Hi all, I know this has been asked before, but i can't get it to work despite that...
I have a foscam FI9821EP ip camera that i am trying to use inside opencv.
this code pops up a window, then closes it instantly. Driving me mad! Any help greatly appreciated.
Mat frame;
namedWindow("video", 1);
VideoCapture cap("http://192.168.1.90:88/cgi-bin/CGIStream.cgi?cmd=GetMJStream&usr=xxx&pwd=xxx&.mjpg");
while (cap.isOpened())
{
cap >> frame;
if (frame.empty()) break;
imshow("video", frame);
if (waitKey(30) >= 0) break;
}