BaseVideoCapturer.CaptureSwitch

public abstract static interface CaptureSwitch

Enclosing class: BaseVideoCapturer

An interface for defining how the BaseVideoCapturer.CaptureSwitch#cycleCamera() method of a Publisher object that implements a custom video capturer.

If you are using a custom video capturer, implement the CaptureSwitch interface in the object that extends BaseVideoCapturer. Then implement the cycleCamera() method to define the behavior of the Publisher#cycleCamera() method for the Publisher object that uses the video capturer.

Methods

Name Description
cycleCamera() Defines the behavior of the Publisher#cycleCamera() method for a Publisher object that uses the custom video capturer.
getCameraIndex() → {int} Defines the behavior of the deprecated Publisher#getCameraId() method for a Publisher object that uses the custom video capturer.
swapCamera(cameraId) Defines the behavior of the deprecated Publisher#swapCamera() method for a Publisher object that uses the custom video capturer.

cycleCamera()

Defines the behavior of the Publisher#cycleCamera() method for a Publisher object that uses the custom video capturer. Generally, you will want to shut down the current active camera and start up a new camera.

getCameraIndex() → {int}

Defines the behavior of the deprecated Publisher#getCameraId() method for a Publisher object that uses the custom video capturer.

Returns:

int

swapCamera(cameraId)

Defines the behavior of the deprecated Publisher#swapCamera() method for a Publisher object that uses the custom video capturer.

Parameters:
Name Type Description
cameraId int