Skip to content

Commit 638fc28

Browse files
committed
fix(sample): workaround for #1196
1 parent c2d594e commit 638fc28

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

‎Assets/MediaPipeUnity/Samples/Scenes/Tasks/Pose Landmark Detection/PoseLandmarkerRunner.cs‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,10 @@ protected override IEnumerator Run()
6565
var transformationOptions = imageSource.GetTransformationOptions();
6666
var flipHorizontally = transformationOptions.flipHorizontally;
6767
var flipVertically = transformationOptions.flipVertically;
68-
var imageProcessingOptions = new Tasks.Vision.Core.ImageProcessingOptions(rotationDegrees: (int)transformationOptions.rotationAngle);
68+
69+
// Always setting rotationDegrees to 0 to avoid the issue that the detection becomes unstable when the input image is rotated.
70+
// https://github.com/homuler/MediaPipeUnityPlugin/issues/1196
71+
var imageProcessingOptions = new Tasks.Vision.Core.ImageProcessingOptions(rotationDegrees: 0);
6972

7073
AsyncGPUReadbackRequest req = default;
7174
var waitUntilReqDone = new WaitUntil(() => req.done);

0 commit comments

Comments
 (0)