Skip to content

Commit 236aa93

Browse files
committed
Actually reuse these structs via ref
1 parent 5b9fdef commit 236aa93

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

org.mixedrealitytoolkit.input/Subsystems/HandsAggregator/MRTKHandsAggregatorSubsystem.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,7 @@ public override bool TryGetPinchingPoint(XRNode handNode, out HandJointPose join
259259
gotData &= TryGetJoint(TrackedHandJoint.IndexTip, handNode, out HandJointPose indexPose);
260260
gotData &= TryGetJoint(TrackedHandJoint.Palm, handNode, out HandJointPose palmPose);
261261

262-
HandJointPose pinchPointPose = handNode == XRNode.LeftHand ? leftPinchPose : rightPinchPose;
262+
ref HandJointPose pinchPointPose = ref (handNode == XRNode.LeftHand ? ref leftPinchPose : ref rightPinchPose);
263263

264264
// Stabilize the pinch pose by a weighted average between the thumb and index.
265265
// A true average (50% thumb, 50% index) is too unstable for precise manipulation.

0 commit comments

Comments
 (0)