summaryrefslogtreecommitdiffstats
path: root/src/gui/image/qimage.h
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@qt.io>2016-11-11 13:12:23 +0100
committerAllan Sandfeld Jensen <allan.jensen@qt.io>2017-01-18 13:10:52 +0000
commitf4a098c6351fd2d14a2d70b7014697d326e83ba7 (patch)
tree39042620ac4a3d1a13c16aa37c509e661c257a3d /src/gui/image/qimage.h
parentd2d9d26b1e94607050e7d3c7efc5a7b5516386bb (diff)
Introduce QImage::reinterpretAsFormat
QImage::reinterpretAsFormat can be used to change the format of an image without converting the data, to correct wrong formats or narrow the format to an opaque one if found to be opaque. [ChangeLog][QtGui][QImage] A new method reinterpretAsFormat is has been added to change the format of a QImage without converting the data. Change-Id: I5e15bc5a1c474a35d3921b06299008ab2effd945 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io> Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
Diffstat (limited to 'src/gui/image/qimage.h')
-rw-r--r--src/gui/image/qimage.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/gui/image/qimage.h b/src/gui/image/qimage.h
index fd2298561e..204e7a54b2 100644
--- a/src/gui/image/qimage.h
+++ b/src/gui/image/qimage.h
@@ -192,6 +192,7 @@ public:
QImage convertToFormat(Format f, Qt::ImageConversionFlags flags = Qt::AutoColor) const Q_REQUIRED_RESULT;
#endif
QImage convertToFormat(Format f, const QVector<QRgb> &colorTable, Qt::ImageConversionFlags flags = Qt::AutoColor) const Q_REQUIRED_RESULT;
+ bool reinterpretAsFormat(Format f);
int width() const;
int height() const;