Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-57268

GLContextHelper::getEGLDisplay() failed.

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Not Evaluated
    • Resolution: Done
    • Affects Version/s: 5.8.0 Beta
    • Fix Version/s: 5.7.2
    • Component/s: WebEngine
    • Labels:
      None
    • Environment:

      Description

      When running QuickNanoBrowser, GLSurfaceQtEGL::InitializeOneOff() fails with error: "GLContextHelper::getEGLDisplay() failed."

      Call tree:

      qtwebengine/src/core/gl_surface_qt.cpp:
      GLSurfaceQtEGL::InitializeOneOff()
      

      calls

      qtwebengine/src/core/gl_context_qt.cpp:
      void* GLContextHelper::getEGLDisplay() 
      {
        return resourceForContext(QByteArrayLiteral("egldisplay"));
      }
      

      which results in call to

      qtbase/src/plugins/platforms/xcb/gl_integrations/xcb_egl/qxcbeglnativeintarfacehandler.cpp:
      QPlatformNativeInterface::NativeResourceForContextFunction QXcbEglNativeInterfaceHandler::nativeResourceFunctionForContext(const QByteArray &resource) const
      {
          switch (resourceType(resource)) {
          case EglContext:
              return eglContextForContext;
          case EglConfig:
              return eglConfigForContext;
          default:
              break;
          }
          return Q_NULLPTR;
      }
      

      which does not handle "egldisplay" but only "eglcontext" and "eglconfig".

      If in GLContextHelper::getEGLDisplay(), resourceForIntegration() is used instead of resourceForContext(), function called from xcb_egl is:

      qtbase/src/plugins/platforms/xcb/gl_integrations/xcb_egl/qxcbeglnativeinterfacehandler.cpp:
      QPlatformNativeInterface::NativeResourceForIntegrationFunction QXcbEglNativeInterfaceHandler::nativeResourceFunctionForIntegration(const QByteArray &resource) const{
          switch (resourceType(resource)) {
          case EglDisplay:
              return eglDisplay;
          default:
              break;
          }
          return Q_NULLPTR;
      }
      

      which does handle "egldisplay", initialization is done successfully and QuickNanoBrowser runs.

        Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

            Assignee:
            qt_webengine_team Qt WebEngine Team
            Reporter:
            leporis leporis
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Gerrit Reviews

                There are no open Gerrit changes