API reference
API reference
Select your platform
No SDKs available
No versions available

SyntheticHand Class

Used primarily for touch limiting during pokes and custom poses during grabs.
Alters hand data piped into this modifier to lock and unlock joints (wrist position and rotation, finger joint rotations). When switching between locked and unlocked states, additionally smooths out transitions by easing between source hand data and target hand data.

Fields

UpdateRequired : System.Action
Signature
System.Action Oculus.Interaction.Input.SyntheticHand.UpdateRequired

Protected Methods

Apply ( data )
Signature
override void Oculus.Interaction.Input.SyntheticHand.Apply(HandDataAsset data)
Parameters
Returns
override void
Start ()
Signature
override void Oculus.Interaction.Input.SyntheticHand.Start()
Returns
override void

Methods

FreeAllJoints ()
Short-hand method for setting the freedom level of all fingers in a hand to Free.
Similar to calling SetFingerFreedom for each single finger in the hand with a value of FingerFreedom.Free for the freedomLevel
Signature
void Oculus.Interaction.Input.SyntheticHand.FreeAllJoints()
Returns
void
FreeWrist ( lockMode )
Unlocks the hand (locked at the OverrideWristPose method) starting a timer for the smooth release animation.
Signature
void Oculus.Interaction.Input.SyntheticHand.FreeWrist(WristLockMode lockMode=WristLockMode.Full)
Parameters
lockMode: WristLockMode
Returns
void
GetJointFreedom ( jointId )
Signature
JointFreedom Oculus.Interaction.Input.SyntheticHand.GetJointFreedom(in HandJointId jointId)
Parameters
jointId: in HandJointId
Returns
JointFreedom
InjectAllSyntheticHandModifier ( updateMode , updateAfter , modifyDataFromSource , applyModifier , wristPositionLockCurve , wristPositionUnlockCurve , wristRotationLockCurve , wristRotationUnlockCurve , jointLockCurve , jointUnlockCurve , spreadAllowance )
Signature
void Oculus.Interaction.Input.SyntheticHand.InjectAllSyntheticHandModifier(UpdateModeFlags updateMode, IDataSource updateAfter, DataModifier< HandDataAsset > modifyDataFromSource, bool applyModifier, ProgressCurve wristPositionLockCurve, ProgressCurve wristPositionUnlockCurve, ProgressCurve wristRotationLockCurve, ProgressCurve wristRotationUnlockCurve, ProgressCurve jointLockCurve, ProgressCurve jointUnlockCurve, float spreadAllowance)
Parameters
updateMode: UpdateModeFlags
updateAfter: IDataSource
modifyDataFromSource: DataModifier< HandDataAsset >
applyModifier: bool
wristPositionLockCurve: ProgressCurve
wristPositionUnlockCurve: ProgressCurve
wristRotationLockCurve: ProgressCurve
wristRotationUnlockCurve: ProgressCurve
jointLockCurve: ProgressCurve
jointUnlockCurve: ProgressCurve
spreadAllowance: float
Returns
void
InjectJointLockCurve ( jointLockCurve )
Signature
void Oculus.Interaction.Input.SyntheticHand.InjectJointLockCurve(ProgressCurve jointLockCurve)
Parameters
jointLockCurve: ProgressCurve
Returns
void
InjectJointUnlockCurve ( jointUnlockCurve )
Signature
void Oculus.Interaction.Input.SyntheticHand.InjectJointUnlockCurve(ProgressCurve jointUnlockCurve)
Parameters
jointUnlockCurve: ProgressCurve
Returns
void
InjectSpreadAllowance ( spreadAllowance )
Signature
void Oculus.Interaction.Input.SyntheticHand.InjectSpreadAllowance(float spreadAllowance)
Parameters
spreadAllowance: float
Returns
void
InjectWristPositionLockCurve ( wristPositionLockCurve )
Signature
void Oculus.Interaction.Input.SyntheticHand.InjectWristPositionLockCurve(ProgressCurve wristPositionLockCurve)
Parameters
wristPositionLockCurve: ProgressCurve
Returns
void
InjectWristPositionUnlockCurve ( wristPositionUnlockCurve )
Signature
void Oculus.Interaction.Input.SyntheticHand.InjectWristPositionUnlockCurve(ProgressCurve wristPositionUnlockCurve)
Parameters
wristPositionUnlockCurve: ProgressCurve
Returns
void
InjectWristRotationLockCurve ( wristRotationLockCurve )
Signature
void Oculus.Interaction.Input.SyntheticHand.InjectWristRotationLockCurve(ProgressCurve wristRotationLockCurve)
Parameters
wristRotationLockCurve: ProgressCurve
Returns
void
InjectWristRotationUnlockCurve ( wristRotationUnlockCurve )
Signature
void Oculus.Interaction.Input.SyntheticHand.InjectWristRotationUnlockCurve(ProgressCurve wristRotationUnlockCurve)
Parameters
wristRotationUnlockCurve: ProgressCurve
Returns
void
LockFingerAtCurrent ( finger )
Immediately locks an individual finger (all its internal joints) at the last known value.
Signature
void Oculus.Interaction.Input.SyntheticHand.LockFingerAtCurrent(in HandFinger finger)
Parameters
finger: in HandFinger  The finger for which to lock joints.
Returns
void
LockJoint ( jointId , rotation , overrideFactor )
Signature
void Oculus.Interaction.Input.SyntheticHand.LockJoint(in HandJointId jointId, Quaternion rotation, float overrideFactor=1f)
Parameters
jointId: in HandJointId
rotation: Quaternion
overrideFactor: float
Returns
void
LockWristPose ( wristPose , overrideFactor , lockMode , worldPose , skipAnimation )
Stores the desired pose to set the wrist of the hand to.
This is not necessarily the final pose of the hand, as it allows lerping between the tracked and provided one during the ApplyHand phase.
To ensure the hand is locked at the desired pose, pass a value of 1 in the overrideFactor
Signature
void Oculus.Interaction.Input.SyntheticHand.LockWristPose(Pose wristPose, float overrideFactor=1f, WristLockMode lockMode=WristLockMode.Full, bool worldPose=false, bool skipAnimation=false)
Parameters
wristPose: Pose  The final pose desired for the wrist
overrideFactor: float  How much to lerp between the tracked and the provided pose
lockMode: WristLockMode  Either lock the position, rotation or both (default)
worldPose: bool
skipAnimation: bool  Whether to skip the animation curve for this override.
Returns
void
LockWristPosition ( position , overrideFactor , skipAnimation )
Signature
void Oculus.Interaction.Input.SyntheticHand.LockWristPosition(Vector3 position, float overrideFactor=1f, bool skipAnimation=false)
Parameters
position: Vector3
overrideFactor: float
skipAnimation: bool
Returns
void
LockWristRotation ( rotation , overrideFactor , skipAnimation )
Signature
void Oculus.Interaction.Input.SyntheticHand.LockWristRotation(Quaternion rotation, float overrideFactor=1f, bool skipAnimation=false)
Parameters
rotation: Quaternion
overrideFactor: float
skipAnimation: bool
Returns
void
OverrideAllJoints ( jointRotations , overrideFactor )
Stores the rotation data for all joints in the hand, to be applied during the ApplyHand event.
Signature
void Oculus.Interaction.Input.SyntheticHand.OverrideAllJoints(in Quaternion[] jointRotations, float overrideFactor)
Parameters
jointRotations: in Quaternion[]  The joint rotations following the FingersMetadata.HAND_JOINT_IDS format.
overrideFactor: float  How much to lerp the fingers from the tracked (raw) state to the provided one.
Returns
void
OverrideFingerRotations ( finger , rotations , overrideFactor )
Stores the rotation data for all joints for the given finger, to be applied during the ApplyHand event.
Signature
void Oculus.Interaction.Input.SyntheticHand.OverrideFingerRotations(HandFinger finger, Quaternion[] rotations, float overrideFactor)
Parameters
finger: HandFinger  The finger for which to lock joints.
rotations: Quaternion[]  The joint rotations for each joint on the finger
overrideFactor: float  How much to lerp the fingers from the tracked (raw) state to the provided one.
Returns
void
OverrideJointRotation ( jointId , rotation , overrideFactor )
Signature
void Oculus.Interaction.Input.SyntheticHand.OverrideJointRotation(HandJointId jointId, Quaternion rotation, float overrideFactor)
Parameters
jointId: HandJointId
rotation: Quaternion
overrideFactor: float
Returns
void
SetFingerFreedom ( finger , freedomLevel , skipAnimation )
To use in conjunction with OverrideAllJoints, it sets the freedom state for a provided finger.
Opposite to LockFingerAtCurrent, this method uses the data provided in OverrideAllJoints instead of the last known state.
Signature
void Oculus.Interaction.Input.SyntheticHand.SetFingerFreedom(in HandFinger finger, in JointFreedom freedomLevel, bool skipAnimation=false)
Parameters
finger: in HandFinger
freedomLevel: in JointFreedom  The freedom level for the finger
skipAnimation: bool
Returns
void
SetJointFreedom ( jointId , freedomLevel , skipAnimation )
Signature
void Oculus.Interaction.Input.SyntheticHand.SetJointFreedom(in HandJointId jointId, in JointFreedom freedomLevel, bool skipAnimation=false)
Parameters
jointId: in HandJointId
freedomLevel: in JointFreedom
skipAnimation: bool
Returns
void

Inner Enum

WristLockMode Enum

Enumeration Constants

MemberValue
Position
1 << 0
Rotation
1 << 1
Full
(1 << 2) - 1