Mercurial > hg > svgui
diff view/View.h @ 1357:93eaff6f206d
Rework cacheing logic to reduce the number of reallocations and be more correct about the repaint areas. I don't expect the difference to be really noticeable but in theory performance should be a little better...
author | Chris Cannam |
---|---|
date | Thu, 11 Oct 2018 14:59:34 +0100 |
parents | 40b9a495a0e0 |
children | 694004228ab7 |
line wrap: on
line diff
--- a/view/View.h Thu Oct 11 10:15:45 2018 +0100 +++ b/view/View.h Thu Oct 11 14:59:34 2018 +0100 @@ -440,6 +440,7 @@ virtual void paintEvent(QPaintEvent *e); virtual void drawSelections(QPainter &); virtual bool shouldLabelSelections() const { return true; } + virtual void drawPlayPointer(QPainter &); virtual bool render(QPainter &paint, int x0, sv_frame_t f0, sv_frame_t f1); virtual void setPaintFont(QPainter &paint); @@ -499,6 +500,7 @@ QPixmap *m_cache; // I own this QPixmap *m_buffer; // I own this + bool m_cacheValid; sv_frame_t m_cacheCentreFrame; ZoomLevel m_cacheZoomLevel; bool m_selectionCached;