Skip to content

Commit ffd3049

Browse files
committed
Don't keep reallocating the states list
1 parent e8446e8 commit ffd3049

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Assets/MixedRealityToolkit.Providers/WindowsMixedReality/XRSDK/Controllers/WindowsMixedRealityXRSDKArticulatedHand.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ public WindowsMixedRealityXRSDKArticulatedHand(TrackingState trackingState, Hand
5252
private int[] handMeshTriangleIndices = null;
5353
private bool hasRequestedHandMeshObserver = false;
5454
private Vector2[] handMeshUVs;
55+
private readonly List<object> states = new List<object>();
5556

5657
protected void InitializeUVs(Vector3[] neutralPoseVertices)
5758
{
@@ -179,7 +180,6 @@ private void UpdateHandData(InputDevice inputDevice)
179180
return;
180181
}
181182

182-
List<object> states = new List<object>();
183183
#if WMR_ENABLED
184184
XRSDKSubsystemHelpers.InputSubsystem?.GetCurrentSourceStates(states);
185185
#endif // WMR_ENABLED

0 commit comments

Comments
 (0)