From e8562b0e8d6ffdb5b1d237d5f441ab1c9239b168 Mon Sep 17 00:00:00 2001 From: Laszlo Agocs Date: Tue, 26 Apr 2022 06:59:37 -0700 Subject: [PATCH] egl: Remove the disabling of surfaceless contexts for Mesa The current check is based on the state of things in 2015, we will assume that this is no longer an issue with more modern Mesa versions. Change-Id: I60c4966eea817a6df1a1edf6064a978fbcd44cf7 Reviewed-by: Andy Nichols --- src/gui/opengl/platform/egl/qeglpbuffer.cpp | 9 --------- 1 file changed, 9 deletions(-) diff --git a/src/gui/opengl/platform/egl/qeglpbuffer.cpp b/src/gui/opengl/platform/egl/qeglpbuffer.cpp index 55e199a6ad..7cc1111ab5 100644 --- a/src/gui/opengl/platform/egl/qeglpbuffer.cpp +++ b/src/gui/opengl/platform/egl/qeglpbuffer.cpp @@ -65,15 +65,6 @@ QEGLPbuffer::QEGLPbuffer(EGLDisplay display, const QSurfaceFormat &format, QOffs m_hasSurfaceless = !flags.testFlag(QEGLPlatformContext::NoSurfaceless) && q_hasEglExtension(display, "EGL_KHR_surfaceless_context"); - // Disable surfaceless contexts on Mesa for now. As of 10.6.0 and Intel at least, some - // operations (glReadPixels) are unable to work without a surface since they at some - // point temporarily unbind the current FBO and then later blow up in some seemingly - // safe operations, like setting the viewport, that apparently need access to the - // read/draw surface in the Intel backend. - const char *vendor = eglQueryString(display, EGL_VENDOR); // hard to check for GL_ strings here, so blacklist all Mesa - if (vendor && strstr(vendor, "Mesa")) - m_hasSurfaceless = false; - if (m_hasSurfaceless) return;