Opened 14 months ago

Last modified 5 months ago

#113 new enhancement

Window backup wastes memory

Reported by: PulkoMandy Owned by: pulkomandy
Priority: minor Milestone: 2.8
Component: GrafX2 Version: 2.6
Keywords: Cc:

Description

https://gitlab.com/GrafX2/grafX2/merge_requests/196#note_167460645

When opening multiple windows ans using a window zoom, the window backup is stored scaled. This wastes memory, we should instead store it at 1x1 scale and scale it up when restoring the window.

Change History (2)

comment:1 Changed 14 months ago by yrizoud@…

Be careful that not everything in a window is drawn scaled by UI size * pixel size. If you cut down the background buffer's "resolution", you may see issue when an other window (for example the Help screen) is drawn on top then removed.
Off the top of my head, the following things can be drawn with finer pixels than the rest:

  • Brushes in the Brush screen - not sure
  • Previews of images in the Load/Save? screen, especially if they have a known pixel ratio (eg: wide pixels from C64 pictures) that is incompatible with the current image's pixel ratio.
  • Maybe the Text preview in Text window

There are other drawing operations that totally bypass pixel ratio AND menu ratio, but they don't happen inside a window so they're no problem: the Grid dotted lines in Zoomed area, and the layer previews.

comment:2 Changed 5 months ago by PulkoMandy

Milestone: 2.72.8
Note: See TracTickets for help on using tickets.