Class XRHandTracker
- Namespace
- Godot
- Assembly
- GodotSharp.dll
A hand tracking system will create an instance of this object and add it to the XRServer. This tracking system will then obtain skeleton data, convert it to the Godot Humanoid hand skeleton and store this data on the XRHandTracker object.
Use XRHandModifier3D to animate a hand mesh using hand tracking data.
public class XRHandTracker : XRPositionalTracker, IDisposable
- Inheritance
-
XRHandTracker
- Implements
- Inherited Members
Constructors
XRHandTracker()
public XRHandTracker()
Properties
HandTrackingSource
The source of the hand tracking data.
public XRHandTracker.HandTrackingSourceEnum HandTrackingSource { get; set; }
Property Value
HasTrackingData
If true, the hand tracking data is valid.
public bool HasTrackingData { get; set; }
Property Value
Methods
GetHandJointAngularVelocity(HandJoint)
Returns the angular velocity for the given hand joint.
public Vector3 GetHandJointAngularVelocity(XRHandTracker.HandJoint joint)
Parameters
joint
XRHandTracker.HandJoint
Returns
GetHandJointFlags(HandJoint)
Returns flags about the validity of the tracking data for the given hand joint (see XRHandTracker.HandJointFlags).
public XRHandTracker.HandJointFlags GetHandJointFlags(XRHandTracker.HandJoint joint)
Parameters
joint
XRHandTracker.HandJoint
Returns
GetHandJointLinearVelocity(HandJoint)
Returns the linear velocity for the given hand joint.
public Vector3 GetHandJointLinearVelocity(XRHandTracker.HandJoint joint)
Parameters
joint
XRHandTracker.HandJoint
Returns
GetHandJointRadius(HandJoint)
Returns the radius of the given hand joint.
public float GetHandJointRadius(XRHandTracker.HandJoint joint)
Parameters
joint
XRHandTracker.HandJoint
Returns
GetHandJointTransform(HandJoint)
Returns the transform for the given hand joint.
public Transform3D GetHandJointTransform(XRHandTracker.HandJoint joint)
Parameters
joint
XRHandTracker.HandJoint
Returns
HasGodotClassMethod(in godot_string_name)
Check if the type contains a method with the given name. This method is used by Godot to check if a method exists before invoking it. Do not call or override this method.
protected override bool HasGodotClassMethod(in godot_string_name method)
Parameters
method
godot_string_nameName of the method to check for.
Returns
HasGodotClassSignal(in godot_string_name)
Check if the type contains a signal with the given name. This method is used by Godot to check if a signal exists before raising it. Do not call or override this method.
protected override bool HasGodotClassSignal(in godot_string_name signal)
Parameters
signal
godot_string_nameName of the signal to check for.
Returns
InvokeGodotClassMethod(in godot_string_name, NativeVariantPtrArgs, out godot_variant)
Invokes the method with the given name, using the given arguments. This method is used by Godot to invoke methods from the engine side. Do not call or override this method.
protected override bool InvokeGodotClassMethod(in godot_string_name method, NativeVariantPtrArgs args, out godot_variant ret)
Parameters
method
godot_string_nameName of the method to invoke.
args
NativeVariantPtrArgsArguments to use with the invoked method.
ret
godot_variantValue returned by the invoked method.
Returns
SetHandJointAngularVelocity(HandJoint, Vector3)
Sets the angular velocity for the given hand joint.
public void SetHandJointAngularVelocity(XRHandTracker.HandJoint joint, Vector3 angularVelocity)
Parameters
joint
XRHandTracker.HandJointangularVelocity
Vector3
SetHandJointFlags(HandJoint, HandJointFlags)
Sets flags about the validity of the tracking data for the given hand joint.
public void SetHandJointFlags(XRHandTracker.HandJoint joint, XRHandTracker.HandJointFlags flags)
Parameters
joint
XRHandTracker.HandJointflags
XRHandTracker.HandJointFlags
SetHandJointLinearVelocity(HandJoint, Vector3)
Sets the linear velocity for the given hand joint.
public void SetHandJointLinearVelocity(XRHandTracker.HandJoint joint, Vector3 linearVelocity)
Parameters
joint
XRHandTracker.HandJointlinearVelocity
Vector3
SetHandJointRadius(HandJoint, float)
Sets the radius of the given hand joint.
public void SetHandJointRadius(XRHandTracker.HandJoint joint, float radius)
Parameters
joint
XRHandTracker.HandJointradius
float
SetHandJointTransform(HandJoint, Transform3D)
Sets the transform for the given hand joint.
public void SetHandJointTransform(XRHandTracker.HandJoint joint, Transform3D transform)
Parameters
joint
XRHandTracker.HandJointtransform
Transform3D