简体   繁体   English

OpenCV无法访问模拟摄像机

[英]opencv cant access analog camera

I have a analog camera whose video I see on my computer using EASYCAP video capture device. 我有一台模拟摄像机,使用EASYCAP视频捕获设备可以在计算机上看到其视频。 I also have a webcam. 我也有一个摄像头。 When I try running any OPENCV videocapture code in C++ it picks video only from my webcam and not the analog camera. 当我尝试在C ++中运行任何OPENCV视频捕获代码时,它仅从我的网络摄像头而不是模拟摄像头中选择视频。

I can see the video from analog camera in Windows Movie maker but C++ wont access it. 我可以在Windows Movie maker中看到来自模拟摄像机的视频,但C ++无法访问它。 I noticed that the capture device is stored in the device manager as a sound,video and game controller while the webcam is stored as a imaging device. 我注意到捕获设备作为声音,视频和游戏控制器存储在设备管理器中,而网络摄像头作为成像设备存储。 Is it not showing this feed because OPENCV wont recognize it. 是否没有显示此供稿,因为OPENCV无法识别它。

Can anyone please advice me how they connect their analog camera (FPV, IR, etc) to the computer and process it. 谁能告诉我他们如何将模拟摄像机(FPV,IR等)连接到计算机并进行处理。 I have to process the video from a external analog camera which I connect to the PC using a video capture device. 我必须处理来自外部模拟摄像机的视频,该摄像机使用视频捕获设备连接到PC。

Thanks. 谢谢。

Use VideoCapture cap(1); 使用VideoCapture cap(1); ....the difference is using "1" instead of "0" in cap() ....区别是在cap()使用“ 1”而不是“ 0”

i struggled with the same problem (using python instead) and hope it helps! 我在同一个问题上挣扎(使用python代替),希望对您有所帮助!

the original thread + answer 原始主题+答案

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM