startVideoCapture method

FutureOr<int> startVideoCapture()

@detail api @hiddensdk(audiosdk) @author zhangzhenyu.samuel @brief Enable internal video capture immediately. The default setting is off.
Internal video capture refers to: capturing video using the built-in module.
The local client will be informed via onVideoDeviceStateChanged{@link #IRTCEngineEventHandler#onVideoDeviceStateChanged} after starting video capture by calling this API.
The remote clients in the room will be informed of the state change via onUserStartVideoCapture{@link #IRTCEngineEventHandler#onUserStartVideoCapture} after the visible client starts video capture by calling this API. @return - 0: Success. - < 0 : Fail. See ReturnStatus{@link #ReturnStatus} for more details @note - Since the upgrade in v3.37.0, you need to add Kotlin plugin to Gradle in the project to use this API. - Call stopVideoCapture{@link #RTCEngine#stopVideoCapture} to stop the internal video capture. Otherwise, the internal video capture will sustain until you destroy the engine instance. - Once you create the engine instance, you can start internal video capture regardless of the video publishing state. The video stream will start publishing only after the video capture starts. - To switch from custom to internal video capture, stop publishing before disabling the custom video capture module and then call this API to enable the internal video capture. - Call switchCamera{@link #RTCEngine#switchCamera} to switch the camera used by the internal video capture module. - If the default video format can not meet your requirement, contact our technical specialist to help you with Cloud Config. After that, you can push and apply these configurations to Android clients at any time.

Implementation

FutureOr<int> startVideoCapture() async {
  return await nativeCall('startVideoCapture', []);
}