problem about emgucv-Collection of common programming errors


  • user2939038
    c++ opencv emgucv
    I am working with opencv_createsamples to create vector file, but it allays crashed.\Lib\Emgu\bin>opencv_createsamples -info “C:\Haar\CarData\info.txt” – vec “C:\Haar\CarData\cars.vec” -w 48 -h 24 -num 27 Info file name: C:\Haar\CarData\info.txt Img file name: (NULL) Vec file name: C:\Haar\CarData\cars.vec BG file name: (NULL) Num: 27 BG color: 0 BG threshold: 80 Invert: FALSE Max intensity deviation: 40 Max x angle: 1.1 Max y angle: 1.1 Max z angle: 0.5 Show samples: FALSE Width: 48 Height:

  • VitoShadow
    c# crash emgucv
    I cannot use the SURFDetector object, because the program crashes.I’m using the version 2.4.9 of Emgu (downloaded form here), and I’ve followed the instructions about adding the OpenCV dependencies (link):For EMGU CV version >=2.4 cudart64_42_9.dll, cvextern.dll, npp64_42_9.dll, opencv_calib3dXXX.dll, opencv_contribXXX.dll, opencv_coreXXX.dll, opencv_features2dXXX.dll, opencv_flannXXX.dll, opencv_highguiXXX.dll, opencv_imgprocXXX.dll, opencv_legacyXXX.dll, opencv_mlXXX.dll, opencv_nonfreXXX.dll,

  • Nate
    c# opencv image-processing emgucv
    I’m working on my project which is a robot air hockey player;in the project I’m using a Microsoft lifecam to identify the “ball” place. that’s working.the problem is when I’m running the project in the main form – if before entering the game I’m checking the camera (one pic) that is the code inside the button:Capture capture = new Capture(0);Image<Emgu.CV.Structure.Bgr,byte> temp = capture.QueryFrame();picture pic = new picture(temp);pic.ShowDialog();and after the check I’m staring playin

  • Benson Chiu
    multithreading emgucv face-recognition
    I am trying improve the speed of detecting faces in images by running the DetectHaarCascade face detection concurrently on multiple files. But I am hitting AccessViolationException, wondering does anyone have examples on how to run EMGU CV face detection parallelly.Here is a simple test I wrote where I have 98 images to detect:[TestMethod]public void TestDetectParallel(){var face = new HaarCascade(“haarcascade_frontalface_default.xml”);var images =Directory.EnumerateFiles(Environment.CurrentDir

  • Nikson Kanti Paul
    c# computer-vision emgucv
    I am trying to use EMGUCV for C#. Currently i have installed Visual Studio 2010 express Edition. When trying to execute some simple commands the Emgu.CV.CvInvoke threw an exception came out so i put the unmanaged code in the exe folder. But still it continued to give me the error. So i tried adding the unmanaged code to solution explorer and still it is giving me this error. Is there anything else which i can do so i can finally use emguCV?The exception is System.TypeInitializationException was

  • Richard Twitty
    vb.net ocr emgucv emgu
    Hey this is my first time using this website, but I a problem. I saw this awesome youtube video about getting ocr to work with vb.net. Here the url:http://www.youtube.com/watch?v=Kjdu8SjEtG0So I decided to download the emgu libraries, here the url:http://sourceforge.net/projects/emgucv/I did everything the video say and I get this error: “An error occurred creating the form. See Exception.InnerException for details. The error is: The type initializer for ‘Emgu.CV.OCR.Tesseract’ threw an excepti

  • Mike
    detection emgucv vision
    I’m having a problem with using Haar Detection and EmguCV within VS2012. I’ve copied the exception details below to provide more insight. Please note that I do not have rapport installed on my pc, although I wish I did because that would probably solve this issue! Anyways, hoping I could get some assistance. Thank you in advance.System.Runtime.InteropServices.SEHException was unhandledHResult=-2147467259Message=External component has thrown an exception.Source=Emgu.CVErrorCode=-2147467259StackTr

  • user2074222
    c# kinect emgucv emgu cv
    I’m working on a project for school involving C#, Kinect, and Emgu CV. I fairly new to both C# and Emgu CV, so I may be missing something simple. What I am trying to do is use the image from the Kinect as an Emgu CV image for processing, but I keep getting an error. The error that comes up is “TypeInitializationException was unhandled” and “The type initializer for ‘Emgu.Cv.CVInvoke’ threw an exception.” The code I’m using to get the image from the Kinect is:using (ColorImageFrame colorFrame = e

  • Soner Gönül
    c# emgucv
    I’m trying to start using emgu CV open CV for C#. But I’m having trouble making it work. I’m following this guide to make simple program using emgu CV Link but I get following error: (any idea what I’m doing wrong?)System.TypeInitializationException was unhandledMessage=The type initializer for ‘Emgu.CV.CvInvoke’ threw an exception.Source=Emgu.CVTypeName=Emgu.CV.CvInvokeStackTrace:at Emgu.CV.Image`2..ctor(String fileName) in c:\Emgu\emgucv-windows-x86-gpu 2.4.2.1777\Emgu.CV\Image.cs:line 144at T

  • Gilad
    c# opencv emgucv emgu
    I’ve been working with EMGU+OpenCV for quite some time and ran into this AccessViolationException mystery.First thing first, the code:class AVE_Simulation{public static int Width = 7500;public static int Height = 7500;public static Emgu.CV.Image<Rgb, float>[] Images;static void Main(string[] args){int N = 50;int Threads = 5;Images = new Emgu.CV.Image<Rgb, float>[N];Console.WriteLine(“Start”);ParallelOptions po = new ParallelOptions();po.MaxDegreeOfParallelism = Threads;System.Threadi

  • user2855778
    c# emgucv
    I have an AXIS IP camera. address of this is:192.168.0.90 .User and pass is ‘admin’. I want to capture a video and saving it to AVI format by using Emgu CV lib into C#. But I can’t capture any frame. when I run this program, An exception happened:An unhandled exception of type ‘System.AccessViolationException’ occurred in Emgu.CV.dllAdditional information: Attempted to read or write protected memory. This is often an indication that other memory is corrupt. where is problem? My codes are:public

  • fouadalnoor
    emgucv
    I am trying to detect a pattern shown in two images. Hence I have been trying to use the SURF algorithim found in emgu.CV, but the “SURFFeature” example that is given gives me the following error:An unhandled exception of type ‘Emgu.CV.Util.CvException’ occurred in Emgu.CV.dllAdditional information: OpenCV: norm == NORM_L1 || norm == NORM_L2 || norm == NORM_HAMMINGAny ideas how to fix this?When I try the “Hello World” example and the face detection example, both seem to work fine.Thanks for any

  • Harsh
    c# wpf visual-studio-2010 emgucv
    I am trying EmguCV 2.2.1 in Visual Studio 2010 Express (C#) All the examples given with the Emgu Installation work absolutely fine, and give the desired output. But when i write a program myself, an exception is thrown at me even before running:TypeInitializationException was unhandled by user code. The type initializer for ‘Emgu.CV.CvInvoke’ threw an exception.I have included ALL the references required for running the program. I have also tried to copy the SAME “working” example to another loc

  • bobzc
    c# opencv video emgucv
    My c# program is about reading a video file and then write to another video file.It is strange that the exception does not occur every time. And it happens here:IntPtr img = CvInvoke.cvRetrieveFrame(Ptr, streamIdx);It says “An unhandled exception of type ‘System.AccessViolationException’ occurred in Emgu.CV.dll”This is my code:bool reading = true; while (reading) {Image<Bgr, Byte> frame = capture.QueryFrame(); if (frame != null){videoWriter.WriteFrame(frame);}else{reading = false;} }videoW

  • Jean-François Côté
    c# deployment emgucv
    I’m trying to create a program for webcam capture, in which I followed the online tutorial. I was able to debug it and deploy the program, but when I installed it on my PC the program failed to execute then gave an error message as follows Unhandled exception has occurred in your application. The type initializer for Emgu.CV.CvInvoke’ threw an exception. Has any one came across this kind of error? Please assist. Thanks

  • Danny Beckett
    c# opencv emgucv
    I get the following error when I try to invoke the BOWImgDescriptorExtractor compute method with BriefDescriptorExtractor and BruteForceMatcher.An unhandled exception of type ‘Emgu.CV.Util.CvException’ occurred in Emgu.CV.dllAdditional information: OpenCV: type == src2.type() && src1.cols == src2.cols && (type == CV_32F || type == CV_8U)Any idea how I can resolve this?

  • Nirupam
    c# emgucv
    I an new in emgu cv c#. I want to create a camera only for simple photocapture from my laptop camera and other camera device connected to my laptop.I dont want video capture only simple photo capture.with one start and one capture button.and will save in particular location.helped would be appreciable.namespace camera { public partial class cameracaps : Form {Capture capturecam=null;bool capturingprocess=false;Image<Bgr,Byte>imgOrg;Image<Gray,Byte>imgproc;public cameracaps(){Initiali

  • mipe34
    c# emgucv
    private void CameraCapture_Load(object sender, EventArgs e){ //Initialize the capture device capture_face = new Capture(); capture_face.QueryFrame(); //Initialize the CapturedFrame event Application.Idle += new EventHandler(CapturedFrame); }private void CapturedFrame(object sender, EventArgs e) { current_Frame = capture_face.QueryFrame().Resize(400, 320, Emgu.CV.CvEnum.INTER.CV_INTER_CUBIC);gray = current_Frame.Convert<Gray, Byte>(); }AccessViolationException was unhandled.- Att

  • Evan Evanson Evans
    c# visual-studio-2010 emgucv
    I’m trying to capture a video using EMGU CV in visual studio 2010, but when it executes the line video.WriteFrame<Bgr, byte>(marked);i get the follwing error:System.AccessViolationException was unhandledAttempted to read or write protected memory. This is often an indication that other memory is corrupt.private void button3_Click_1(object sender, EventArgs e){Capture camera = new Capture();if (camera == null){MessageBox.Show(“can’t find a camera”, “error”);}double fps = camera.GetCapturePr

  • sheldon90
    c# opencv emgucv
    I always get this error when I run my program…i’m not sure about what’s wrong with my program, FYI, actually my program consist of many image processing algorithm’s such as viola-jones, haarcascade for hand detection camshift + kalman filter for hand tracking convex hull and convexity defects for counting finger and other preprocessing ….I have no idea whether these process triggering the error or not…but when I remove convexhull / convexity defects, the errors gone… any solution?Edited

  • Jay
    c# c++ opencv matrix emgucv
    I’m using EmguCV Matrix.Add method to append one matrix to another matrix.Emgu.CV.Matrix<float> descriptors = new Emgu.CV.Matrix<float>(0, dictionarySize); Emgu.CV.Matrix<float> BOWDescriptor = imageDescriptorExtractor.Compute(trainingImage, keyPoints); descriptors.Add(BOWDescriptor);The corresponding OpenCV code is given below:Mat bowDescriptor(0, dictionarySize, CV_32FC1); Mat bowDescriptor; bowDE.compute(img, keypoints, bowDescriptor); descriptors.push_back(bowDescriptor);Du