WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
240313
[GTK][WPE] Make ANGLE backend EGL context initialization work
https://bugs.webkit.org/show_bug.cgi?id=240313
Summary
[GTK][WPE] Make ANGLE backend EGL context initialization work
Alejandro G. Castro
Reported
2022-05-11 12:43:50 PDT
Currently there are issues when running tests with our headless backend, we need to review the way we create the display and choose configuration.
Attachments
Patch
(2.47 KB, patch)
2022-05-11 12:51 PDT
,
Alejandro G. Castro
no flags
Details
Formatted Diff
Diff
Patch
(2.03 KB, patch)
2022-05-13 13:05 PDT
,
Alejandro G. Castro
no flags
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Alejandro G. Castro
Comment 1
2022-05-11 12:51:07 PDT
Created
attachment 459178
[details]
Patch
Zan Dobersek (Reviews)
Comment 2
2022-05-12 05:50:08 PDT
Comment on
attachment 459178
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=459178&action=review
> Source/WebCore/platform/graphics/gbm/GraphicsContextGLGBM.cpp:222 > - m_displayObj = EGL_GetPlatformDisplayEXT(EGL_PLATFORM_ANGLE_ANGLE, EGL_DEFAULT_DISPLAY, displayAttributes.data()); > + m_displayObj = EGL_GetPlatformDisplayEXT(EGL_PLATFORM_ANGLE_ANGLE, PlatformDisplay::sharedDisplay().eglDisplay(), displayAttributes.data());
EGL_DEFAULT_DISPLAY is a native display identifier for the default display, it's cast to EGLNativeDisplayType. The change now pushes an EGLDisplay value into the EGL call, which is not how the entrypoint works. There has to be a different way taken of avoiding X11 in Mesa.
Alejandro G. Castro
Comment 3
2022-05-13 09:51:25 PDT
(In reply to Zan Dobersek (Reviews) from
comment #2
)
> Comment on
attachment 459178
[details]
> Patch > > View in context: >
https://bugs.webkit.org/attachment.cgi?id=459178&action=review
> > > Source/WebCore/platform/graphics/gbm/GraphicsContextGLGBM.cpp:222 > > - m_displayObj = EGL_GetPlatformDisplayEXT(EGL_PLATFORM_ANGLE_ANGLE, EGL_DEFAULT_DISPLAY, displayAttributes.data()); > > + m_displayObj = EGL_GetPlatformDisplayEXT(EGL_PLATFORM_ANGLE_ANGLE, PlatformDisplay::sharedDisplay().eglDisplay(), displayAttributes.data()); > > EGL_DEFAULT_DISPLAY is a native display identifier for the default display, > it's cast to EGLNativeDisplayType. The change now pushes an EGLDisplay value > into the EGL call, which is not how the entrypoint works. There has to be a > different way taken of avoiding X11 in Mesa.
Right, I made the mistake to think the Display was the same Egl display, but it is just used to make sure we return the same EGLDisplay for the same NativeDisplay; just tested even passing (void *) 1, makes the tests work, because it just stores the pointer as an Id and allows the code path to be different using a guessing function, avoiding the building default like when you pass EGL_DEFAULT_DISPLAY, which is 0x0. I can try and environment variable in the script to try to avoid it if I do not find other code path that can be used. Thanks for the review!
Alejandro G. Castro
Comment 4
2022-05-13 13:05:39 PDT
Created
attachment 459320
[details]
Patch
EWS
Comment 5
2022-05-16 10:59:57 PDT
Committed
r294245
(
250603@main
): <
https://commits.webkit.org/250603@main
> All reviewed patches have been landed. Closing bug and clearing flags on
attachment 459320
[details]
.
Radar WebKit Bug Importer
Comment 6
2022-05-16 11:01:14 PDT
<
rdar://problem/93357585
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug