Closed JoshuaBonn1 closed 7 months ago
After using callgrind, the result is to be expected. After fixing some getFont() calls and other loop invariants, the clear slow down was clearing and recreating all the graphic items. My first fix will be adjusting all the widths of the items to see if there is any particular speed up. If that works, I will adjust the x position of the items as well and see what happens.
For the record, the meta actually took the most time to clear and redraw due to dealing with text items (expensive). Just reusing these would cause a large speedup (supposedly).
While some graphical glitches remain, simply updating the x and width of the cells resulted in basically no slow down. With good news from this, creating a "redraw" of the meta should significantly decrease the zooming lag, hopefully down to 0.
5d673b31bc49e512ccffd596f15e235b9ce288f8 attempts to fix the lag.
Zooming in and out on the timeline using Ctrl + Scroll causes serious lag on large scores. This is likely because of redrawing the timeline every single time the zoom changes. There are a few solutions for this: