public partial class Form1 : Form
{
private Capture cap = null;
public Form1()
{
InitializeComponent();
cap = new Capture(0);
Application.Idle+=new EventHandler(Application_Idle);
}
private void Application_Idle(object sender, EventArgs e)
{
Mat frame = new Mat();
frame = cap.QueryFrame();
Image<Bgr, Byte> fram = frame.ToImage<Bgr, Byte>();
picRaw.Image = fram.ToBitmap();
{
private Capture cap = null;
public Form1()
{
InitializeComponent();
cap = new Capture(0);
Application.Idle+=new EventHandler(Application_Idle);
}
private void Application_Idle(object sender, EventArgs e)
{
Mat frame = new Mat();
frame = cap.QueryFrame();
Image<Bgr, Byte> fram = frame.ToImage<Bgr, Byte>();
picRaw.Image = fram.ToBitmap();
}
}