opencv RTSP拉流
作者:
Caiaolun | 来源:发表于
2019-07-12 16:32 被阅读0次#include "opencv2\opencv.hpp"
#include <iostream>
using namespace cv;
int main()
{
VideoCapture capture;
capture.open("../../bin/data/1.mp4");
//capture.open("rtsp://admin:admin123@192.168.1.164:554/cam/realmonitor?channel=1&subtype=0");
int frameH = capture.get(4);
int frameW = capture.get(3);
std::cout << "frameH:" << frameH << " frameW:" << frameW << std::endl;
while (1)
{
Mat frame;
capture >> frame;
if (frame.empty())
{
break;
}
imshow("test", frame);
waitKey(30);
}
}
本文标题:opencv RTSP拉流
本文链接:https://www.haomeiwen.com/subject/xyrykctx.html
网友评论