Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

OpenCV (EMGUCV wrapper) integration in Unity

Discussion in 'Editor & General Support' started by mbougaa, May 17, 2013.

  1. mbougaa

    mbougaa

    Joined:
    Mar 14, 2013
    Posts:
    5
    Hi everyone,

    As you know OpenCV is very useful library that let you do amazing and powerful things in Computer vision. So I passed a good time to figure out how to use it in Unity3d, I had many problems, and searching in the Net, I have found several suggestions but not one worked for me, so I wasted more time to figure out how to integrate it, and thanks god, now I’m using it in Unity, this is what I did for everyone who want to use it:

    - I’m using a Unity Pro 4.0
    - This version of Emgu CV (emgucv-windows-universal-gpu 2.4.9.1847)
    - My target for unity project is: windows and not web player

    1- Install this version of EmguCV, witch create a folder EMGU in C: disc
    2- In this folder you will have a single folder named “emgucv-windows-universal-gpu 2.4.9.1847”
    3- Go to “bin folder”
    4- From the “bin folder” you need to Copy all the dlls in the x86 folder (22 dlls), and also those in the bin directly (12 dlls: Emgu.CV, Emgu.CV.UI….) For X64 target, you can try the same thing, I think this will work by taking the dlls from the X64 folder.
    5- Create a folder named Plugins, in your Unity project (Assets Plugins)
    6- Paste all these 34 dlls file in the Plugins folder
    7- From this 34 dll files, copy the “npp32_50_35” and “cudart32_50_35” into the Unity editor folder, in my case it’s “C:\Program Files (x86)\Unity\Editor”
    8- You are done for the Dlls stuff.

    This is how to test it:
    1- Create a small script, that take a “picture1.jpg” and change the color of the first 200 diagonal pixels color to white color (255,255,255) and then save the new “picture2.jpg” This is what you have to put in the script:
    using UnityEngine;
    using System.Collections;
    using Emgu.CV;
    using Emgu.CV.Util;
    using Emgu.CV.UI;
    using Emgu.CV.CvEnum;
    using Emgu.CV.Structure;
    using System.Runtime.InteropServices;
    using System;
    using System.Drawing;

    Image<Bgr, byte> picture = new Image<Bgr, byte>("C:\\picture1.jpg");
    Bgr myWhiteColor = new Bgr(255, 255, 255);
    For (int i=0; i<200; i++)
    {picture[i,i]= color;}
    picture.Save("C:\\picture2.jpg");

    2- By adding the different dlls in the Plugins folder they will be referenced automatically in the Mono Editor, but probably you will have a problem with “System.Drawing” library, so don’t forget using System.Drawing; and also you have to reference it by going to your script editor, if MonoDevelop-Unity, go the solution explorer in the left, right click on Refrences Edit references and search for system.drawing in the left column and check it to see it in the right column  then press ok
    3- Also don’t forget to change the build settings in Unityfilebuild settings in this way:
    - PC Mac and Linux instead of webplayer
    - Target= windows
    - Architecture= x86
    - Then push the “player settings button” go to the “other settings in the new screen” and set Api Compatibility lavel to .NET 2.0, instead of .NET 2.0 subset
    For now you’re free to test your script and do awesome work using OpenCV
    PS: I’m not sure why exactly the “npp32_50_35” and “cudart32_50_35” have to be in the Editor folder, but it’s the only situation that worked for me, and sorry if my English isn’t good.

    Good luck for everyone
     
    chelnok likes this.
  2. elias_t

    elias_t

    Joined:
    Sep 17, 2010
    Posts:
    1,367
    Thank you. I had a shot in the past with emgucv but had many problems with unsafe pointers.
     
  3. jerrylewisbh

    jerrylewisbh

    Joined:
    May 22, 2013
    Posts:
    1
    Hello, mbougaa.

    First of all, thank you for your post.

    I did everything as you said but I got the following error:

    Internal compiler error. See the console log for more information. output was:
    Unhandled Exception: System.Reflection.ReflectionTypeLoadException: The classes in the module cannot be loaded.

    at (wrapper managed-to-native) System.Reflection.Assembly:GetTypes (bool)

    do you have any idea ??

    thanks in advance




     
  4. mbougaa

    mbougaa

    Joined:
    Mar 14, 2013
    Posts:
    5
  5. sephirock

    sephirock

    Joined:
    Jun 19, 2013
    Posts:
    1
    Hi jerrylewisbh,
    I had this problem and i've solved it with create a folder "Editor" in "Assets" folder and put “npp32_50_35” and “cudart32_50_35” in "Editor" folder
     
    ndhaijaan likes this.
  6. svenskefan

    svenskefan

    Joined:
    Nov 26, 2008
    Posts:
    282
    Hi!

    I have successfully compiled emgucv into a usable library for mac/monodevelop/unity.

    However I am really struggling with somehow sending the webcamtexture from Unity side to EmguCV. Would anyone have any insights into this?
     
    munees likes this.
  7. hrjunker

    hrjunker

    Joined:
    Nov 15, 2011
    Posts:
    26
    I got this working but somehow some functions did not work and I got some errors like this example:

    DllNotFoundException: C:/.../Assets/Plugins/cvextern.dll
    Emgu.CV.Cvb.CvBlobs..ctor ()
    TestOpenCV.GetBlobs (Emgu.CV.Image`2 source) (at Assets/TestOpenCV.cs:58)
    TestOpenCV.Update () (at Assets/TestOpenCV.cs:45)

    But I found that copying all opencv / emgu dlls into the project folder solved the issue.

    p.s. I was using EmguCV version 2.9 (emgucv-windows-universal-cuda 2.9.0.1922)
     
    Last edited: Oct 17, 2013
  8. dimitroff

    dimitroff

    Joined:
    Apr 3, 2013
    Posts:
    131
    Thanks for that! I was having the same problem, this is the Fix!!!
     
  9. flamy

    flamy

    Joined:
    Feb 7, 2011
    Posts:
    194
    Hello Everyone,


    If someone is trying to integreate EMGU inside Unity and is stuck some where, Follow the exact same as the On Post and after installing the emgucv-windows-universal-gpu 2.4.9.1847 Do remove the opencv dll that has GPU in the name, which will not be required and occupies a hectic 330+ mb


    and if you are using a 64 bit system, dont copy dlls from x64 folder, it will not work, copy it from the x86 itslef. The reason is unity is compiled for 32 bit OS. and other than that it is the same as the OP.


    While taking build, Copy the “npp32_50_35” and “cudart32_50_35” dlls to the build location out of data. The dlls should be in the same folder as the build.exe and build_data folder.


    Good luck :)
     
  10. AlbertYang

    AlbertYang

    Joined:
    Mar 12, 2014
    Posts:
    1
    I'm confused with the internal compiler error. after following the instructions, the error is fixed!
     
  11. abtrakt

    abtrakt

    Joined:
    Jan 8, 2014
    Posts:
    3
    i did everything you sayd but i get this error:

    Assets/scriptEMGU.cs(11,14): error CS0234: The type or namespace name `Drawing' does not exist in the namespace `System'. Are you missing an assembly reference?

    i dont get it when i put it as import in a javascript code "import System.Drawing;"

    what do i do?
     
  12. alexandre-fiset

    alexandre-fiset

    Joined:
    Mar 19, 2012
    Posts:
    714
    Copy the System Drawing DLL from Unity installation folder and paste it inside Asset/Plugins
     
  13. SaulStark

    SaulStark

    Joined:
    Jun 26, 2013
    Posts:
    1
    Hello everybody,

    I'm receiveng that error message trying to build:

    "ArgumentException: The Assembly Microsoft.VisualStudio.DebuggerVisualizers is referenced by Emgu.CV.DebuggerVisualizers.VS2008. But the dll is not allowed to be included or could not be found.
    UnityEditor.AssemblyHelper.AddReferencedAssembliesRecurse (System.String assemblyPath, System.Collections.Generic.List`1 alreadyFoundAssemblies, System.String[] allAssemblyPaths, System.String[] foldersToSearch, System.Collections.Generic.Dictionary`2 cache, BuildTarget target) (at C:/BuildAgent/work/d3d49558e4d408f4/Editor/Mono/AssemblyHelper.cs:113)
    UnityEditor.AssemblyHelper.FindAssembliesReferencedBy (System.String[] paths, System.String[] foldersToSearch, BuildTarget target) (at C:/BuildAgent/work/d3d49558e4d408f4/Editor/Mono/AssemblyHelper.cs:148)
    UnityEditor.BuildPlayerWindow:BuildPlayerAndRun()"

    Any idea? I've checked all the step and I can't find the problem.

    Thanks mbougaa for the post.
     
  14. Xiaoxiao_CC

    Xiaoxiao_CC

    Joined:
    May 13, 2014
    Posts:
    2
    DllNotFoundException: cvextern
    Emgu.CV.HOGDescriptor..ctor ()
    Emgu.CV.CvInvoke.cvLoad (System.String fileName, IntPtr memstorage, System.String name, IntPtr realName)
    Emgu.CV.HaarCascade..ctor (System.String fileName)
    NewBehaviourScript.Start () (at Assets/Scripts/NewBehaviourScript.cs:70)

    I have the same question with you, I had already put 34 dlls into plugins, where are others?
     
  15. jainam

    jainam

    Joined:
    Oct 20, 2013
    Posts:
    9
    Hi svenskefan!

    I am trying to do the same thing but keep getting error in Unity.

    "Internal compiler error. See the console log for more information. output was:
    Unhandled Exception: System.Reflection.ReflectionTypeLoadException: The classes in the module cannot be loaded.
    at (wrapper managed-to-native) System.Reflection.Assembly:GetTypes (bool)
    at System.Reflection.Assembly.GetTypes () [0x00000] in <filename unknown>:0
    at Mono.CSharp.RootNamespace.ComputeNamespaces (System.Reflection.Assembly assembly, System.Type extensionType) [0x00000] in <filename unknown>:0
    at Mono.CSharp.RootNamespace.ComputeNamespace (Mono.CSharp.CompilerContext ctx, System.Type extensionType) [0x00000] in <filename unknown>:0
    at Mono.CSharp.GlobalRootNamespace.ComputeNamespaces (Mono.CSharp.CompilerContext ctx) [0x00000] in <filename unknown>:0
    at Mono.CSharp.Driver.LoadReferences () [0x00000] in <filename unknown>:0
    at Mono.CSharp.Driver.Compile () [0x00000] in <filename unknown>:0
    at Mono.CSharp.Driver.Main (System.String[] args) [0x00000] in <filename unknown>:0 "

    I am literally new to OpenCV....have started exploring yesterday. It would be great if you could help me.

    Thanks in advance! :)
     
  16. 2011juve

    2011juve

    Joined:
    Jun 3, 2013
    Posts:
    1
    Hi ! I solve this problem !
    First - i found Microsoft.VisualStudio.DebuggerVisualizers.dll and put it in /Assets/Plugins/ folder
    Second - i found Antlr3.Runtime.dll and put it in /Assets/Plugins/ folder
    Third - i found mysql.dll and put it in /Assets/Plugins/ folder
    Fourth - i download binaries from http://www.codeproject.com/Articles/20884/Introducing-the-LinFu-Framework-Part-I-LinFu-Dynam and put all dll's it in /Assets/Plugins/ folder

    And i built my project. If you any questions - write here

    (in picture - my plugins folder structure)

    Good luck !
     

    Attached Files:

  17. lmeng

    lmeng

    Joined:
    Oct 15, 2014
    Posts:
    2
    I got this working but somehow some functions did not work and I got some errors like this example:

    DllNotFoundException: E:/4.5.2Workspace/EmguCV/Assets/Plugins/cvextern.dll
    Emgu.CV.CascadeClassifier..ctor (System.String fileName)
    Test1.FaceRecognition () (at Assets/Scripts/Test1.cs:55)
    Test1.Update () (at Assets/Scripts/Test1.cs:42)

    But I found that copying all opencv / emgu dlls into the project folder solved the issue.

    p.s. I was using EmguCV version 2.9 (emgucv-windows-universal-cuda 2.9.0.1922) Unity3d version 4.5.2 pro
     
  18. zuofengliu

    zuofengliu

    Joined:
    Mar 2, 2015
    Posts:
    1
    Sharing my experience :
    I am using unity pro Version 4.6.1f1 and Emgucv 2.4.10.1940, and got this error below with my first try:

    "Internal compiler error. See the console log for more information. output was:
    Unhandled Exception: System.Reflection.ReflectionTypeLoadException: The classes in the module cannot be loaded."
    I fixed it by set .NET 2.0 subset to NET 2.0, in the player setting.

    then I got another error below:
    "DllNotFoundException: opencv_core2410 "
    fixed the error by copying the files "nppc32_65.dll" "nppi32_65.dll" "npps32_65.dll" "cudart32_65.dll" from Emgucv folder to the unityEditor folder

    Now Its working properly
    thanks for all the post above!
     
  19. pretender

    pretender

    Joined:
    Mar 6, 2010
    Posts:
    862
    Can this be used in unity free?
     
  20. eco_bach

    eco_bach

    Joined:
    Jul 8, 2013
    Posts:
    1,601
    Is it possible to do swipe detection using the EmguCv asset?
     
  21. ABerlemont

    ABerlemont

    Joined:
    Sep 27, 2012
    Posts:
    67
    Following zuofengliu recommendations for dlls I end up with the following Error :

    DllNotFoundException: opencv_core249

    Debugview is telling me :

    [6808] Load scene 'Temp/__Backupscenes/0.backup' time: 52.522327 ms
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/opencv_highgui249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/.\opencv_highgui249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/opencv_highgui249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/libopencv_highgui249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/.\libopencv_highgui249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/libopencv_highgui249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/opencv_core249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/.\opencv_core249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/opencv_core249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/libopencv_core249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/.\libopencv_core249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/libopencv_core249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/opencv_highgui249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/.\opencv_highgui249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/opencv_highgui249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/libopencv_highgui249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/.\libopencv_highgui249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/libopencv_highgui249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/opencv_core249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/.\opencv_core249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/opencv_core249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/libopencv_core249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/.\libopencv_core249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/libopencv_core249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/c
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/.\c
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/c
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/libc
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/.\libc
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/libc
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/opencv_core249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/.\opencv_core249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/opencv_core249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/libopencv_core249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/.\libopencv_core249
    [6808] Fallback handler could not load library C:/Program Files/Unity/Editor/Data/Mono/lib/libopencv_core249
    [6808] DllNotFoundException: opencv_core249
    [6808] at (wrapper managed-to-native) Emgu.CV.CvInvoke:cvRedirectError (Emgu.CV.CvInvoke/CvErrorCallback,intptr,intptr)
    [6808] at Emgu.CV.CvInvoke..cctor () [0x00000] in <filename unknown>:0
    [6808] Rethrow as TypeInitializationException: An exception was thrown by the type initializer for Emgu.CV.CvInvoke
    [6808] at Emgu.CV.Image`2[Emgu.CV.Structure.Bgr,System.Byte].LoadImageUsingOpenCV (System.IO.FileInfo file) [0x00000] in <filename unknown>:0
    [6808] at Emgu.CV.Image`2[Emgu.CV.Structure.Bgr,System.Byte]..ctor (System.String fileName) [0x00000] in <filename unknown>:0
    [6808]
    [6808] (Filename: Line: -1)

    I tried to move the named dll around in the unity editor folder but it's doesn't work.

    Anyone managed to do this ? (im using Unity 5.3.2f1)
     
  22. MORKANE

    MORKANE

    Joined:
    Feb 13, 2015
    Posts:
    3
    hi all :)
    Why is this error appears:(, has implemented steps fully, NOTE: This mis only shows if you create scripts of some kind (C#) :confused:????

    #The description error in the debug unity :
    ________________________________________________________________________________
    ________________________________________________________________________________

    Unhandled Exception: System.Reflection.ReflectionTypeLoadException: The classes in the module cannot be loaded.

    at (wrapper managed-to-native) System.Reflection.Assembly:GetTypes (bool)

    at System.Reflection.Assembly.GetTypes () [0x00000] in <filename unknown>:0

    at Mono.CSharp.RootNamespace.ComputeNamespaces (System.Reflection.Assembly assembly, System.Type extensionType) [0x00000] in <filename unknown>:0

    at Mono.CSharp.RootNamespace.ComputeNamespace (Mono.CSharp.CompilerContext ctx, System.Type extensionType) [0x00000] in <filename unknown>:0

    at Mono.CSharp.GlobalRootNamespace.ComputeNamespaces (Mono.CSharp.CompilerContext ctx) [0x00000] in <filename unknown>:0

    at Mono.CSharp.Driver.LoadReferences () [0x00000] in <filename unknown>:0

    at Mono.CSharp.Driver.Compile () [0x00000] in <filename unknown>:0

    at Mono.CSharp.Driver.Main (System.String[] args) [0x00000] in <filename unknown>:0

    The following assembly referenced from C:\Users\TOOLS\Documents\Open CV\Assets\Plugins\Emgu.CV.dll could not be loaded:
    Assembly: System.Drawing (assemblyref_index=3)
    Version: 2.0.0.0
    Public Key: b03f5f7f11d50a3a
    The assembly was not found in the Global Assembly Cache, a path listed in the MONO_PATH environment variable, or in the location of the executing assembly (C:\Users\TOOLS\Documents\Open CV\Assets\Plugins\).

    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    The class Emgu.CV.Matrix`1 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class Emgu.CV.Matrix`1 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    The class Emgu.CV.Matrix`1 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class Emgu.CV.Matrix`1 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class RecognitionResult could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class Emgu.CV.Matrix`1 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class SimilarFeature could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class MatchedImageFeature could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    The class Emgu.CV.Matrix`1 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class Emgu.CV.Matrix`1 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    The class Emgu.CV.Matrix`1 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    The class Emgu.CV.Image`2 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    The class Emgu.CV.Structure.MCvSURFPoint could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class Emgu.CV.Structure.MKeyPoint could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    The class ColorSamplingMethod could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class OPLandIplParvoParameters could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class IplMagnoParameters could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class RetinaParameters could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    The class Emgu.CV.Structure.MCvBox2D could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    Could not load file or assembly 'System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
    The class Emgu.CV.Image`2 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class Emgu.CV.VideoSurveillance.BackgroundSubtractor could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class Emgu.CV.VideoSurveillance.BackgroundSubtractor could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class Emgu.CV.Structure.MCvBGCodeBookModel could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class Emgu.CV.Structure.MCvBlob could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class Emgu.CV.VideoSurveillance.BlobSeqBase could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class Emgu.CV.VideoSurveillance.BlobSeqBase could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class Emgu.CV.VideoSurveillance.BlobSeqBase could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class Emgu.CV.VideoSurveillance.BlobTracker could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class <>c__DisplayClassc could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class <>c__DisplayClass1 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class <>c__DisplayClass4 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class <>c__DisplayClass1 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class <>c__DisplayClass4 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class <>c__DisplayClass7 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class <>c__DisplayClassa could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class <>c__DisplayClassd could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class <>c__DisplayClassf could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class <>c__DisplayClass11 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class <>c__DisplayClass14 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class <>c__DisplayClass16 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class <>c__DisplayClass19 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class <>c__DisplayClass1c could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class <>c__DisplayClass20 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class <>c__DisplayClass23 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class <>c__DisplayClass26 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class <>c__DisplayClass29 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class <GetVoronoiFacetsHelper>d__0 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class <GetEnumerator>d__d could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438
    The class <GetEnumerator>d__0 could not be loaded, used in Emgu.CV, Version=2.4.10.1939, Culture=neutral, PublicKeyToken=7281126722ab4438

    _________________________________________________________________________________
    _________________________________________________________________________________

    My image of the project :

    <<<<<:rolleyes:I need to please help solution:rolleyes:>>>>>
     
    fisionomiadev likes this.
  23. munees

    munees

    Joined:
    Jul 13, 2017
    Posts:
    3
    Unhandled Exception: System.Reflection.ReflectionTypeLoadException: The classes in the module cannot be loaded.
     
  24. munees

    munees

    Joined:
    Jul 13, 2017
    Posts:
    3
    after i cleared ->
    Unhandled Exception: System.Reflection.ReflectionTypeLoadException: The classes in the module cannot be loaded.
    But One Eror can be occur->
    Failed to load 'Assets/Plugins/ope.dll', expected 64 bit architecture (IMAGE_FILE_MACHINE_AMD64), but was IMAGE_FILE_MACHINE_I386. You must recompile your plugin for 64 bit architecture.
     
  25. munees

    munees

    Joined:
    Jul 13, 2017
    Posts:
    3
    please give system.Reflection error .
    My project platform is Unity to connect Emgu opencv dll file .:(:(:(:(:(
     
  26. fisionomiadev

    fisionomiadev

    Joined:
    Sep 25, 2015
    Posts:
    1
    I'm having this error on Unity 2017.2.0f3

    TypeLoadException: Could not load type 'Emgu.CV.UI.ImageProperty' from assembly 'Emgu.CV.UI, Version=3.0.0.2157, Culture=neutral, PublicKeyToken=7281126722ab4438'.
    System.Reflection.MonoMethodInfo.GetMethodInfo (IntPtr handle) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Reflection/MonoMethod.cs:59)
    System.Reflection.MonoMethodInfo.GetAttributes (IntPtr handle) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Reflection/MonoMethod.cs:75)
    System.Reflection.MonoMethod.get_Attributes () (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Reflection/MonoMethod.cs:245)
    System.Reflection.MethodBase.get_IsSpecialName () (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Reflection/MethodBase.cs:184)
    UnityEditor.Build.BuildPipelineInterfaces.InitializeBuildCallbacks (BuildCallbacks findFlags) (at C:/buildslave/unity/build/Editor/Mono/BuildPipeline/BuildPipelineInterfaces.cs:191)