1.
#include "opencv2/opencv.hpp" #include "opencv2/core/core.hpp" #include "opencv2/highgui/highgui.hpp" #include "opencv2/imgproc/imgproc.hpp" #include "opencv2/video/video.hpp" #include <iostream> #include <amcomdef.h> #include <arcsoft_face_sdk.h> #include <asvloffscreen.h> #include <merror.h> using namespace cv; int main() { VideoCapture capture; Mat frame; frame = capture.open("rtsp://admin:admin123@10.129.74.199:554/cam/realmonitor?channel=1&subtype=1"); if (!capture.isOpened()) { printf("can not open ... "); return -1; } namedWindow("output", CV_WINDOW_AUTOSIZE); while (capture.read(frame)) { imshow("output", frame); waitKey(10); } capture.release(); return 0; }