setLocalSimulcastMode method
- VideoSimulcastMode mode,
- Array<
VideoEncoderConfig> streamConfig
@valid since 3.60. @detail api @brief Enable the Simulcast feature and configure the lower-quality video streams settings. @param mode Whether to publish lower-quality streams and how many of them to be published. See VideoSimulcastMode{@link #VideoSimulcastMode}. By default, it is set to Single, where the publisher sends the video in a single profile. In the other modes, the low-quality stream is set to a default resolution of 160px × 90px with a bitrate of 50Kbps. @param streamConfig The specification of the lower quality stream. You can configure up to three low-quality streams for a video source. See VideoEncoderConfig{@link #VideoEncoderConfig}. The resolution of the lower quality stream must be smaller than the standard stream set via setVideoEncoderConfig{@link #RTCEngine#setVideoEncoderConfig}. The specifications in the array must be arranged in ascending order based on resolution. In the other modes, the low-quality stream is set to a default resolution of 160px × 90px with a bitrate of 50Kbps. @return - 0: Success. - < 0 : Fail. See ReturnStatus{@link #ReturnStatus} for more details. @note - The default specification of the video stream is 640px × 360px @15fps. - The method applies to the camera video only. - Refer to Simulcasting for more information.
Implementation
FutureOr<int> setLocalSimulcastMode(
VideoSimulcastMode mode, Array<VideoEncoderConfig> streamConfig) async {
return await nativeCall(
'setLocalSimulcastMode', [mode.$value, streamConfig]);
}