cycleCamera()

cycleCamera()

Compatibility:
Prebuilt
Custom

Switches the local camera stream to use the next available camera device. Has no effect if there is only one camera.

This is the easiest way to switch between the front and rear camera on a mobile device.

Returns a Promise that resolves with data about the camera device. (The data is copied from the camera's MediaDeviceInfo struct.)