Bug 263646
| Summary: | [GTK][WPE] PlatformDisplay should not use EGL_EXTERNAL_CONTEXT_SAVE_STATE_ANGLE | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Kimmo Kinnunen <kkinnunen> |
| Component: | WebGL | Assignee: | Carlos Garcia Campos <cgarcia> |
| Status: | RESOLVED FIXED | ||
| Severity: | Normal | CC: | dino, kbr, kkinnunen, webkit-bug-importer |
| Priority: | P2 | Keywords: | InRadar |
| Version: | WebKit Local Build | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Bug Depends on: | |||
| Bug Blocks: | 263639 | ||
Kimmo Kinnunen
[GTK][WPE] PlatformDisplay should not use EGL_EXTERNAL_CONTEXT_SAVE_STATE_ANGLE
It is removed in upstream ANGLE commit:
Author: Shahbaz Youssefi <syoussefi@chromium.org>
Date: Thu Jul 27 10:51:07 2023 -0400
GL: Remove EGL_EXTERNAL_CONTEXT_SAVE_STATE_ANGLE
Now that Chromium no longer uses it.
Bug: angleproject:5509
Change-Id: Ibb8d9cdc4d67dad77ca50437423b18d81e838203
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4724768
Reviewed-by: Peng Huang <penghuang@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
This is blocking ANGLE update.
Options to fix:
1. Share the WebGL display buffer with external sharing mechanism
Each platform should have the webgl display buffer backing as such a resource that can be bound to the textures explicitly.
The compositor and WebGL should not share OpenGL contexts, as WebGL is not designed to do that.
The WebKit ANGLE should preferably only be used to run WebGL, not the compositor to prevent this kind of merge blockers.
2. When ANGLE usage beings, call eglAcquireExternalContextANGLE.
When ANGLE usage ends and compositor usage begins, call eglReleaseExternalContextANGLE.
Option 1 is preferred.
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Kimmo Kinnunen
Note: current implementation with context sharing with WebGL and compositor in general will not work correctly with WebGL. (E.g. the option 2 is broken)
WebGL will abandon resources in certain conditions by design.
This means that all abandoned WebGL resources will be leak through the compositor context.
The correct approach is to keep WebGL contexts and compositor contexts separate and share the resources with the external sharing mechanisms.
Carlos Garcia Campos
Pull request: https://github.com/WebKit/WebKit/pull/19530
EWS
Committed 269804@main (24ec7c56a453): <https://commits.webkit.org/269804@main>
Reviewed commits have been landed. Closing PR #19530 and removing active labels.
Radar WebKit Bug Importer
<rdar://problem/117519080>