Error message when I try to run this code [closed]

asked 2018-11-07 11:58:52 -0500

updated 2018-11-07 12:09:37 -0500

berak gravatar image

these error message : OpenCV: Cannot use FaceTime HD Camera (Built-in) OpenCV: camera failed to properly initialize!

code: import cv2 as cv import numpy as np

cap = cv.VideoCapture(0)

while True: ret, frame = cap.read() cv.imshow('frame', frame) if cv.waitKey(1) & 0xFF == ord('q'): break

cap.release() cv.destroyAllWindows()


macOS Mojave

edit retag flag offensive reopen merge delete

Closed for the following reason question is off-topic or not relevant by berak
close date 2018-11-07 12:09:01.746948

Comments

it's a restriction of your silly os (access rights using the webcam, look it up, please), not an opencv problem.

berak gravatar imageberak ( 2018-11-07 12:08:52 -0500 )edit