Class WebXRHand
Hierarchy
- WebXRHand
Implements
Index
Constructors
Properties
Accessors
Methods
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 rig MappingSearch 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 xr ControllerSearch playground for xrController
The controller to which the hand correlates.
Accessors
hand Mesh
-
Get the hand mesh.
Returns Nullable<AbstractMesh>
Methods
disposeSearch playground for dispose
-
Dispose this Hand object
Returns void
get Hand Part MeshesSearch 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.
-
get Joint MeshSearch playground for getJointMesh
-
Retrieves a mesh linked to a named joint in the hand.
Parameters
-
jointName: XRHandJoint
The name of the joint.
Returns AbstractMesh
An AbstractMesh whose position corresponds with the joint position.
-
set Hand MeshSearch playground for setHandMesh
-
Sets the current hand mesh to render for the WebXRHand.
Parameters
-
handMesh: AbstractMesh
The rigged hand mesh that will be tracked to the user's hand.
-
rigMapping: Nullable<XRHandMeshRigMapping>
The mapping from XRHandJoint to bone names to use with the mesh.
Returns void
-
update FromXRFrameSearch 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
-
Representing a single hand (with its corresponding native XRHand object)