I need to check if appliaction has camera permission before launching ZXing barcode scanner or Augumented Reality page.
If I just launch them and user has disabled camera access in ios settings - barcode scanner either crashes or never returns and AR just crashes.
I tried :
UIImagePickerController.IsSourceTypeAvailable(UIImagePickerControllerSourceType.Camera);
but it returns true = camera supported.
Exception generated by launching AR (Wikitude)
ex {Foundation.MonoTouchException: Objective-C exception thrown. Name: NSGenericException Reason: *** AVCaptureSession can't startRunning between calls to beginConfiguration / commitConfiguration Native stack trace: 0 CoreFoundation 0x000000018514e0a0 + 160 1 libobjc.A.dylib 0x0000000195afc0e4 objc_exception_throw + 60 2
If app has camera permission AR starts OK.