cozmo / jsQR

A pure javascript QR code reading library. This library takes in raw images and will locate, extract and parse any QR code found within.
https://cozmo.github.io/jsQR/
Apache License 2.0
3.73k stars 607 forks source link

Safari ask access to camera each time on iOS #207

Closed Alexscandal closed 3 years ago

Alexscandal commented 3 years ago

After each reloding page Safari ask access to camera. No issue on Android. How to resolve this issue?

ukscone commented 3 years ago

I have the same problem although i'm guessing it's not a jsQR problem as such but rather something to do with setting up/using the camera. other things like zxing-js don't seem to have the problem so i'm guessing need to compare camera setup between jsQR example and other examples

ukscone commented 3 years ago

actually i've just had a bit of a google and found this

https://support.scandit.com/hc/en-us/articles/360008443011-Why-does-iOS-keep-asking-for-camera-permissions-#h_01EN2HDPPMHYFFY9B3Y475YM6Q

Alexscandal commented 3 years ago

Thank you for answer.

cozmo commented 3 years ago

This library is a QR code scanner, and has no logic for camera access.

If you can confirm this is an issue with jsQR - aka not related to the webcam access, but rather to the call of this library, then feel free to clarify in the issue, however if you're just having trouble getting getUserMedia to work I'm unfortunately not going to be able to help much.

Perhaps get your webcam capturing to work and then add jsQR and see if you can isolate the issue from there?

Closing this issue until it's clear it's an issue with jsQR not the webcam capture. Please comment/re-open if you feel this is in error.