This page documents the use of the Emgu.CV library for accessing computer vision functions and a general interface to using webcams. It uses OpenCV.
- Download Emgu.CV
- Copy the low-level (machine-dependent) opencv_*.dll libraries to Calico's bin folder
- For example copy "C:\Emgu\emgucv-windows-universal-gpu 220.127.116.117\bin\x86\*.*" to C:\Calico\bin
- Copy the high-level (managed) libraries to Calico's module folder
- For example copy "C:\Emgu\emgucv-windows-universal-gpu 18.104.22.1687\bin\*.dll" to C:\Calico\modules
In running these interactions, it if probably a good idea to NOT reset the shell when running a new Calico script.
In Calico when you have a program script (say, Python) open, go to menu -> Script -> Script Options and UNCHECK "Reset Shell on Run". This will not clear variables, and will allow the webconnection to remain continuous through your session.
After installation, you should be able to run the following:
# http://www.emgu.com/wiki/index.php/Camera_Capture_in_7_lines_of_code import Emgu viewer = Emgu.CV.UI.ImageViewer() capture = Emgu.CV.Capture() viewer.ShowDialog()
If that fails, perhaps you have the wrong architecture (32-bits vs. 64-bits). The 32-bit version should work for all Windows versions.
If that fails, then you may need to rebuild the Emgu.CV library for your platform via Mono. You can use MonoDevelop (or Xamarin Studio) to rebuild managed DLL libraries. Simple open the Emgu.CV solution (in the Solution folder) and rebuild all.
To be written...