Opened 5 years ago

Last modified 3 years ago

#113 new enhancement

Window backup wastes memory

Reported by: PulkoMandy Owned by: pulkomandy
Priority: minor Milestone: 2.9
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 (3)

comment:1 by yrizoud@…, 5 years ago

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 by PulkoMandy, 4 years ago

Milestone: 2.72.8

comment:3 by PulkoMandy, 3 years ago

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