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

DistanceHandGrabInteractable Class

The DistanceHandGrabInteractable allows grabbing the marked object from far away.
Internally it uses HandGrabPoses to specify not only the poses of the hands but the required gestures to perform the grab. It is recommended to reuse the same HandGrabPoses used by the HandGrabInteractable, and even select just a few so they become the default poses when distant grabbing.

Fields

HandGrabPoses : List< HandGrabPose >
Retrieves the list of HandGrabPoses which can be used to grab this interactable.
This returns the value of the _handGrabPoses field, which is typically set from the UnityEditor.
Signature
List<HandGrabPose> Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.HandGrabPoses
PalmGrabRules : GrabbingRule
Implementation of IHandGrabInteractable.PalmGrabRules; for details, please refer to the related documentation provided for that interface.
Signature
GrabbingRule Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.PalmGrabRules
PinchGrabRules : GrabbingRule
Implementation of IHandGrabInteractable.PinchGrabRules; for details, please refer to the related documentation provided for that interface.
Signature
GrabbingRule Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.PinchGrabRules
RelativeTo : Transform
Implementation of IRelativeToRef.RelativeTo; for details, please refer to the related documentation provided for that interface.
Signature
Transform Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.RelativeTo
Rigidbody : Rigidbody
The Unity Rigidbody used for collision detection.
The returned value is from the _rigidbody field, which is set from the UnityEditor.
Signature
Rigidbody Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.Rigidbody
SupportedGrabTypes : GrabTypeFlags
Implementation of IHandGrabInteractable.SupportedGrabTypes; for details, please refer to the related documentation provided for that interface.
Signature
GrabTypeFlags Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.SupportedGrabTypes
UsesHandPose : bool
Implementation of IHandGrabInteractable.UsesHandPose; for details, please refer to the related documentation provided for that interface.
Signature
bool Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.UsesHandPose

Properties

Colliders : Collider []
[Get]
The list of Unity Colliders associated with this interactable.
This list is automatically populated during the MonoBehaviour's start-up process and will contain a reference to every Collider in Rigidbody's hierarchy at that time. This list is not allowed to be empty, meaning there must be at least one Collider in Rigidbody's hierarchy at the time the DistanceHandGrabInteractable first becomes active.
Signature
Collider [] Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.Colliders
HandAlignment : HandAlignType
[Get][Set]
Implementation of IHandGrabInteractable.HandAlignment; for details, please refer to the related documentation provided for that interface.
Signature
HandAlignType Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.HandAlignment
MovementProvider : IMovementProvider
[Get][Set]
The IMovementProvider used to move this interactable.
This value is populated during the MonoBehaviour's start-up process from the _movementProvider field, which is set from the UnityEditor. Manually specifying this value is optional; if none is provided, a MoveTowardsTargetProvider will be created during start-up for this role.
Signature
IMovementProvider Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.MovementProvider
ResetGrabOnGrabsUpdated : bool
[Get][Set]
Related to GrabInteractable.ResetGrabOnGrabsUpdated; forces a release on all other grabbing interactors when grabbed by a new interactor.
Signature
bool Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.ResetGrabOnGrabsUpdated
Slippiness : float
[Get][Set]
Implementation of IHandGrabInteractable.Slippiness; for details, please refer to the related documentation provided for that interface.
Signature
float Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.Slippiness

Protected Methods

Awake ()
Signature
override void Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.Awake()
Returns
override void
Reset ()
Signature
virtual void Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.Reset()
Returns
void
Start ()
Signature
override void Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.Start()
Returns
override void

Methods

