Skip to main content

getAVCaptureSession()

Obtain reference to Aila's internal AVCaptureSession (iOS only).

Aila requires full control of the session, so user code must not modify the session or camera configuration in any way, except to add or remove additional capture outputs. (For example, it may be desirable to add an AVCaptureVideoPreviewLayer to the app's user interface in order to assist end-users in scanning.)

warning

User code must not modify the configuration of this session even if disableCamera() is in effect. Instead, another AVCaptureSession should be created.

AilaCordovaPlugin.getAVCaptureSession()

Returns

Promise that resolves with an ArrayBuffer reference to the AVCaptureSession.

Example

AilaCordovaPlugin.getAVCaptureSession()
.then((sessionRef) => {
console.log('AVCaptureSession reference:', sessionRef);
});

Platform Support

  • iOS: Supported
  • Android: Not available