Skip to content
  • Hy Murveit's avatar
    Reduce memory use when zooming in fitsviewer · 48491864
    Hy Murveit authored and Jasem Mutlaq's avatar Jasem Mutlaq committed
    Summary:
    Instead of creating a scaled image, let Qt do the work.
    This saves half the memory when zooming 200% or 300%.
    I also limited the zoom to 300% running out of memory has been
    an issue for users. This change was relatively straight-forward
    for the image rendering, but there was complexity with the
    overlays drawn, espcially those rendering text.
    
    Test Plan:
    Load an image, zoom in. You should be limited to 300%. You should notice less than
    1Gb of memory use from a ~20megapixel camera, whereas this would be over 2.5Gb
    previously. Try the various overlays. They should work the same as before (some line
    widths may be slightly different, but I tried to match the previous rendering.
    Similarly, test focus, align, guide views, zooming in and so forth.
    
    Reviewers: mutlaqja
    
    Reviewed By: mutlaqja
    
    Subscribers: kde-edu
    
    Tags: #kde_edu
    
    Differential Revision: https://phabricator.kde.org/D28935
    48491864