WebXRGenericTriggerMotionController

A generic trigger-only motion controller for WebXR

Hierarchy

Implements

Index

Constructors

constructor

Find examples in Playground

Properties

components

Find examples in Playground
components: object

A map of components (WebXRControllerComponent) in this motion controller Components have a ComponentType and can also have both button and axis definitions

Type declaration

gamepadObject

Find examples in Playground

The gamepad object correlating to this controller

handness

Find examples in Playground

handness (left/right/none) of this controller

onModelLoadedObservable

Find examples in Playground
onModelLoadedObservable: Observable<WebXRAbstractMotionController>

Observers registered here will be triggered when the model of this controller is done loading

profileId

Find examples in Playground
profileId: string

rootMesh

Find examples in Playground

The root mesh of the model. It is null if the model was not yet initialized

Static ComponentType

Find examples in Playground
ComponentType: object

Component type map

Type declaration

  • BUTTON: string
  • SQUEEZE: string
  • THUMBSTICK: string
  • TOUCHPAD: string
  • TRIGGER: string

Static ProfileId

Find examples in Playground
ProfileId: string

Static version of the profile id of this controller

Methods

dispose

Find examples in Playground
  • dispose(): void

getComponent

Find examples in Playground

getComponentTypes

Find examples in Playground
  • getComponentTypes(): string[]

getMainComponent

Find examples in Playground

loadModel

Find examples in Playground
  • loadModel(): Promise<boolean>
  • Loads the model correlating to this controller When the mesh is loaded, the onModelLoadedObservable will be triggered

    Returns Promise<boolean>

    A promise fulfilled with the result of the model loading

updateFromXRFrame

Find examples in Playground
  • updateFromXRFrame(xrFrame: XRFrame): void

Generated using TypeDoc