disableCamera()
This function releases the Apple device camera (either front or back) from being controlled by the Aila SDK for use cases where third party SDK's or other non-Aila functions require control of the camera.
Because AVCaptureSession interacts with the main thread this function should be called as an asynchronous operation off of the main thread to ensure deadlock does not occur. This function returns immediately. The camera is not ready to use until the promise resolves.
Barcode scanning is disabled while this is in effect.
AilaCordovaPlugin.disableCamera()
Returns
Promise that resolves when camera control is released.
Example
AilaCordovaPlugin.disableCamera()
.then(() => {
console.log('Camera control released');
setupCustomCamera();
});