USB 웹캠으로 작업 할 수 있지만, 여러 대의 카메라에 연결할 수있는 비디오 카드가 있습니다. AForge가 비디오 카드를 사용하려면 어떻게해야합니까?AForge - 여러 대의 카메라로 비디오 카드로 작업하기
제 문제는 VideoInputDevice
을 작동중인 비디오 입력으로 설정할 수 없었습니다.
코드는 다음과 같다 : 나는 또한 시도
void init(){
FilterInfoCollection videoCaptureDevice =
new FilterInfoCollection(FilterCategory.VideoInputDevice);
VideoCaptureDevice finalVideo =
new VideoCaptureDevice(videoCaptureDevice[0].MonikerString);
finalVideo.NewFrame += new NewFrameEventHandler(finalVideo_NewFrame);
finalVideo.Start();
}
public void finalVideo_NewFrame(object sender, NewFrameEventArgs eventArgs)
{
Bitmap temp = (Bitmap)eventArgs.Frame.Clone();
pictureBox1.Image = temp;
}
:
finalVideo = new VideoCaptureDevice();
finalVideo.CrossbarVideoInput = VideoInput.Default;
과 중 하나가 작동하지 않았다.
도움이 매우 감사합니다. 코드
VideoCaptureDevice finalVideo = new VideoCaptureDevice(videoCaptureDevice[0].MonikerString);
에서
유감스럽게도 videoCaptureDevice가 null이기 때문에 작동하지 않습니다. 그것은 비디오 입력을 보지 못했습니다. –
흠 그 이상한 당신은 또한 당신이 그것을 USB 비디오 카메라와 함께 작동 시키도록 할 수 있다고 썼다. 그래서 문제를 일으키는 캡처 카드입니다. 코드 내에서 특정 환경에 유용 할 수있는 의견이 가득 찼습니다. 여기를보세요 http://aforge.googlecode.com/svn-history/r1680/trunk/Sources/Video.DirectShow/VideoCaptureDevice.cs – user613326