我有Form1和Form2
通过 AForge调用摄像头显示画面,怎么通过btnConnect_Click方法让Form1上的vispShoot1和Form2上的vispShoot2和同时显示摄像头画面?
下面是我在Form1上的vispShoot1显示的摄像头画面的方法。
public FilterInfoCollection videoDevices;
public VideoCaptureDevice videoDevice;
public VideoCapabilities[] videoCapabilities;
private void btnConnect_Click(object sender, EventArgs e)
{
videoDevices = new FilterInfoCollection(FilterCategory.VideoInputDevice);
videoDevice = new VideoCaptureDevice(videoDevices[0].MonikerString);
videoCapabilities = videoDevice.VideoCapabilities;
videoDevice.VideoResolution = videoCapabilities[0];
vispShoot1.VideoSource = videoDevice;
vispShoot1.Start();
}