Title: [280417] trunk/Source/WebCore
Revision
280417
Author
commit-qu...@webkit.org
Date
2021-07-28 22:30:34 -0700 (Wed, 28 Jul 2021)

Log Message

[WebXR] Require GL_OES_EGL_image extension for xrCompatible GL context
https://bugs.webkit.org/show_bug.cgi?id=228575

Patch by Ada Chan <ada.c...@apple.com> on 2021-07-28
Reviewed by Dean Jackson.

Without this extension, EGLImageTargetTexture2DOES() will fail
in GraphicsContextGLOpenGL::attachIOSurfaceToSharedTexture().

* platform/graphics/cocoa/GraphicsContextGLOpenGLCocoa.mm:
(WebCore::GraphicsContextGLOpenGL::GraphicsContextGLOpenGL):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (280416 => 280417)


--- trunk/Source/WebCore/ChangeLog	2021-07-29 04:18:16 UTC (rev 280416)
+++ trunk/Source/WebCore/ChangeLog	2021-07-29 05:30:34 UTC (rev 280417)
@@ -1,3 +1,16 @@
+2021-07-28  Ada Chan  <ada.c...@apple.com>
+
+        [WebXR] Require GL_OES_EGL_image extension for xrCompatible GL context
+        https://bugs.webkit.org/show_bug.cgi?id=228575
+
+        Reviewed by Dean Jackson.
+
+        Without this extension, EGLImageTargetTexture2DOES() will fail
+        in GraphicsContextGLOpenGL::attachIOSurfaceToSharedTexture().
+
+        * platform/graphics/cocoa/GraphicsContextGLOpenGLCocoa.mm:
+        (WebCore::GraphicsContextGLOpenGL::GraphicsContextGLOpenGL):
+
 2021-07-28  Jean-Yves Avenard  <j...@apple.com>
 
         [WebAudio] Add webm/opus container support

Modified: trunk/Source/WebCore/platform/graphics/cocoa/GraphicsContextGLOpenGLCocoa.mm (280416 => 280417)


--- trunk/Source/WebCore/platform/graphics/cocoa/GraphicsContextGLOpenGLCocoa.mm	2021-07-29 04:18:16 UTC (rev 280416)
+++ trunk/Source/WebCore/platform/graphics/cocoa/GraphicsContextGLOpenGLCocoa.mm	2021-07-29 05:30:34 UTC (rev 280417)
@@ -309,6 +309,10 @@
         requiredExtensions.append("GL_EXT_texture_format_BGRA8888"_s);
     }
 #endif // PLATFORM(MAC) || PLATFORM(MACCATALYST)
+#if ENABLE(WEBXR) && !PLATFORM(IOS_FAMILY_SIMULATOR)
+    if (contextAttributes().xrCompatible)
+        requiredExtensions.append("GL_OES_EGL_image"_s);
+#endif
     ExtensionsGL& extensions = getExtensions();
     for (auto& extension : requiredExtensions) {
         if (!extensions.supports(extension)) {
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to