setChannelProfile abstract method

Future<void> setChannelProfile(
  1. ChannelProfileType profile
)

Sets the channel profile.

You can call this method to set the channel profile. The SDK adopts different optimization strategies for different channel profiles. For example, in a live streaming scenario, the SDK prioritizes video quality. After initializing the SDK, the default channel profile is the live streaming profile.

  • profile The channel profile. See ChannelProfileType.

Returns When the method call succeeds, there is no return value; when fails, the AgoraRtcException exception is thrown. You need to catch the exception and handle it accordingly. < 0: Failure. -2: The parameter is invalid. -7: The SDK is not initialized.

Implementation

Future<void> setChannelProfile(ChannelProfileType profile);