Questions tagged [emgucv]

EmguCV is a cross-platform .NET wrapper to the OpenCV image processing library. Allowing OpenCV functions to be called from .NET compatible languages such as C#, VB, C++-CLI, IronPython etc. The wrapper can be compiled in Mono and run on Linux or Mac OS X.

About EmguCV

EmguCV opens the OpenCV (Open Source Computer Vision Library) library of programming functions mainly aimed at real time computer vision to .NET developers. OpenCV was originally developed by Intel and now supported by Willow Garage.

Current versions for x86 , x64 and ARM(only for iOS and Android) architectures are available for download at their SourceForge website, https://sourceforge.net/projects/emgucv/.

A download and installation guide is available here. This is particularly useful for newcomers as ensuring the correct references are used and that the associated OpenCV .dll files are copied to the output directory can be difficult.

EmguCV uses a dual-license business model for its software development library and offers licenses for two distinct purposes: open source, and commercial development. More information can be found here.

Cross Platform

Unlike other wrappers such as OpenCVDotNet, SharperCV or Code Project which use unsafe code, EmguCV is written entirely in C#. The benefit is that it can be compiled in Mono and therefore is able to run on any platform Mono supports, including Linux, Solaris and Mac OS X. A lot of efforts have been spent creating a pure C# implementation since the headers have to be ported, compared with managed C++ implementation where header files can simply be included. But it is well worth it if you see EmguCV running on Fedora 10! Plus it always gives you the comfort knowing that your code is cross-platform.

EmguCV can be used from several different languages, including C#, VB.NET, C++-CLI and IronPython. On this wiki, we provide examples for all those languages, which are available from the Examples section on Tutorial page. Our discussion forum is also available if you have any questions related to your favorite programming language.

Other Advantages

  • Image class with Generic Color and Depth
  • Automatic garbage collection
  • XML Serializable Image
  • XML Documentation and intellisense support
  • The choice to either use the Image class or direct invoke functions from OpenCV
  • Generic operations on image pixels

Architecture Overview

EmguCV has two layers of wrapper as shown below

  • The basic layer (layer 1) contains function, structure and enumeration mappings which directly reflect those in OpenCV.
  • The second layer (layer 2) contains classes that mix in advantages from the .NET world.

EmguCVArchitecture.png

2204 questions
7
votes
1 answer

How to detect and count a spiral's turns

I need to detect a spiral shaped spring and count its coil turns. I have tried as follows: Image ProcessImage(Image img) { Image imgClone = new Image( img.Width, img.Height); imgClone =…
Rick2047
  • 1,565
  • 7
  • 24
  • 35
6
votes
4 answers

EmguCV - how to specify jpeg quality when saving image?

I save jpeg image using the following C# EmguCV code: Emgu.CV.Image image ... image.Save("imageName.jpg"); But image is stored in extremally low quality (1 color square per 8x8 pixels). When I save bmp all are ok: Emgu.CV.Image
sergtk
  • 10,714
  • 15
  • 75
  • 130
6
votes
3 answers

Improve face detection performances with OpenCV/EmguCV

I am currently using EmguCV (OpenCV C# wrapper) sucessfully to detect faces in real-time (webcam). I get around 7 FPS. Now I'm looking to improve the performances (and save CPU cycles), and I'm looking for options, here are my ideas: Detect the…
Matthieu Napoli
  • 48,448
  • 45
  • 173
  • 261
6
votes
2 answers

How to cut a sub-part of an image using Emgu CV (or OpenCV)?

I want to cut a sub-purt of an image (or crop it) using Emgu CV (or OpenCV) and calculate average color of that part; looking for changes. Thanks
Kaveh Shahbazian
  • 13,088
  • 13
  • 80
  • 139
6
votes
1 answer

Motion tracking using Emgu CV (or OpenCV)

How can I do motion tracking using Emgu CV or OpenCV? What are different ways of doing it? I want to track objects against a fixed background. Best Regards
Kaveh Shahbazian
  • 13,088
  • 13
  • 80
  • 139
6
votes
2 answers

How to create a histogram

I want to create a histogram within a C# program that uses EMGU. EMGU contains a class called MCvHistogram in it, but I don't know how to use it.
White Dwarf
  • 189
  • 1
  • 3
  • 11
6
votes
2 answers

EMGU CV 2.4.9 face recognition accuracy issue

I have followed the sample code from the code project to create a face recognition system using EMGUCV. I have trained the database with 2 people and each person has 10 images. When the webcam detects those people and able to show the name…
Bubble Bub
  • 651
  • 4
  • 12
  • 32
6
votes
2 answers

Multi-Layer Perceptrons in EmguCV

I'm trying to implement Multi-Layer Perceptrons (MLP) neural networks using EmguCV 3.1 (a dot NET wrapper for OpenCV library) in C#(Windows Form). In order to practice with this library I decide to implement OR operation using MLP. I create MLP…
Babak.Abad
  • 2,839
  • 10
  • 40
  • 74
6
votes
4 answers

how to configure EmguCV and Visual Studio Express 2010 in Win8.1x64

I am developing an application via EmguCV and Visual Studio Express 2010 in Win8.1x64. when I create a new project (C# windows application), it automatically choose x86 as target platform and there is no other choice. When I try to read an image…
mjyazdani
  • 2,110
  • 6
  • 33
  • 64
6
votes
3 answers

How to choose Full Frames (Uncompressed) as codec for VideoWriter

i want to store uncompressed frames from a device as a video, but i need to know how to choose " Full Frames (Uncompressed) " as a codec for the VideoWriter (in emgu aka openCV). Iam able to choose it from the dropdown menu when iam passing -1 like…
Rantir
  • 111
  • 1
  • 1
  • 11
6
votes
1 answer

System.Drawing.Image to Emgu.CV.Mat

As titled. I am having a problem of converting System.Drawing.Image to Emgu.CV.Mat I tried to covert it from Drawing.Image to CV.Image but keep having Exceptions. Is there any other solution available? Any help render is kindly appreciated.
Kim McWing Wee
  • 81
  • 1
  • 1
  • 4
6
votes
1 answer

How to multiply a Mat and a scalar with EmguCV in Visual Basic?

I've been trying to re-scale an Emgu.CV.Mat with depth 32F and value range [0,1] (a grayscale image) to range [0,255] in order to visualize it in a ImageBox object contained in a Visual Basic form, using the code line ibSuave.Image = imgSuave *…
6
votes
1 answer

How do EmguCV detectors relate to EmguCV DescriptorExtractors?

Reading EmgCV docs cant quite understand: what detectors can be used with which DescriptorExtractors? Here it is said: You can use it with the FREAK descriptor that is scale invariant. Just replace the BriefDescriptorExtractor with Freak and it…
DuckQueen
  • 772
  • 10
  • 62
  • 134
6
votes
2 answers

How to use FindChessboardCorners

i am using the new EmguCV 3.0.0 alpha to detect a chessboard with webcam and have an understanding problem with the corners matrix. Size patternSize = new Size(5, 4); Matrix corners = new Matrix(1, 2); bool…
6
votes
3 answers

Converting Image in c#

Edit: SOLVED! Please see my answer down below for details. I was unable to find an answer to the original question but I found an alternate solution This question may be asked somewhere else but I have been searching for days and can't find anything…
Hughsie28
  • 103
  • 2
  • 13