Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: b50c48fd07c7c53424ac797ef8bafc11a81f2b7c
      
https://github.com/WebKit/WebKit/commit/b50c48fd07c7c53424ac797ef8bafc11a81f2b7c
  Author: Sergio Villar Senin <svil...@igalia.com>
  Date:   2025-08-26 (Tue, 26 Aug 2025)

  Changed paths:
    M Source/WebCore/Modules/webxr/WebXROpaqueFramebuffer.cpp
    M Source/WebCore/Modules/webxr/WebXROpaqueFramebuffer.h
    M Source/WebCore/Modules/webxr/WebXRWebGLLayer.cpp
    M Source/WebCore/platform/graphics/GraphicsContextGL.h
    M 
Source/WebCore/platform/graphics/texmap/GraphicsContextGLTextureMapperANGLE.cpp
    M 
Source/WebCore/platform/graphics/texmap/GraphicsContextGLTextureMapperANGLE.h
    M Source/WebCore/platform/xr/PlatformXR.h
    M Source/WebKit/Shared/XR/XRDeviceLayer.h
    M Source/WebKit/Shared/XR/XRSystem.serialization.in
    M Source/WebKit/UIProcess/XR/openxr/PlatformXROpenXR.cpp
    M Source/WebKit/WebProcess/XR/PlatformXRSystemProxy.cpp

  Log Message:
  -----------
  [WebXR][OpenXR] Add EGL fences for WebGL content
https://bugs.webkit.org/show_bug.cgi?id=297140

Reviewed by Nikolas Zimmermann.

Currently there is no guarantee that the WebXR WebGL frames are
completely rendered before they're submitted to the OpenXR compositor.
That's why the WebXROpaqueFramebuffer does a glFinish(), blocking the
WebProcess before returning from endFrame.

A much better solution is to use EGL fences. The WebProcess will
create a fence in endFrame(). Then that fence is exported and shared
to the UI process (via a file descriptor) in the submitFrame() call.

The UI process then will call wait in the fence before submitting
the frame to OpenXR. Although OpenXR runtimes guarantee that all the
GPU commands are finished before displaying the contents of the
textures, that does not apply to the cases in which there are multiple
contexts accessing the texture, as it happens in WebKit due to the
multiprocess architecture.

Co-authored-by: Carlos Garcia Campos <cgar...@igalia.com>
Canonical link: https://commits.webkit.org/299154@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to