Class WebXREnterExitUI
Hierarchy
- WebXREnterExitUI
Implements
Index
Constructors
Properties
Methods
Constructors
constructor
-
Construct a new EnterExit UI class
Parameters
-
scene: Scene
babylon scene object to use
-
options: WebXREnterExitUIOptions
(read-only) version of the options passed to this UI
Returns WebXREnterExitUI
-
Properties
active Button Changed ObservableSearch playground for activeButtonChangedObservable
Fired every time the active button is changed.
When xr is entered via a button that launches xr that button will be the callback parameter
When exiting xr the callback parameter will be null)
optionsSearch playground for options
version of the options passed to this UI
Readonly overlaySearch playground for overlay
The HTML Div Element to which buttons are added.
Methods
disposeSearch playground for dispose
-
Disposes of the XR UI component
Returns void
set Helper AsyncSearch playground for setHelperAsync
-
Set the helper to be used with this UI component. The UI is bound to an experience helper. If not provided the UI can still be used but the events should be registered by the developer.
Parameters
-
helper: WebXRExperienceHelper
the experience helper to attach
-
Optional renderTarget: WebXRRenderTarget
an optional render target (in case it is created outside of the helper scope)
Returns Promise<void>
a promise that resolves when the ui is ready
-
Static Create AsyncSearch playground for CreateAsync
-
Creates UI to allow the user to enter/exit XR mode
Parameters
-
scene: Scene
the scene to add the ui to
-
helper: WebXRExperienceHelper
the xr experience helper to enter/exit xr with
-
options: WebXREnterExitUIOptions
options to configure the UI
Returns Promise<WebXREnterExitUI>
the created ui
-
UI to allow the user to enter/exit XR mode