Files
test/source
Christoph Lendenfeld 3eda9619f9 Anim: precalculate bounding indices for key drawing in the Graph Editor
While the drawing code already skipped drawing any key points that are not in view,
it did that with an `if` check within the `for` loop. This can be speed up quite a bit
by calculating the bounding indices beforehand and only iterating that range.

| - | Before | After |
| - | - | - |
| `draw_fcurve_selected_keyframe_vertices` | 44850ns | 3194ns |
| `graph_main_region_draw` | 32ms | 21ms |

Test file used
https://download.blender.org/ftp/sybren/animation-rigging/heavy_mocap_test.blend

Pull Request: https://projects.blender.org/blender/blender/pulls/120521
2024-04-12 12:41:45 +02:00
..