Mac camera fail to initialise

asked 2019-07-16 16:46:36 -0600

TigerN gravatar image

updated 2019-07-17 07:08:55 -0600

supra56 gravatar image

Hi all,

When I try to run:

cv::VideoCapture cap;
cap.open(0);

I get the error:

Error:

OpenCV: not authorized to capture video (status 0), requesting...
OpenCV: camera failed to properly initialize!

It's my first time using OpenCV4 (4.1.0) with C++11 and Xcode.

Any help is appreciated.

Thanks, Tiger

edit retag flag offensive close merge delete

Comments

Go to System Preferences->Privacy->Camera and check your privacy permissions.

eshirima gravatar imageeshirima ( 2019-07-20 20:08:21 -0600 )edit

Hi eshirima, I have done that and all that requested camera access are granted camera permission. I think the issue is that my xcode commandline tool project is not requesting camera access properly.

TigerN gravatar imageTigerN ( 2019-07-21 14:18:14 -0600 )edit