I made one APP, and used the camera control, everything is fine, but I found it is very slow when opening the camera control, which need spend much time to wait the camera configurated on device.
And on the other hand, I also found if firstly navigate the screen of taking photos, 3~4 seconds can correctly configurate the camera and then can take photos, but when we close this screen, then navigate it again, issues occurred, which need too much time to wait camera control ready, sometimes, which need 1minutes.
I don't know why? Please share some knowledge.
The function is by clicking the camera icon to navigate to new screen to take photos, but need to wait so long time to make camera ready, once the camera is ready, click it and save photos is fine, no any problems.
Update (29/08): Setting the duration of the Timer to 2000ms resolved that user's issue (more time to load camera stream / camera devices).
Update (22/08): Some reason it's not working for Samsung s22 given it has 4 camera's in the following format:
"Name": "camera2 2, facing back"
"Name": "camera2 0, facing back"
"Name": "camera2 3, facing front"
"Name": "camera2 1, facing front"
*DesiredOrder was used to make the camera default to a back facing cam.
Will have another shot at it sometime hopefully.
Hmmm, okay I think I've found something promising this time, that works programmatically. It goes off Heathbar's idea (thank you!), which I tried without the use of a component, but still had no luck. I did notice however, that if the camera control gets the opportunity to load under a different available device (which could be done by swapping manually), then the camera rejigs itself and starts working again.
To force the load of a different device programmatically, instead of making the 'Default' property of the dropdown dynamic, we make the 'Camera' property of the camera control dynamic with respect to the dropdown.
To do this, we set the item's property to be a collection (colAvailableCameraDevices) and change the collection when the screen becomes visible. Then after a timer starts and stops, the collection is updated with the full available set of devices. The timer must be sufficiently long such that the stream shows on the camera control before the collection is updated (1000ms was the lowest I could get).
Visible: Coalesce(cvShowCamera, true)
Hope this makes sense!
Keep up to date with current events and community announcements in the Power Apps community.
A great place where you can stay up to date with community calls and interact with the speakers.
Check out the latest Community Blog from the community!