Sublime Forum

After upgrade to mac OS Catalina I have NO permission to use my iMac camera!?

#1

After upgrade to mac OS Catalina I have no permission to use my iMac camera!

This is my test program:
import cv2
print(cv2.version)

cam=cv2.VideoCapture(0)
while True:
ret, frame = cam.read()
cv2.imshow(‘nanoCam’,frame)
if cv2.waitKey(1)==ord(‘q’):
break

cam.release()
cv2.destroyAllWindows()
cv2.waitKey(1)
+++++++++++++++++++
Output event report:
3.4.2
[Finished in 1.3s with exit code -6]
[cmd: [’/Users/joseperes/anaconda/anaconda3/bin/python3’, ‘-u’, ‘/Users/joseperes/Desktop/cam_Opencv.py’]]
[dir: /Users/joseperes/Desktop]
[path: /usr/bin:/bin:/usr/sbin:/sbin]

On my iMac in setting security and Privacy does not appear ‘Sublime Text’ app to give permission!

Could anyone give an idea to fix this . . .
I can run all programs openCV but without using the camera!

Thanks in advance.

José

0 Likes

#2

Does running your code from a terminal give you the same results? If so the problem lies with anaconda, not Sublime Text.

0 Likes

#3

Yes I got the same results running the code from a terminal!
But I did not have Anaconda installed in my iMac since last October . . .

After running a simple python test, I get sublime msg “Python closed unexpectedly” , send me a python crash report! This situation ocurrs after upgrade my iMax to masOs Catalina . . .

Tks for your answer

error msg:
2.7.15 (v2.7.15:ca079a3ea3, Apr 29 2018, 17:49:27)
[GCC 4.2.1 (Apple Inc. build 5666) (dot 3)]
3.4.1
[Finished in 0.4s with exit code -6]
[shell_cmd: python -u “/Users/joseperes/Desktop/checkversion.py”]
[dir: /Users/joseperes/Desktop]
[path: /Library/Frameworks/Python.framework/Versions/2.7/bin:/usr/local/bin:/usr/local/bin:/Library/Frameworks/Python.framework/Versions/2.7/bin:/Library/Frameworks/Python.framework/Versions/3.7/bin:/opt/local/bin:/opt/local/sbin:/usr/local/bin:/usr/local/sbin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/minicom/2.2/bin:/opt/X11/bin:/usr/local/share/dotnet:/Library/Frameworks/Mono.framework/Versions/Current/Commands]

0 Likes