win10下vs2015使用opencv3.2读取摄像头一直是和灰色
opencv吧
全部回复
仅看楼主
level 1
s15534656510 楼主
#include <opencv2/highgui/highgui.hpp>
#include <opencv2/imgproc/imgproc.hpp>
#include <opencv2/core/core.hpp>
using namespace cv;
int main()
{
VideoCapture cap(0);
Mat frame;
while (1)
{
cap >> frame;
waitKey(30);
imshow("调用摄像头", frame);
waitKey(30);
}
return 0;
}
望解决!!!!!!!!!!!!!!!
2017年03月19日 02点03分 1
level 1
s15534656510 楼主
电脑没有升级驱动的问题
2017年05月01日 10点05分 2
请问楼主这个驱动怎么升级呢?我也是这个问题
2019年10月31日 03点10分
@远征星辰大海☜ 系统驱动,随便找个装驱动的,360 驱动精灵等等
2019年11月22日 04点11分
level 1
你可以设置一下帧率 Frame rate
比如
VideoCapture cap(0);
cap.set(CV_CAP_PROP_FPS, 480);
2017年08月27日 11点08分 4
level 6
我试了 是正常的啊,就是你的代码
2017年09月02日 00点09分 5
1