I am writing a c# program with emgucv library. I use the imagebox in emgucv to capture image from webcam. And I want to get the color pixel of the image by using bitmap.Getpixel() by mouse clicking the imagebox. However, it contain error The error is..it cannot implicitly convert type 'Emgu.CV.IImage' to 'System.Drawing.Bitmap'
Can anyone give me idea to solve this problem?
Bitmap bitmap = newdetectimageBox.Image; //error
Please use this code
Image<Bgr, Byte> ImageFrame = newdetectimageBox.Image ; //Capture the cam Image
Bitmap BmpInput = ImageFrame.ToBitmap(); //Convert the emgu Image to BitmapImage
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With