Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
WebXR: experimental DOM Overlay support for immersive-ar mode
This opt-in mode keeps DOM content visible as a transparent overlay while in an immersive-ar WebXR session. It is activated by requesting an optional or required feature on session start: navigator.xr.requestSession( 'immersive-ar', {optionalFeatures: ['dom-overlay-for-handheld-ar']}); This functionality is only available if the corresponding feature flag chrome://flags#webxr-ar-dom-overlay is enabled. On session start, this fullscreens the <body> element. The application can use the Fullscreen API to change the visible element. Exiting the session ends fullscreen mode, and calling document.exitFullscreen() exits the immersive-ar session if there are no remaining fullscreened elements. (As of this CL, changing the fullscreen element doesn't fully update layer visibility, so non-fullscreen content can remain visible unexpectedly. That's being addressed in a followup.) Change-Id: I77b767b111436b45e2b584e46a390a68473ab118 Bug: 991747
- Loading branch information