diff options
author | Trond Kjernåsen <trond.kjernasen@nokia.com> | 2010-09-22 14:11:02 (GMT) |
---|---|---|
committer | Trond Kjernåsen <trond.kjernasen@nokia.com> | 2010-09-22 14:16:27 (GMT) |
commit | 88b5af89e35584f12330bc6932176d5df413d1b1 (patch) | |
tree | 91c57b512a0f364560060613a7e7bd28ec20dc38 /src/opengl/qgl_x11.cpp | |
parent | 571f0dc0a33b22bfc1f1ffd4521e7c4e5151647c (diff) | |
download | Qt-88b5af89e35584f12330bc6932176d5df413d1b1.zip Qt-88b5af89e35584f12330bc6932176d5df413d1b1.tar.gz Qt-88b5af89e35584f12330bc6932176d5df413d1b1.tar.bz2 |
Fixed drawing of QPixmaps with masks in the GL 2 and X11 engines.
A regression from 4.6.x. This is an X11-only problem caused by the
separate masks that an X11 QPixmap can contain. These masks we're not
taken into account when a number optimizations were done for 4.7.
Introduction of the texture-from-pixmap extension in 4.6 also broke
masked pixmaps under X11.
Task-number: QTBUG-13814
Reviewed-by: Samuel
Diffstat (limited to 'src/opengl/qgl_x11.cpp')
-rw-r--r-- | src/opengl/qgl_x11.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/opengl/qgl_x11.cpp b/src/opengl/qgl_x11.cpp index f3a4c95..7f4c670 100644 --- a/src/opengl/qgl_x11.cpp +++ b/src/opengl/qgl_x11.cpp @@ -1776,6 +1776,10 @@ QGLTexture *QGLContextPrivate::bindTextureFromNativePixmap(QPixmap *pixmap, cons QX11PixmapData *pixmapData = static_cast<QX11PixmapData*>(pixmap->data_ptr().data()); Q_ASSERT(pixmapData->classId() == QPixmapData::X11Class); + // We can't use TFP if the pixmap has a separate X11 mask + if (pixmapData->x11_mask) + return 0; + if (!qt_resolveTextureFromPixmap(paintDevice)) return 0; |