qt6-bb10/tests/auto/gui/image/qimagereader
Eirik Aavitsland 12bca46996 Remove inline downscaling in png reader
In Qt 5.0 timeframe, support for downscaled reading was added to the
png handler, as a help for devices with very limited memory. Instead
of decoding the whole image into memory and then scaling it down (as
happens for most image formats if scaled reading is requested), a
separate reading function was added that would perform line-by-line
decoding and downscaling.

Although this provides a transient memory saving during decoding, it
has a number of drawbacks:

- The scaling routine is simplistic and can create artifacts for
  images with transparency, ref. the linked bug report

- The scaled result from the png handler is in general different from
  the result of using the common QImage smoothscaling function

- The line-by-line scaling function is generally slower than the
  common smoothscaling function, since the latter is optimized using
  SSE/NEON extensions

- It adds a redundant implementation of image scaling to the code base

Hence we drop this functionalty going forward. This effectively
reverts 44a9c08eff0647f398863de55e2b62dbd6541e27.

[ChangeLog][QtGui][Image I/O] The PNG handler no longer implements
progressive downscaling during decoding when scaled image reading is
requested.

Fixes: QTBUG-121724
Change-Id: I7b524b12c174c64201b98945ee2fa062ed127f87
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
(cherry picked from commit a2a315eaa28edf9c649e13c951fdb1154e3ddf48)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
2024-08-16 06:49:53 +00:00
..
baseline
images QPpmHandler: fix reading ppm files 2023-11-27 19:53:41 +01:00
.gitignore
BLACKLIST tests: blacklist tst_QImageReader::setClipRect() and 2023-03-24 10:49:16 +01:00
CMakeLists.txt CMake: Make gui tests standalone projects 2023-07-05 15:09:32 +02:00
android_testdata.qrc Android: Fix QImageReader test 2015-01-16 09:27:15 +01:00
tst_qimagereader.cpp Remove inline downscaling in png reader 2024-08-16 06:49:53 +00:00