⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 277468 in webkit


Ignore:
Timestamp:
May 13, 2021, 5:35:23 PM (5 years ago)
Author:
dino@apple.com
Message:

[WebXR] Allow WebXR to be tested on PLATFORM(COCOA)
​https://bugs.webkit.org/show_bug.cgi?id=225578
<rdar://problem/77707283>

Reviewed by Sam Weinig.

LayoutTests/imported/w3c:

New expected results.

  • web-platform-tests/webxr/exclusive_requestFrame_nolayer.https-expected.txt: Added.
  • web-platform-tests/webxr/render_state_vertical_fov_inline.https-expected.txt: Added.
  • web-platform-tests/webxr/webxr-supported-by-feature-policy-expected.txt: Added.
  • web-platform-tests/webxr/webxr_availability.http.sub-expected.txt: Added.
  • web-platform-tests/webxr/webxr_feature_policy.https-expected.txt: Added.
  • web-platform-tests/webxr/xrFrame_lifetime.https-expected.txt: Added.
  • web-platform-tests/webxr/xrPose_transform_sameObject.https-expected.txt: Added.
  • web-platform-tests/webxr/xrReferenceSpace_originOffsetBounded.https-expected.txt: Added.
  • web-platform-tests/webxr/xrSession_input_events_end.https-expected.txt: Added.
  • web-platform-tests/webxr/xrSession_visibilityState.https-expected.txt: Added.
  • web-platform-tests/webxr/xrStationaryReferenceSpace_floorlevel_updates.https-expected.txt: Added.
  • web-platform-tests/webxr/xrWebGLLayer_framebuffer_scale.https-expected.txt: Added.
  • web-platform-tests/webxr/xrWebGLLayer_opaque_framebuffer_stencil.https-expected.txt: Added.

Source/WebKit:

Remove checking for a WebXR feature flag.

  • Shared/WebPreferencesDefaultValues.cpp:

(WebKit::defaultWebXREnabled):

Source/WTF:

Compile-time enabled on all Cocoa platforms.

  • wtf/PlatformEnableCocoa.h:

LayoutTests:

Remove the skip rule for the WebXR directory, and add more
specific expected results.

