diff options
author | Jani Hautakangas <jani.hautakangas@nokia.com> | 2011-02-07 11:38:51 (GMT) |
---|---|---|
committer | Jani Hautakangas <jani.hautakangas@nokia.com> | 2011-02-25 13:36:47 (GMT) |
commit | 01dcf4ca11c38df20c0948357383ff22ecd29035 (patch) | |
tree | 8c7496e9132341bfb8c4d2d566a9912101900859 /src/opengl/qpixmapdata_gl_p.h | |
parent | 31e3cc1256083494d28b20af874f7b2023446df0 (diff) | |
download | Qt-01dcf4ca11c38df20c0948357383ff22ecd29035.zip Qt-01dcf4ca11c38df20c0948357383ff22ecd29035.tar.gz Qt-01dcf4ca11c38df20c0948357383ff22ecd29035.tar.bz2 |
Use the 'convertInPlace' versions of QImage in QGLPixmapData load.
Change QGLPixmapData load functions to use 'convertInPlace' versions
of QImage to save memory.
Task-number: QTBUG-17256
Reviewed-by: Samuel Rødal
Diffstat (limited to 'src/opengl/qpixmapdata_gl_p.h')
-rw-r--r-- | src/opengl/qpixmapdata_gl_p.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/opengl/qpixmapdata_gl_p.h b/src/opengl/qpixmapdata_gl_p.h index 5545d3c..96631e6 100644 --- a/src/opengl/qpixmapdata_gl_p.h +++ b/src/opengl/qpixmapdata_gl_p.h @@ -107,6 +107,8 @@ public: // Re-implemented from QPixmapData: void resize(int width, int height); void fromImage(const QImage &image, Qt::ImageConversionFlags flags); + void fromImageReader(QImageReader *imageReader, + Qt::ImageConversionFlags flags); bool fromFile(const QString &filename, const char *format, Qt::ImageConversionFlags flags); bool fromData(const uchar *buffer, uint len, const char *format, @@ -149,6 +151,8 @@ private: QImage fillImage(const QColor &color) const; + void createPixmapForImage(QImage &image, Qt::ImageConversionFlags flags, bool inPlace); + mutable QGLFramebufferObject *m_renderFbo; mutable QPaintEngine *m_engine; mutable QGLContext *m_ctx; |