summaryrefslogtreecommitdiffstats
path: root/src/opengl
diff options
context:
space:
mode:
Diffstat (limited to 'src/opengl')
-rw-r--r--src/opengl/qpixmapdata_gl.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/opengl/qpixmapdata_gl.cpp b/src/opengl/qpixmapdata_gl.cpp
index f0c7e20..fe3bb0c 100644
--- a/src/opengl/qpixmapdata_gl.cpp
+++ b/src/opengl/qpixmapdata_gl.cpp
@@ -303,6 +303,8 @@ QImage QGLPixmapData::fillImage(const QColor &color) const
return img;
}
+extern QImage qt_gl_read_texture(const QSize &size, bool alpha_format, bool include_alpha);
+
QImage QGLPixmapData::toImage() const
{
if (!isValid())
@@ -319,7 +321,6 @@ QImage QGLPixmapData::toImage() const
}
QGLShareContextScope ctx(qt_gl_share_widget()->context());
- extern QImage qt_gl_read_texture(const QSize &size, bool alpha_format, bool include_alpha);
glBindTexture(GL_TEXTURE_2D, m_textureId);
return qt_gl_read_texture(QSize(w, h), true, true);
}