PoseCalculator
(
desiredPose
, relativeTo
)
|
Signature
delegate Pose Oculus.Interaction.Grab.GrabPoseHelper.PoseCalculator(in Pose desiredPose, Transform relativeTo) Parameters desiredPose: in PoserelativeTo: TransformReturns delegate Pose |
CalculateBestPoseAtSurface
(
desiredPose
, offset
, bestPose
, scoringModifier
, relativeTo
, minimalTranslationPoseCalculator
, minimalRotationPoseCalculator
)
|
Finds the best pose comparing the one that requires the minimum rotation and minimum translation.
Signature
static GrabPoseScore Oculus.Interaction.Grab.GrabPoseHelper.CalculateBestPoseAtSurface(in Pose desiredPose, in Pose offset, out Pose bestPose, in PoseMeasureParameters scoringModifier, Transform relativeTo, PoseCalculator minimalTranslationPoseCalculator, PoseCalculator minimalRotationPoseCalculator) Parameters desiredPose: in PoseÂ
Root pose to measure from.
offset: in PoseÂ
The offset from the root for accurate scoring
bestPose: out PoseÂ
Nearest pose to the desired one at the hand grab pose.
relativeTo: TransformÂ
The reference transform to apply the calculators to
minimalTranslationPoseCalculator: PoseCalculatorÂ
Delegate to calculate the nearest, by position, pose at a hand grab pose.
minimalRotationPoseCalculator: PoseCalculatorÂ
Delegate to calculate the nearest, by rotation, pose at a hand grab pose.
|
CollidersScore
(
position
, colliders
, hitPoint
)
|
Calculates the score from a point to a set of colliders.
When the point is outside the colliders the further from their surface means the lower the score. When the point is inside any of the colliders the score is always higher.
Signature
static GrabPoseScore Oculus.Interaction.Grab.GrabPoseHelper.CollidersScore(Vector3 position, Collider[] colliders, out Vector3 hitPoint) Parameters position: Vector3Â
Position to measure against the colliders
colliders: Collider []Â
Group of colliders to measure the score
hitPoint: out Vector3Â
Output point in the surface or inside the colliders that is near the position
Returns GrabPoseScoreÂ
A GrabPoseScore value containing the score of the position in reference to the colliders
|
SelectBestPose
(
poseA
, poseB
, reference
, offset
, scoringModifier
, bestScore
)
|
Compares two poses to a reference and returns the most similar one
Signature
static Pose Oculus.Interaction.Grab.GrabPoseHelper.SelectBestPose(in Pose poseA, in Pose poseB, in Pose reference, in Pose offset, PoseMeasureParameters scoringModifier, out GrabPoseScore bestScore) Parameters poseA: in PoseÂ
First root Pose to compare with the reference.
poseB: in PoseÂ
Second root Pose to compare with the reference.
reference: in PoseÂ
Reference pose to measure from.
offset: in PoseÂ
The offset from the roots, for accurate scoring
Returns PoseÂ
The most similar pose to reference out of the poses
|