How to test IOS runtime camera permission?
-
Developing a app for Android and IOS.
QT 5.11.1For IOS, popup permission request, if click "Don't Allow", will not popup permission requests (this behaviour is perfect).
But when use this camera (did not sign camera permission at installation stage), QtMultimedia.availableCameras.length return 2. (for android, here return 0 if has no permission). So App failed to get a correct result about available camera due to no related permission here.IOS show camera in black and camera could not use (here QtMultimedia.availableCameras.length is used to decide whether to start camera or not, but for IOS, it looks this method does not work),
How to request permission during run-time for IOS and detect no permission granted (like this case, QtMultimedia.availableCameras.length return 2, but has no permission). Many thanks.
More hints about IOS: not matter sign camera permission at installation stage or not, these has the same values (QtMultimedia.availableCameras.length:2, camera.cameraStatus: 8, camera.availability:0, camera.cameraState:2). Even camera.imageCapture.ready return true. I don't know How to get camera permission status at runtime in IOS?
-
Hi,
You may have to do the check natively. See this stack overflow thread.