summaryrefslogtreecommitdiffstats
path: root/src/gui/egl
diff options
context:
space:
mode:
authorNicolai de Haan <ndhb78@gmail.com>2010-05-05 16:54:34 +0200
committerTrond Kjernåsen <trond.kjernasen@nokia.com>2010-05-10 10:51:47 +0200
commitabcec6ba4b126358c50bf4c539253f88da6bb2d6 (patch)
treed8fdffeb940c60fd57da445448e68491fc3759df /src/gui/egl
parent42d46a85a50926cd24d7216cb99b4084f6d8ad04 (diff)
Opt out of visual-config size checks with extension
EGL_NV_post_convert_replication. QTBUG-9444. Task-number: QTBUG-9444 Merge-request: 612 Reviewed-by: Trond
Diffstat (limited to 'src/gui/egl')
-rw-r--r--src/gui/egl/qegl_x11.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/gui/egl/qegl_x11.cpp b/src/gui/egl/qegl_x11.cpp
index cb8dcda713..969acc4c47 100644
--- a/src/gui/egl/qegl_x11.cpp
+++ b/src/gui/egl/qegl_x11.cpp
@@ -163,6 +163,11 @@ VisualID QEgl::getCompatibleVisualId(EGLConfig config)
int matchingCount = 0;
chosenVisualInfo = XGetVisualInfo(X11->display, VisualIDMask, &visualInfoTemplate, &matchingCount);
if (chosenVisualInfo) {
+ // Skip size checks if implementation supports non-matching visual
+ // and config (http://bugreports.qt.nokia.com/browse/QTBUG-9444).
+ if (QEgl::hasExtension("EGL_NV_post_convert_replication"))
+ return visualId;
+
int visualRedSize = countBits(chosenVisualInfo->red_mask);
int visualGreenSize = countBits(chosenVisualInfo->green_mask);
int visualBlueSize = countBits(chosenVisualInfo->blue_mask);