diff options
author | Allan Sandfeld Jensen <allan.jensen@qt.io> | 2021-01-14 15:13:42 +0100 |
---|---|---|
committer | Allan Sandfeld Jensen <allan.jensen@qt.io> | 2021-01-15 15:17:19 +0100 |
commit | ade24763c74ce506276218ec1ce0e307301717fe (patch) | |
tree | 9c488e10420138e2abc6dc91747188c20b7064fd /src | |
parent | e86e9d0725192d06196faa0f24593e907330b2e3 (diff) |
Fix convertToRGBA64PM for Grayscale16
The input has been fetch into a set of uint32s, so no longer a
string of ushorts.
Pick-to: 6.0 5.15
Fixes: QTBUG-90246
Change-Id: Id52a6824317b0744310008cc2ce2f726539b4c8c
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
Diffstat (limited to 'src')
-rw-r--r-- | src/gui/painting/qpixellayout.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/gui/painting/qpixellayout.cpp b/src/gui/painting/qpixellayout.cpp index 3bc0d3333d..acaee9f289 100644 --- a/src/gui/painting/qpixellayout.cpp +++ b/src/gui/painting/qpixellayout.cpp @@ -804,9 +804,8 @@ static const uint *QT_FASTCALL fetchGrayscale16ToRGB32(uint *buffer, const uchar static const QRgba64 *QT_FASTCALL convertGrayscale16ToRGBA64(QRgba64 *buffer, const uint *src, int count, const QList<QRgb> *, QDitherInfo *) { - const unsigned short *s = reinterpret_cast<const unsigned short *>(src); for (int i = 0; i < count; ++i) - buffer[i] = QRgba64::fromRgba64(s[i], s[i], s[i], 65535); + buffer[i] = QRgba64::fromRgba64(src[i], src[i], src[i], 65535); return buffer; } |