Interface: WebXROptions
Defined in: src/core/WebXR.ts:37
Options for enableXR / WebXRSession.
Properties
camera?
optionalcamera:Camera
Defined in: src/core/WebXR.ts:45
Camera to render with. Overrides the scene's own camera when provided.
mode?
optionalmode:XRSessionMode
Defined in: src/core/WebXR.ts:39
Session mode. Defaults to 'immersive-vr'.
onExit()?
optionalonExit: () =>void
Defined in: src/core/WebXR.ts:52
Called after the session ends and the desktop state is restored.
Returns
void
onFrame()?
optionalonFrame: (time,frame) =>void
Defined in: src/core/WebXR.ts:50
Called once per XR frame, after the scene is rendered. Use it to advance animation state while an immersive session drives the render loop.
Parameters
time
number
frame
XRFrame
Returns
void
referenceSpaceType?
optionalreferenceSpaceType:XRReferenceSpaceType
Defined in: src/core/WebXR.ts:43
Reference space type for the session. Defaults to 'local-floor'.
sessionInit?
optionalsessionInit:XRSessionInit
Defined in: src/core/WebXR.ts:41
Extra WebXR features to request (forwarded to requestSession).