Details
-
Bug
-
Resolution: Unresolved
-
P2: Important
-
None
-
6.9
-
None
Description
Observed on macOS and iOS.
If you have a QML setup similar to the following:
CameraPermission { id: cameraPermission onStatusChanged: () => { if (status === Qt.PermissionStatus.Granted) { myCamera.active = true } } } Component.onCompleted: cameraPermission.request() TestLib.CameraHelper { id: myCamera active: true }
Then the camera will have the property "active" set to true, even before the permission is granted, and it will not transmit any frames. If the user then grants access, the camera will still not send transmit any frames even though it is still marked as active and permission is granted.
This leaves the camera in an unusable state until the user switches device and then back. This method is impossible if the user only has a single camera connected.
What do you expect to happen
I expect the camera to not go into "active = true" whenever permission is not granted. Instead I expect it to start working once I assign true to the "active" property, only after permission has been granted.