2014-07-15 05:40:51 -0600 | asked a question | I am not able to capture video from camera. I am using a usb frame grabber to connect my camera with my PC with Windows 7. I am running opencv 2.4.2 on Eclipse. I have also installed FFDshow. as i run my code for some time a black window comes after that Windows crashes and blue screen comes and system restarts. Pls help me striving for 3 days my code is like this : include "opencv2/highgui/highgui.hpp"include "opencv\cv.h"define CV_Husing namespace std; using namespace cv; int main() { int a = 0; IplImage frame; cvNamedWindow("Video", CV_WINDOW_AUTOSIZE); CvCapture capture = cvCreateCameraCapture(0); if(!capture){ cout<<"No camera found."<<endl; return="" -1;="" }="" for="" (a="0;" a<10;a++)="" {="" capture="" frame="" frame="cvQueryFrame(capture);</p"> } |