Skip to content

Commit 87bcf43

Browse files
committed
update 2.4.6
1 parent 9b13024 commit 87bcf43

File tree

119 files changed

+179
-153
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

119 files changed

+179
-153
lines changed

Assets/OpenCVForUnity/Examples.meta

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Assets/OpenCVForUnity/Examples/Advanced.meta

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Assets/OpenCVForUnity/Examples/Advanced/AlphaBlendingExample.meta

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Assets/OpenCVForUnity/Examples/Advanced/ComicFilterExample.meta

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Assets/OpenCVForUnity/Examples/Advanced/ComicFilterExample/ComicFilterExample.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@ public void OnStopButtonClick()
181181
/// </summary>
182182
public void OnChangeCameraButtonClick()
183183
{
184-
webCamTextureToMatHelper.requestedIsFrontFacing = !webCamTextureToMatHelper.IsFrontFacing();
184+
webCamTextureToMatHelper.requestedIsFrontFacing = !webCamTextureToMatHelper.requestedIsFrontFacing;
185185
}
186186
}
187187
}

Assets/OpenCVForUnity/Examples/Advanced/DocumentScannerExample.meta

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Assets/OpenCVForUnity/Examples/Advanced/DocumentScannerExample/DocumentScannerExample.cs

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -130,8 +130,15 @@ public void OnWebCamTextureToMatHelperInitialized ()
130130
DEBUG_CONTOUR_COLOR = new Scalar(255, 255, 0, 255);
131131
DEBUG_CORNER_NUMBER_COLOR = new Scalar(255, 255, 255, 255);
132132

133-
// if WebCamera is frontFaceing, flip Mat.
134-
webCamTextureToMatHelper.flipHorizontal = webCamTextureToMatHelper.GetWebCamDevice().isFrontFacing;
133+
// If the WebCam is front facing, flip the Mat horizontally. Required for successful detection of document.
134+
if (webCamTextureToMatHelper.IsFrontFacing() && !webCamTextureToMatHelper.flipHorizontal)
135+
{
136+
webCamTextureToMatHelper.flipHorizontal = true;
137+
}
138+
else if (!webCamTextureToMatHelper.IsFrontFacing() && webCamTextureToMatHelper.flipHorizontal)
139+
{
140+
webCamTextureToMatHelper.flipHorizontal = false;
141+
}
135142
}
136143

137144
/// <summary>
@@ -409,7 +416,7 @@ public void OnStopButtonClick ()
409416
/// </summary>
410417
public void OnChangeCameraButtonClick ()
411418
{
412-
webCamTextureToMatHelper.requestedIsFrontFacing = !webCamTextureToMatHelper.IsFrontFacing ();
419+
webCamTextureToMatHelper.requestedIsFrontFacing = !webCamTextureToMatHelper.requestedIsFrontFacing;
413420
}
414421

415422
/// <summary>

Assets/OpenCVForUnity/Examples/Advanced/GreenScreenExample.meta

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Assets/OpenCVForUnity/Examples/Advanced/GreenScreenExample/GreenScreenExample.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,7 @@ public void OnStopButtonClick ()
293293
/// </summary>
294294
public void OnChangeCameraButtonClick ()
295295
{
296-
webCamTextureToMatHelper.requestedIsFrontFacing = !webCamTextureToMatHelper.IsFrontFacing ();
296+
webCamTextureToMatHelper.requestedIsFrontFacing = !webCamTextureToMatHelper.requestedIsFrontFacing;
297297
}
298298
}
299299
}

Assets/OpenCVForUnity/Examples/Advanced/HandPoseEstimationExample.meta

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)