arfoundation-samples icon indicating copy to clipboard operation
arfoundation-samples copied to clipboard

How to check the availability of camera rights for the current device

Open Leiong opened this issue 7 years ago • 6 comments

In addition to checking the availability of the AR on the current device, there is also how to check the availability of the camera rights of the current device. If the current camera permissions are disabled by the user, how do I get the current camera permission status.

Leiong avatar Jun 21 '19 03:06 Leiong

You can use the ARCorePermissionManager.

tdmowrer avatar Jun 21 '19 04:06 tdmowrer

@tdmowrer Hi,Is there a similar method for IOS systems? I didn't find it.

Leiong avatar Jun 21 '19 06:06 Leiong

@tdmowrer Hi,Is there a similar method for IOS systems? I didn't find it.

Sorry, the better, and cross-platform way, is to use ARCameraManager.permissionGranted.

tdmowrer avatar Jun 21 '19 06:06 tdmowrer

Thank you !!!

Leiong avatar Jun 21 '19 06:06 Leiong

Can you recomend a way to check camera permission before loading an AR scene? Could ARCameraManager.permissionGranted have a static counterpart maybe?

dorkbot avatar Jun 23 '19 07:06 dorkbot

There are methods of checking camera permission but we would not be adding that functionality outside of the context of an AR session.

mdurand42 avatar Apr 27 '20 22:04 mdurand42