I've been using kap-camera on Big Sur for some time and it was working fine using built-in webcam for MacBook Pro 2018. I decided to use external webcams, as soon as I added the new webcams (Sony ZV-1 and iPhone as webcam via EpocCam), kap-camera stopped working. I was getting the "kap-camera does not have access to camera error" while Kap had access. I did a bit of debugging and found the issue.
Issue
I noticed that the code depends on the below function to return true:
Not sure if this is the best way to fix it but I have updated the function to support the previous format and the new format. I got my camera back with this fix, however it only works with internal webcam. Not sure why I can't get the output from my external webcams. I have selected the right camera in settings yet always get the video from built-in macbook one.
I think the correct fix is to make a somewhat unique identifier string and detect that. true could be part of some debug output too, so it's not reliable in this case. Maybe '__KAP_CAMERA_TRUE__'.
Story
I've been using
kap-camera
on Big Sur for some time and it was working fine using built-in webcam for MacBook Pro 2018. I decided to use external webcams, as soon as I added the new webcams (Sony ZV-1 and iPhone as webcam via EpocCam), kap-camera stopped working. I was getting the "kap-camera does not have access to camera error" while Kap had access. I did a bit of debugging and found the issue.Issue
I noticed that the code depends on the below function to return true:
which expected the binary to print "true". At least in my case, it doesn't only print "true".
This is the log I get when I run "permission" binary manually.
Solution
Not sure if this is the best way to fix it but I have updated the function to support the previous format and the new format. I got my camera back with this fix, however it only works with internal webcam. Not sure why I can't get the output from my external webcams. I have selected the right camera in settings yet always get the video from built-in macbook one.