Changeset 225078 in webkit


Ignore:
Timestamp:
Nov 21, 2017 5:37:48 AM (6 years ago)
Author:
Carlos Garcia Campos
Message:

[WPE] WPEWebProcess: Couldn't find current GLX or EGL context
https://bugs.webkit.org/show_bug.cgi?id=179883

Reviewed by Žan Doberšek.

I'm seeing that message quite often when running the unit tests. The problem seems to be that some tests run so
fast that the web process never renders the first frame, so the context is created but never made current. I've
checked with apitrace that there are calls to eglQueryContext with null display, causing a EGL_BAD_DISPLAY, but
I don't know where those calls are originated. Making the context current right after it's created fixes the
problem.

  • Shared/CoordinatedGraphics/threadedcompositor/ThreadedCompositor.cpp:

(WebKit::ThreadedCompositor::createGLContext): Always call makeContextCurrent() right after the context is created.

Location:
trunk/Source/WebKit
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebKit/ChangeLog

    r225066 r225078  
     12017-11-21  Carlos Garcia Campos  <cgarcia@igalia.com>
     2
     3        [WPE] WPEWebProcess: Couldn't find current GLX or EGL context
     4        https://bugs.webkit.org/show_bug.cgi?id=179883
     5
     6        Reviewed by Žan Doberšek.
     7
     8        I'm seeing that message quite often when running the unit tests. The problem seems to be that some tests run so
     9        fast that the web process never renders the first frame, so the context is created but never made current. I've
     10        checked with apitrace that there are calls to eglQueryContext with null display, causing a EGL_BAD_DISPLAY, but
     11        I don't know where those calls are originated. Making the context current right after it's created fixes the
     12        problem.
     13
     14        * Shared/CoordinatedGraphics/threadedcompositor/ThreadedCompositor.cpp:
     15        (WebKit::ThreadedCompositor::createGLContext): Always call makeContextCurrent() right after the context is created.
     16
    1172017-11-20  Carlos Garcia Campos  <cgarcia@igalia.com>
    218
  • trunk/Source/WebKit/Shared/CoordinatedGraphics/threadedcompositor/ThreadedCompositor.cpp

    r220792 r225078  
    9494        return;
    9595
    96     if (m_doFrameSync == ShouldDoFrameSync::No) {
    97         if (m_context->makeContextCurrent())
    98             m_context->swapInterval(0);
    99     }
     96    if (!m_context->makeContextCurrent())
     97        return;
     98
     99    if (m_doFrameSync == ShouldDoFrameSync::No)
     100        m_context->swapInterval(0);
    100101}
    101102
Note: See TracChangeset for help on using the changeset viewer.