Skip to content

Commit

Permalink
[WebXR] Enable required extensions for simulator builds
Browse files Browse the repository at this point in the history
https://bugs.webkit.org/show_bug.cgi?id=258836
rdar://111710240

Reviewed by Kimmo Kinnunen.

There are two code paths to create a WebGL context for use by WebXR. The first
is at creation time and the second upgrades an exiting WebGL context for WebXR.

The second path was not requesting all the required extensions in simulator
builds. This change makes both paths request the same extensions on all builds
for Cocoa platforms.

* Source/WebCore/html/canvas/WebGLRenderingContextBase.cpp:
(WebCore::WebGLRenderingContextBase::makeXRCompatible):

Canonical link: https://commits.webkit.org/265766@main
  • Loading branch information
djg authored and kkinnunen-apple committed Jul 5, 2023
1 parent 70d4a42 commit e6dd2b8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Source/WebCore/html/canvas/WebGLRenderingContextBase.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3278,7 +3278,7 @@ void WebGLRenderingContextBase::makeXRCompatible(MakeXRCompatiblePromise&& promi
// FIXME: add a way to verify that we're using a compatible graphics adapter.
m_isXRCompatible = true;

#if PLATFORM(COCOA) && !PLATFORM(IOS_FAMILY_SIMULATOR)
#if PLATFORM(COCOA)
// FIXME: This is ugly. It's something needed at the GraphicsContextGL
// level, not WebGLRenderingContext. We should move this down to a
// virtual makeXRCompatible or something on GCGL.
Expand Down

0 comments on commit e6dd2b8

Please sign in to comment.