Details
-
Bug
-
Resolution: Fixed
-
P2: Important
-
6.6.3, 6.8.0 Beta1
-
None
-
-
bea8beef8 (dev), aba84d1e6 (6.8), 4a5b7ef64 (6.7), 1a7fbb055 (tqtc/lts-6.5)
Description
When I rotate an image (e.g. 90 degrees), the color profile information is lost. Here's an example:
for (int i = 0; i < 2; ++i) { QImage qi(16, 16, QImage::Format_ARGB32); qi.setColorSpace(QColorSpace(QColorSpace::AdobeRgb)); if (i) qi = qi.transformed(QTransform().rotate(90)); qDebug() << qi.colorSpace().isValid() << qi.colorSpace().description(); }
The result is:
true "Adobe RGB" false ""
Same problem when loading an image (e.g. the attached TIFF) with orientation (from 4 to 7) using QImageReader and setAutoTrasform(true):
for (int i = 0; i < 2; ++i) { QImageReader r("dice_r.tif"); r.setAutoTransform(i ? true : false); auto qi = r.read(); qDebug() << qi.colorSpace().isValid() << qi.colorSpace().description(); }
The result is:
true "sRGB Linear build-in" false ""
Attachments
For Gerrit Dashboard: QTBUG-126575 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
570646,2 | QImage: retain color space also through right angle roatations | dev | qt/qtbase | Status: MERGED | +2 | 0 |
574449,2 | QImage: retain color space also through right angle roatations | 6.8 | qt/qtbase | Status: MERGED | +2 | 0 |
574623,3 | QImage: retain color space also through right angle roatations | 6.7 | qt/qtbase | Status: MERGED | +2 | +1 |
579195,2 | QImage: retain color space also through right angle roatations | tqtc/lts-6.5 | qt/tqtc-qtbase | Status: MERGED | +2 | 0 |