The "Bitmap" type is defined in an Assembly that is not referenced C#

Asked

Viewed 22 times

0

The problem:

I’m doing a project using Windows Form C# which should basically record a video from a webcam and save to the computer. I was using the Aforge.net package to record the video and when I went to migrate to Accord.net I accidentally deleted a dll from the project and now it made an error when I try to capture the current frame of the camera and draw it in a bitmap. I am using Netframework 5.0.

Bitmap bitmapFrameAtual = new bitmapFrameAtual(640,480);
bitmapFrameAtual = (Bitmap)eventArgs.Frame.Clone(); // o erro acontece nessa linha

Accord.Video.VFW.AVIWriter writer = new AVIWriter("wmv3");
writer.AddFrame(bitmapFrameAtual);     // o erro acontece nessa linha

The mistake:

inserir a descrição da imagem aqui

My attempts:

I installed on Nuget and referenced this Assembly (Corecompat.System.Drawing) in my project and it didn’t work. I searched and found that the Bitmap type is part of the Assembly System.Drawing.Commom, but I installed and referenced it and it hasn’t solved my problem yet.

Can someone give me a light please. I thank you since!

No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.