Skip to content

Commit 9b13024

Browse files
committed
update 2.4.5
1 parent 602df1d commit 9b13024

File tree

118 files changed

+5576
-739
lines changed

Some content is hidden

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

118 files changed

+5576
-739
lines changed

Assets/OpenCVForUnity/Examples.meta

Lines changed: 2 additions & 3 deletions
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: 2 additions & 3 deletions
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: 2 additions & 3 deletions
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: 2 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Assets/OpenCVForUnity/Examples/Advanced/DocumentScannerExample.meta

Lines changed: 2 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Assets/OpenCVForUnity/Examples/Advanced/GreenScreenExample.meta

Lines changed: 2 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Assets/OpenCVForUnity/Examples/Advanced/HandPoseEstimationExample.meta

Lines changed: 2 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Assets/OpenCVForUnity/Examples/Advanced/MatToTextureInRenderThreadExample.meta

Lines changed: 2 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Assets/OpenCVForUnity/Examples/Advanced/MultiObjectTrackingBasedOnColorExample.meta

Lines changed: 2 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Assets/OpenCVForUnity/Examples/Advanced/MultiObjectTrackingBasedOnColorExample/MultiObjectTrackingBasedOnColorExample.cs

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ public void OnWebCamTextureToMatHelperInitialized ()
9191

9292
Mat webCamTextureMat = webCamTextureToMatHelper.GetMat ();
9393

94-
texture = new Texture2D (webCamTextureMat.cols (), webCamTextureMat.rows (), TextureFormat.RGB24, false);
94+
texture = new Texture2D (webCamTextureMat.cols (), webCamTextureMat.rows (), TextureFormat.RGBA32, false);
9595
Utils.fastMatToTexture2D(webCamTextureMat, texture);
9696

9797
gameObject.GetComponent<Renderer> ().material.mainTexture = texture;
@@ -183,10 +183,12 @@ void Update ()
183183
Core.inRange (hsvMat, green.getHSVmin (), green.getHSVmax (), thresholdMat);
184184
morphOps (thresholdMat);
185185
trackFilteredObject (green, thresholdMat, hsvMat, rgbMat);
186-
187-
// Imgproc.putText (rgbMat, "W:" + rgbMat.width () + " H:" + rgbMat.height () + " SO:" + Screen.orientation, new Point (5, rgbMat.rows () - 10), Imgproc.FONT_HERSHEY_SIMPLEX, 1.0, new Scalar (255, 255, 255, 255), 2, Imgproc.LINE_AA, false);
188186

189-
Utils.fastMatToTexture2D (rgbMat, texture);
187+
//Imgproc.putText (rgbMat, "W:" + rgbMat.width () + " H:" + rgbMat.height () + " SO:" + Screen.orientation, new Point (5, rgbMat.rows () - 10), Imgproc.FONT_HERSHEY_SIMPLEX, 1.0, new Scalar (255, 255, 255, 255), 2, Imgproc.LINE_AA, false);
188+
189+
Imgproc.cvtColor(rgbMat, rgbaMat, Imgproc.COLOR_RGB2RGBA);
190+
191+
Utils.fastMatToTexture2D (rgbaMat, texture);
190192
}
191193
}
192194

0 commit comments

Comments
 (0)