报错如下:

CvCapture_MSMF::initStream Failed to set mediaType (stream 0, (640x480 @ 30) MFVideoFormat_RGB24(codec not found)
`anonymous-namespace'::SourceReaderCB::~SourceReaderCB terminating async callback

解决方式

cv2.VideoCapture(0 + cv2.CAP_DSHOW)

转自:http://t.zoukankan.com/geoffreygao-p-14266884.html


↙↙↙阅读原文可查看相关链接,并与作者交流