Location:
trunk
Files:
13 added
3 deleted
18 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r277462 r277468  
     12021-05-13  Dean Jackson  <dino@apple.com>
     2
     3        [WebXR] Allow WebXR to be tested on PLATFORM(COCOA)
     4        https://bugs.webkit.org/show_bug.cgi?id=225578
     5
     6        Reviewed by Sam Weinig.
     7
     8        Remove the skip rule for the WebXR directory, and add more
     9        specific expected results.
     10
     11        * TestExpectations:
     12
    1132021-05-13  Cameron McCormack  <heycam@apple.com>
    214
  • trunk/LayoutTests/TestExpectations

    r277430 r277468  
    35823582
    35833583webkit.org/b/207262 imported/w3c/web-platform-tests/web-animations/timing-model/animations/sync-start-times.html [ Pass ImageOnlyFailure ]
    3584 
    3585 # WebXR is being implemented
    3586 webkit.org/b/208988 http/wpt/webxr [ Skip ]
    3587 webkit.org/b/208988 imported/w3c/web-platform-tests/webxr [ Skip ]
    35883584
    35893585webkit.org/b/210963 imported/w3c/web-platform-tests/css/css-animations/animation-important-002.html [ ImageOnlyFailure ]
    … …  
    49144910# This webstorage test has timed out since it was imported.
    49154911imported/w3c/web-platform-tests/webstorage/document-domain.html [ Skip ]
     4912
     4913# WebXR - Missing modules.
     4914webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/anchors [ Skip ]
     4915webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/ar-module [ Skip ]
     4916webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/dom-overlay [ Skip ]
     4917webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/gamepads-module [ Skip ]
     4918webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/hit-test [ Skip ]
     4919
     4920# WebXR - These currently timeout due to missing features.
     4921webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/events_referenceSpace_reset_immersive.https.html [ Skip ]
     4922webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/events_referenceSpace_reset_inline.https.html [ Skip ]
     4923webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/getInputPose_pointer.https.html [ Skip ]
     4924webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/xrDevice_disconnect_ends.https.html [ Skip ]
     4925webkit.org/b/208988 http/wpt/webxr/xrSession_ended_by_system.https.html [ Skip ]
     4926webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/events_input_source_recreation.https.html [ Skip ]
     4927webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/events_input_sources_change.https.html [ Skip ]
     4928webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/events_session_select.https.html [ Skip ]
     4929webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/events_session_squeeze.https.html [ Skip ]
     4930webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/xrSession_requestAnimationFrame_data_valid.https.html [ Skip ]
     4931webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/xrView_match.https.html [ Skip ]
     4932webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/xrViewport_valid.https.html [ Skip ]
     4933webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/xrRigidTransform_inverse.https.html [ Skip ]
     4934webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/xrSession_visibilityState.https.html [ Skip ]
     4935webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/xrView_sameObject.https.html [ Skip ]
     4936
     4937# WebXR - expected to fail.
     4938webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/exclusive_requestFrame_nolayer.https.html [ Skip ]
     4939webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/xrPose_transform_sameObject.https.html [ Skip ]
     4940webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/xrReferenceSpace_originOffset.https.html [ Skip ]
     4941webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/xrSession_requestReferenceSpace_features.https.html [ Skip ]
     4942webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/xrSession_sameObject.https.html [ Skip ]
     4943webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/xrSession_viewer_referenceSpace.https.html [ Skip ]
     4944webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/getInputPose_handedness.https.html [ Skip ]
     4945webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/webxr_feature_policy.https.html [ Skip ]
     4946webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/xrDevice_requestSession_requiredFeatures_unknown.https.html [ Skip ]
     4947webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/xrInputSource_add_remove.https.html [ Skip ]
     4948webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/xrInputSource_emulatedPosition.https.html [ Skip ]
     4949webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/xrView_eyes.https.html [ Skip ]
     4950webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/xrView_oneframeupdate.https.html [ Skip ]
     4951webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/xrWebGLLayer_framebuffer_draw.https.html [ Skip ]
     4952webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/xrWebGLLayer_opaque_framebuffer.https.html [ Skip ]
     4953webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/xrStationaryReferenceSpace_floorlevel_updates.https.html [ Skip ]
     4954webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/xrSession_cancelAnimationFrame_invalidhandle.https.html [ Skip ]
     4955webkit.org/b/208988 imported/w3c/web-platform-tests/webxr/xrWebGLLayer_opaque_framebuffer_stencil.https.html [ Skip ]
  • trunk/LayoutTests/fast/dom/navigator-detached-no-crash-expected.txt

    r267988 r277468  
    3131navigator.vendorSub is OK
    3232navigator.webdriver is OK
     33navigator.xr is OK
    3334navigator.appCodeName is OK
    3435navigator.appName is OK
    … …  
    5960navigator.vendorSub is OK
    6061navigator.webdriver is OK
     62navigator.xr is OK
    6163
  • trunk/LayoutTests/imported/w3c/ChangeLog

    r277430 r277468  
     12021-05-13  Dean Jackson  <dino@apple.com>
     2
     3        [WebXR] Allow WebXR to be tested on PLATFORM(COCOA)
     4        https://bugs.webkit.org/show_bug.cgi?id=225578
     5
     6        Reviewed by Sam Weinig.
     7
     8        New expected results.
     9
     10        * web-platform-tests/webxr/exclusive_requestFrame_nolayer.https-expected.txt: Added.
     11        * web-platform-tests/webxr/render_state_vertical_fov_inline.https-expected.txt: Added.
     12        * web-platform-tests/webxr/webxr-supported-by-feature-policy-expected.txt: Added.
     13        * web-platform-tests/webxr/webxr_availability.http.sub-expected.txt: Added.
     14        * web-platform-tests/webxr/webxr_feature_policy.https-expected.txt: Added.
     15        * web-platform-tests/webxr/xrFrame_lifetime.https-expected.txt: Added.
     16        * web-platform-tests/webxr/xrPose_transform_sameObject.https-expected.txt: Added.
     17        * web-platform-tests/webxr/xrReferenceSpace_originOffsetBounded.https-expected.txt: Added.
     18        * web-platform-tests/webxr/xrSession_input_events_end.https-expected.txt: Added.
     19        * web-platform-tests/webxr/xrSession_visibilityState.https-expected.txt: Added.
     20        * web-platform-tests/webxr/xrStationaryReferenceSpace_floorlevel_updates.https-expected.txt: Added.
     21        * web-platform-tests/webxr/xrWebGLLayer_framebuffer_scale.https-expected.txt: Added.
     22        * web-platform-tests/webxr/xrWebGLLayer_opaque_framebuffer_stencil.https-expected.txt: Added.
     23
    1242021-05-13  Martin Robinson  <mrobinson@webkit.org>
    225
  • trunk/LayoutTests/imported/w3c/web-platform-tests/webxr/idlharness.https.window-expected.txt

    r267649 r277468  
    134134PASS XRView interface: attribute projectionMatrix
    135135PASS XRView interface: attribute transform
     136PASS XRView interface: attribute recommendedViewportScale
     137PASS XRView interface: operation requestViewportScale(double?)
    136138PASS XRViewport interface: existence and properties of interface object
    137139PASS XRViewport interface object length
  • trunk/LayoutTests/platform/mac-wk1/fast/dom/navigator-detached-no-crash-expected.txt

    r268735 r277468  
    2323navigator.vendorSub is OK
    2424navigator.webdriver is OK
     25navigator.xr is OK
    2526navigator.appCodeName is OK
    2627navigator.appName is OK
    … …  
    4546navigator.vendorSub is OK
    4647navigator.webdriver is OK
     48navigator.xr is OK
    4749
  • trunk/LayoutTests/platform/mac-wk2/fast/dom/navigator-detached-no-crash-expected.txt

    r271204 r277468  
    3434navigator.vendorSub is OK
    3535navigator.webdriver is OK
     36navigator.xr is OK
    3637navigator.appCodeName is OK
    3738navigator.appName is OK
    … …  
    6768navigator.vendorSub is OK
    6869navigator.webdriver is OK
     70navigator.xr is OK
    6971
  • trunk/LayoutTests/platform/mac/TestExpectations

    r277455 r277468  
    21932193webkit.org/b/223759 [ BigSur Debug ] http/tests/security/webaudio-render-remote-audio-blocked-no-crossorigin-redirect.html [ Pass Timeout ]
    21942194
    2195 webkit.org/b/222239 fast/canvas/webgl/context-creation-attributes.html [ Pass Failure ]
    21962195webkit.org/b/222239 fast/canvas/webgl/webgl2-texture-upload-enums.html [ Pass Failure ]
    21972196webkit.org/b/222239 webgl/2.0.0/conformance2/extensions/promoted-extensions-in-shaders.html [ Pass Failure ]
  • trunk/LayoutTests/platform/mac/fast/dom/navigator-detached-no-crash-expected.txt

    r267988 r277468  
    2727navigator.vendorSub is OK
    2828navigator.webdriver is OK
     29navigator.xr is OK
    2930navigator.appCodeName is OK
    3031navigator.appName is OK
    … …  
    5253navigator.vendorSub is OK
    5354navigator.webdriver is OK
     55navigator.xr is OK
    5456
  • trunk/LayoutTests/platform/wpe/TestExpectations

    r277223 r277468  
    10241024fast/canvas/toDataURL-supportedTypes.html [ Failure ]
    10251025fast/canvas/webgl/antialiasing-enabled.html [ Failure ]
    1026 fast/canvas/webgl/context-creation-attributes.html [ Failure ]
    10271026fast/canvas/webgl/multisample-resolve-consistency.html [ Failure ]
    10281027fast/canvas/webgl/premultiplyalpha-test.html [ Failure ]
  • trunk/Source/WTF/ChangeLog

    r277449 r277468  
     12021-05-13  Dean Jackson  <dino@apple.com>
     2
     3        [WebXR] Allow WebXR to be tested on PLATFORM(COCOA)
     4        https://bugs.webkit.org/show_bug.cgi?id=225578
     5
     6        Reviewed by Sam Weinig.
     7
     8        Compile-time enabled on all Cocoa platforms.
     9
     10        * wtf/PlatformEnableCocoa.h:
     11
    1122021-05-13  Chris Dumez  <cdumez@apple.com>
    213
  • trunk/Source/WTF/wtf/PlatformEnableCocoa.h

    r276887 r277468  
    600600#endif
    601601
    602 #if !defined(ENABLE_WEBXR) && HAVE(WEBXR_INTERNALS)
     602#if !defined(ENABLE_WEBXR)
    603603#define ENABLE_WEBXR 1
    604604#endif
  • trunk/Source/WTF/wtf/PlatformUse.h

    r277099 r277468  
    323323#define USE_OPENXR 0
    324324#define USE_IOSURFACE_FOR_XR_LAYER_DATA 1
     325#if !defined(HAVE_WEBXR_INTERNALS) && !HAVE(WEBXR_INTERNALS)
     326#define USE_EMPTYXR 1
     327#endif
    325328#endif
    326329
  • trunk/Source/WebCore/Modules/webxr/WebXRInputSource.h

    r277251 r277468  
    6363    WebXRSpace* gripSpace() const { return m_gripSpace.get(); }
    6464    const Vector<String>& profiles() const { return m_source.profiles; };
     65    double connectTime() const { return m_connectTime; }
    6566#if ENABLE(GAMEPAD)
    6667    const Gamepad* gamepad() const { return m_gamepad.ptr(); }
  • trunk/Source/WebCore/platform/xr/cocoa/PlatformXRCocoa.h

    r275835 r277468  
    2626#pragma once
    2727
    28 #if ENABLE(WEBXR) && PLATFORM(COCOA)
     28#if ENABLE(WEBXR) && USE(EMPTYXR)
    2929#include "PlatformXR.h"
    30 #include <WebKitAdditions/PlatformXRAdditions.h>
    3130#endif
  • trunk/Source/WebCore/platform/xr/cocoa/PlatformXRCocoa.mm

    r270159 r277468  
    2727#import "PlatformXRCocoa.h"
    2828
    29 #if ENABLE(WEBXR) && PLATFORM(COCOA)
     29#if ENABLE(WEBXR) && USE(EMPTYXR)
    3030
    31 #import <WebKitAdditions/PlatformXRAdditions.mm>
     31#import <wtf/NeverDestroyed.h>
     32
     33using namespace WebCore;
     34
     35namespace PlatformXR {
     36
     37struct Instance::Impl {
     38    WTF_MAKE_FAST_ALLOCATED;
     39public:
     40    Impl() = default;
     41    ~Impl() = default;
     42};
     43
     44Instance& Instance::singleton()
     45{
     46    static LazyNeverDestroyed<Instance> s_instance;
     47    static std::once_flag s_onceFlag;
     48    std::call_once(s_onceFlag,
     49        [&] {
     50            s_instance.construct();
     51        });
     52    return s_instance.get();
     53}
     54
     55Instance::Instance()
     56    : m_impl(makeUniqueRef<Impl>())
     57{
     58}
     59
     60void Instance::enumerateImmersiveXRDevices(CompletionHandler<void(const DeviceList& devices)>&& callback)
     61{
     62    callback({ });
     63}
     64
     65}
    3266
    3367#endif
  • trunk/Source/WebKit/ChangeLog

    r277464 r277468  
     12021-05-13  Dean Jackson  <dino@apple.com>
     2
     3        [WebXR] Allow WebXR to be tested on PLATFORM(COCOA)
     4        https://bugs.webkit.org/show_bug.cgi?id=225578
     5
     6        Reviewed by Sam Weinig.
     7
     8        Remove checking for a WebXR feature flag.
     9
     10        * Shared/WebPreferencesDefaultValues.cpp:
     11        (WebKit::defaultWebXREnabled):
     12
    1132021-05-13  Tim Horton  <timothy_horton@apple.com>
    214
  • trunk/Source/WebKit/Shared/WebPreferencesDefaultValues.cpp

    r276566 r277468  
    268268#if HAVE(WEBXR_INTERNALS)
    269269    return true;
    270 #elif HAVE(SYSTEM_FEATURE_FLAGS)
    271     return isFeatureFlagEnabled("WebXR");
    272270#else
    273271    return false;
Note: See TracChangeset for help on using the changeset viewer.