使用 opencv byC++ 从 IP cam 捕获帧
Capture frame from ip cam using opencv byC++
my ipcam's ip http://admin:@192.168.1.124:80/
谁能教我如何使用OpenCV2.4.3编写真正的程序来连接到IPCAM希望能给我完整的程序参考多谢
基本的相机样板,无论输入什么:
#include "opencv2/highgui/highgui.hpp"
#include "opencv2/core/core.hpp"
using namespace cv;
int main()
{
VideoCapture cap("http://admin:@192.168.1.124:80/"); // connect to an ip-cam ( might need some additional dummy param like: '?type=mjpeg' at the end
//VideoCapture cap("/home/me/some.avi"); // load a video file
//VideoCapture cap(-1); // get the 1st 'local' usb webcam
while( cap.isOpened() )
{
Mat frame;
if ( ! cap.read(frame) )
break;
//
// your processing here
//
imshow("lalala",frame);
int k = waitKey(10);
if ( k==27 )
break;
}
return 0;
}
相关文章:
- 我正在开发服务器,ip作为参数传递不起作用
- 如何使用 Boost Asio 在 Android 上获取我的本地 udp IP 地址?
- 我可以与 python 服务器而不是 c++ 客户端建立 tcp/ip 套接字吗?
- C++ boost::asio::ip::tcp::acceptor 有时不接受连接器?
- 从网址获取 IP (C++)
- 为什么 WinInet 在通过 FQDN 连接时无法通过协商自动进行身份验证,但如果通过 IP 连接则成功?
- 如何修复无效的API密钥,IP或操作权限错误?
- C++ Winsock2 客户端未通过远程 IP 连接到服务器
- PHP Profiler语言 - 使用 C++ 从 PHP 扩展获取客户端 IP 和 URL
- 为什么 boost::asio::ip::tcp::basic_stream_socket::available 的运行
- 如何使用 libcurl 在本地 IP 上获取 HTML?
- 在C++中使用宏验证 IP 时出错
- 使用 IP 帮助程序的 Windows 中活动 UDP 连接的远程地址
- 将静态 IP 分配给我的 ESP32 服务器后不再响应
- C++ / Qt:如何检测主机名或IP地址何时引用当前系统?
- "acceptor"在从TCP迁移到UDP时不是"boost::asio::ip::udp
- 用于C++的 TCP/IP 解析器和响应器
- 使用 C++将 IP 地址附加到字符*
- 使用 opencv byC++ 从 IP cam 捕获帧
- 捕获图像从IP /以太网摄像机(AXIS Cam)