ApplyVelocities ( linearVelocity , angularVelocity )
Obsolete: this was used to apply velocities from an Throw.IThrowVelocityCalculator, which is deprecated.
Velocity calculation capabilities are now a feature of Grabbable and should be controlled from there.
Signature
void Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.ApplyVelocities(Vector3 linearVelocity, Vector3 angularVelocity)
Parameters
linearVelocity: Vector3
angularVelocity: Vector3
Returns
void
CalculateBestPose ( userPose , handScale , handedness , result )
Implementation of IHandGrabInteractable.CalculateBestPose(Pose, float, Handedness, ref HandGrabResult); for details, please refer to the related documentation provided for that interface.
Signature
bool Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.CalculateBestPose(Pose userPose, float handScale, Handedness handedness, ref HandGrabResult result)
Parameters
userPose: Pose
handScale: float
handedness: Handedness
result: ref HandGrabResult
Returns
bool
CalculateBestPose ( userPose , offset , relativeTo , handScale , handedness , result )
Implementation of IHandGrabInteractable.CalculateBestPose(in Pose, in Pose, Transform, float, Handedness, ref HandGrabResult); for details, please refer to the related documentation provided for that interface.
Signature
void Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.CalculateBestPose(in Pose userPose, in Pose offset, Transform relativeTo, float handScale, Handedness handedness, ref HandGrabResult result)
Parameters
userPose: in Pose
offset: in Pose
relativeTo: Transform
handScale: float
handedness: Handedness
result: ref HandGrabResult
Returns
void
GenerateMovement ( from , to )
Implementation of IHandGrabInteractable.GenerateMovement(in Pose, in Pose); for details, please refer to the related documentation provided for that interface.
Signature
IMovement Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.GenerateMovement(in Pose from, in Pose to)
Parameters
from: in Pose
to: in Pose
Returns
IMovement
InjectAllDistanceHandGrabInteractable ( supportedGrabTypes , rigidbody , pinchGrabRules , palmGrabRules )
This method exists to support Interaction SDK's dependency injection pattern and is not needed for typical Unity Editor-based usage.
Signature
void Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.InjectAllDistanceHandGrabInteractable(GrabTypeFlags supportedGrabTypes, Rigidbody rigidbody, GrabbingRule pinchGrabRules, GrabbingRule palmGrabRules)
Parameters
supportedGrabTypes: GrabTypeFlags
rigidbody: Rigidbody
pinchGrabRules: GrabbingRule
palmGrabRules: GrabbingRule
Returns
void
InjectOptionalHandGrabPoses ( handGrabPoses )
Adds a list of DistanceHandGrabInteractor as HandGrabPoses to a dynamically instantiated DistanceHandGrabInteractable.
This method exists to support Interaction SDK's dependency injection pattern and is not needed for typical Unity Editor-based usage.
Signature
void Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.InjectOptionalHandGrabPoses(List< HandGrabPose > handGrabPoses)
Parameters
handGrabPoses: List< HandGrabPose >
Returns
void
InjectOptionalMovementProvider ( provider )
Adds an IMovementProvider as MovementProvider to a dynamically instantiated DistanceHandGrabInteractable.
This method exists to support Interaction SDK's dependency injection pattern and is not needed for typical Unity Editor-based usage.
Signature
void Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.InjectOptionalMovementProvider(IMovementProvider provider)
Parameters
Returns
void
InjectOptionalPhysicsGrabbable ( physicsObject )
Obsolete: adds a PhysicsGrabbable to a dynamically instantiated GameObject.
This functionality is now provided as part of Grabbable and no longer needs to be handled independently. This method exists to support Interaction SDK's dependency injection pattern and is not needed for typical Unity Editor-based usage.
Signature
void Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.InjectOptionalPhysicsGrabbable(PhysicsGrabbable physicsObject)
Parameters
physicsObject: PhysicsGrabbable
Returns
void
InjectPalmGrabRules ( palmGrabRules )
Adds a GrabbingRule as PalmGrabRules to a dynamically instantiated DistanceHandGrabInteractable.
This method exists to support Interaction SDK's dependency injection pattern and is not needed for typical Unity Editor-based usage.
Signature
void Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.InjectPalmGrabRules(GrabbingRule palmGrabRules)
Parameters
palmGrabRules: GrabbingRule
Returns
void
InjectPinchGrabRules ( pinchGrabRules )
Adds a GrabbingRule as PinchGrabRules to a dynamically instantiated DistanceHandGrabInteractable.
This method exists to support Interaction SDK's dependency injection pattern and is not needed for typical Unity Editor-based usage.
Signature
void Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.InjectPinchGrabRules(GrabbingRule pinchGrabRules)
Parameters
pinchGrabRules: GrabbingRule
Returns
void
InjectRigidbody ( rigidbody )
Adds a Unity Rigidbody as Rigidbody to a dynamically instantiated DistanceHandGrabInteractable.
This method exists to support Interaction SDK's dependency injection pattern and is not needed for typical Unity Editor-based usage.
Signature
void Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.InjectRigidbody(Rigidbody rigidbody)
Parameters
rigidbody: Rigidbody
Returns
void
InjectSupportedGrabTypes ( supportedGrabTypes )
Adds a GrabTypeFlags as SupportedGrabTypes in a dynamically instantiated DistanceHandGrabInteractable.
This method exists to support Interaction SDK's dependency injection pattern and is not needed for typical Unity Editor-based usage.
Signature
void Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.InjectSupportedGrabTypes(GrabTypeFlags supportedGrabTypes)
Parameters
supportedGrabTypes: GrabTypeFlags
Returns
void
SupportsHandedness ( handedness )
Implementation of IHandGrabInteractable.SupportsHandedness(Handedness); for details, please refer to the related documentation provided for that interface.
Signature
bool Oculus.Interaction.HandGrab.DistanceHandGrabInteractable.SupportsHandedness(Handedness handedness)
Parameters
handedness: Handedness
Returns
bool