Convert Unity Texture2D to OpenCVSharp Mat

■ Texture2D to OpenCVSharp Mat

When you want to use cvtColor() or something method, you should convert CV_64F to 8UC or other suitable Mattype.

Note

This method doesn’t convert some images as shown in this image.
Probably, the MatType property or GetPixel Method is not appropriate in this code.

■ OpenCVSharp Mat to Texture2D

Reference

https://forum.unity.com/threads/convert-texture2d-to-opencvsharp-to-mat-and-vice-versa.524872/

コメントを残す

メールアドレスが公開されることはありません。