HoloLensWithOpenCVForUnityExample icon indicating copy to clipboard operation
HoloLensWithOpenCVForUnityExample copied to clipboard

Error: 'MatUtils' does not exist in the current context

Open tammmyz opened this issue 1 year ago • 3 comments
trafficstars

Hello! I am pretty new to Unity and developing for the HoloLens. I have followed the steps in the README up until step 9 where I need to build on Unity. I am running into the following error: Screenshot 2024-06-28 at 12 21 13 PM

I tried looking for a reference to MatUtils within this repo as well as the OpenCVForUnity repo, and online with no success. I am currently using Unity version 2022.3.22f1 on Windows 10.

Wondering if anyone can point me towards a solution for this? Thanks!

tammmyz avatar Jun 28 '24 16:06 tammmyz

Thank you for your inquiry. This is due to an older version of OpenCVForUnity. Please try the latest version (2.6.1).

EnoxSoftware avatar Jun 30 '24 10:06 EnoxSoftware

Hi, I also have the same error. I am using the latest version 2.6.2, and Unity version 2021.3.42f1

lagenuina avatar Aug 14 '24 21:08 lagenuina

Thank you all for your reports. It seems to be affected by the namespace change in the latest version. Assets\HoloLensWithOpenCVForUnityExample\HLCameraStreamToMatHelperExample\ComicFilter.cs, replace line 3 from “using OpenCVForUnity.UtilsModule;” with ”using OpenCVForUnity.UnityUtils;” instead of ”using OpenCVForUnity.

EnoxSoftware avatar Aug 15 '24 19:08 EnoxSoftware