From ee07fff45d49e69d9a4f4474861a219af8d557f2 Mon Sep 17 00:00:00 2001 From: Tom Cooksey Date: Fri, 5 Mar 2010 16:59:06 +0100 Subject: Make QEgl::createSurface store the surface in the pixmapdata too This means the same surface can then later be used to bind the pixmap as a texture using eglBindTexImage2D. Reviewed-By: TrustMe --- src/gui/egl/qegl_x11.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/gui/egl/qegl_x11.cpp b/src/gui/egl/qegl_x11.cpp index 483c01d..8608523 100644 --- a/src/gui/egl/qegl_x11.cpp +++ b/src/gui/egl/qegl_x11.cpp @@ -404,9 +404,11 @@ EGLSurface QEgl::createSurface(QPaintDevice *device, EGLConfig config, const QEg else surfaceAttribs.setValue(EGL_TEXTURE_FORMAT, EGL_TEXTURE_RGB); - return eglCreatePixmapSurface(QEgl::display(), config, - (EGLNativePixmapType) x11PixmapData->handle(), - surfaceAttribs.properties()); + EGLSurface surf = eglCreatePixmapSurface(QEgl::display(), config, + (EGLNativePixmapType) x11PixmapData->handle(), + surfaceAttribs.properties()); + x11PixmapData->gl_surface = (Qt::HANDLE)surf; + return surf; } return EGL_NO_SURFACE; -- cgit v0.12