Options
All
  • Public
  • Public/Protected
  • All
Menu

Class WebXRHand

Representing a single hand (with its corresponding native XRHand object)

Hierarchy

  • WebXRHand

Implements

Index

Constructors

constructor

  • Construct a new hand object

    Parameters

    • xrController: WebXRInputSource

      The controller to which the hand correlates.

    • _jointMeshes: AbstractMesh[]

      The meshes to be used to track the hand joints.

    • _handMesh: Nullable<AbstractMesh>

      An optional hand mesh.

    • rigMapping: Nullable<XRHandMeshRigMapping>

      An optional rig mapping for the hand mesh. If not provided (but a hand mesh is provided), it will be assumed that the hand mesh's bones are named directly after the WebXR bone names.

    • Optional _leftHandedMeshes: boolean

      Are the hand meshes left-handed-system meshes

    • Optional _jointsInvisible: boolean

      Are the tracked joint meshes visible

    • Optional _jointScaleFactor: number

      Scale factor for all joint meshes

    Returns WebXRHand

Properties

Readonly rigMappingSearch playground for rigMapping

An optional rig mapping for the hand mesh. If not provided (but a hand mesh is provided), it will be assumed that the hand mesh's bones are named directly after the WebXR bone names.

Readonly xrControllerSearch playground for xrController

xrController: WebXRInputSource

The controller to which the hand correlates.

Accessors

handMesh

Methods

disposeSearch playground for dispose

  • dispose(): void
  • Dispose this Hand object

    Returns void

getHandPartMeshesSearch playground for getHandPartMeshes

  • Get meshes of part of the hand.

    Parameters

    • part: HandPart

      The part of hand to get.

    Returns AbstractMesh[]

    An array of meshes that correlate to the hand part requested.

getJointMeshSearch playground for getJointMesh

  • Retrieves a mesh linked to a named joint in the hand.

    Parameters

    Returns AbstractMesh

    An AbstractMesh whose position corresponds with the joint position.

setHandMeshSearch playground for setHandMesh

  • Sets the current hand mesh to render for the WebXRHand.

    Parameters

    Returns void

updateFromXRFrameSearch playground for updateFromXRFrame

  • Update this hand from the latest xr frame.

    Parameters

    • xrFrame: XRFrame

      The latest frame received from WebXR.

    • referenceSpace: XRReferenceSpace

      The current viewer reference space.

    Returns void

Legend

  • Constructor
  • Property
  • Method
  • Property
  • Method
  • Inherited property
  • Inherited method
  • Static property
  • Static method