summaryrefslogtreecommitdiff
path: root/wizards/source/scriptforge/SF_PythonHelper.xba
diff options
context:
space:
mode:
authorLuboš Luňák <l.lunak@collabora.com>2021-03-15 22:15:15 +0100
committerLuboš Luňák <l.lunak@collabora.com>2021-03-16 12:56:17 +0100
commit1e9b97dc1f795da63c92b0169415a4f455d9d014 (patch)
treefaef3e3376566a97065e46d051441f819a3e446a /wizards/source/scriptforge/SF_PythonHelper.xba
parent2c84920182ee18d0cff97637bc7f20facc5f29cd (diff)
fixes for SkiaSalBitmap delayed scaling (tdf#140930)
The original idea for delayed scaling was that if a bitmap is to be scaled, only the parameters will be saved and the pixel buffer mBuffer will be resized only on-demand. But this gets complicated by mImage sometimes not being just a cache of mBuffer, but sometimes it is the only data. This is needed so that e.g. OutputDevice::GetBitmap() can operate only on SkImage without possibly ever needing a conversion to the pixel buffer, thus even keeping the data only on the GPU in the Vulkan case. Together with delayed scaling this means that the size of mImage can be either the original size (if Scale() is called with mImage already valid) or the final size (if mImage is created in GetSkImage()). Thus relying on 'mPixelsSize != mSize' as a detection of pending scaling does not always work for mImage. Handle this by using mImage dimensions in cases where relevant. Change-Id: Id9fad67b8936d2266c1f270d08023d15efee3987 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112545 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
Diffstat (limited to 'wizards/source/scriptforge/SF_PythonHelper.xba')
0 files changed, 0 insertions, 0 deletions