Skip to content

Commit 34ae37f

Browse files
committed
Update PlatformHandMeshVisualizer.cs
1 parent 02ea52d commit 34ae37f

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

org.mixedrealitytoolkit.input/Visualizers/PlatformHandVisualizer/PlatformHandMeshVisualizer.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,11 @@ protected void Update()
110110
&& handMeshTracker.TryGetHandMesh(FrameTime.OnUpdate, meshFilter.mesh)
111111
&& handMeshTracker.TryLocateHandMesh(FrameTime.OnUpdate, out Pose pose))
112112
{
113+
// On some runtimes, the mesh is moved in its local space instead of world space,
114+
// while its world space location is unchanged. In this case, we want to ensure the
115+
// bounds follow the hand around by manually recalculating them.
113116
meshFilter.mesh.RecalculateBounds();
117+
114118
handRenderer.enabled = true;
115119

116120
if (!initializedUVs && handMeshTracker.TryGetHandMesh(FrameTime.OnUpdate, neutralPoseMesh, HandPoseType.ReferenceOpenPalm))

0 commit comments

Comments
 (0)