I am unable to open the video camera and read the frames. Below is the Python code.
import cv2 as cv
cap = cv.VideoCapture()
while True:
success, frame = cap.read()
... do something with the frame ...
... break on a certain key ...
cap.release()
I noticed that success is False and no frame is read. I am not sure if there are specific permissions I need to set on my MacBook Pro. I explored the security settings and also the accessibility settings but could not find anything other than applications that typically expect to use the video camera. I also don't know if I need to and if there is some way to switch on the video camera in the Mac. I am using PyCharm and my macOS version is 10.15 (upgraded only last week).
My current workaround is to play the video into a file and read the file. That works. If you have any suggestions for me to try, I will do that right away. Thank you.