diff options
author | Tom Cooksey <thomas.cooksey@nokia.com> | 2010-03-02 15:41:16 (GMT) |
---|---|---|
committer | Tom Cooksey <thomas.cooksey@nokia.com> | 2010-03-02 15:48:15 (GMT) |
commit | e614e3548bbe505c75e8b3a54f44f07522a6ecf5 (patch) | |
tree | 9b9a6515416a94434e346ec548e002fb6e11e96b /src/opengl/qgl_x11egl.cpp | |
parent | 03daf059647c0a0222e8774b0a083f58c8e64934 (diff) | |
download | Qt-e614e3548bbe505c75e8b3a54f44f07522a6ecf5.zip Qt-e614e3548bbe505c75e8b3a54f44f07522a6ecf5.tar.gz Qt-e614e3548bbe505c75e8b3a54f44f07522a6ecf5.tar.bz2 |
Add and use QGLContextPrivate::eglSurfaceForDevice()
The QGLContext only stores the EGLSurface for QWidgets & QGLWidgets,
other device types like QPixmap & QGLPixelBuffer store the surface
themsselves. With this patch it is possible to create a QGLContext
on a QPixmap, make it current and render GL to that QPixmap on X11.
Reviewed-By: TrustMe
Diffstat (limited to 'src/opengl/qgl_x11egl.cpp')
-rw-r--r-- | src/opengl/qgl_x11egl.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/opengl/qgl_x11egl.cpp b/src/opengl/qgl_x11egl.cpp index bcde8c4..ba05e72 100644 --- a/src/opengl/qgl_x11egl.cpp +++ b/src/opengl/qgl_x11egl.cpp @@ -229,7 +229,7 @@ bool QGLContext::chooseContext(const QGLContext* shareContext) // QWidget - yes, create the EGLSurface and store it in QGLContextPrivate::eglSurface // QGLWidget - yes, create the EGLSurface and store it in QGLContextPrivate::eglSurface // QPixmap - yes, create the EGLSurface but store it in QX11PixmapData::gl_surface - // QGLPixelBuffer - no, it creates the surface itself + // QGLPixelBuffer - no, it creates the surface itself and stores it in QGLPixelBufferPrivate::pbuf if (devType == QInternal::Widget) { if (d->eglSurface != EGL_NO_SURFACE) |