Main API Logic

Follow the API logic to implement the basic communication or live broadcast function.

The letters in italic are the API names, which might not the same across all platforms. For details, refer to each platform API reference document.

Communication

1

Select the channel mode.

Set the channel mode as communication.

setChannelProfile

2

Start the video.

Start the video.

enableVideo

3

Set the local and remote video view.

Local: setupLocalVideo

Remote: setupRemoteVideo

4

Set the video profiles.

Resolution, frame rate, and bitrate.

setVideoProfile

5

Start the conference/call.

Join the channel.

joinChannel

6

Exit the conference/call.

Leave the channel.

leaveChannel

Live Broadcast

1

Select the channel mode.

Set the channel mode as live broadcast.

setChannelProfile

2

Start the video.

Start the video.

enableVideo

3

Set the local and remote video view.

Local: setupLocalVideo

Remote: setupRemoteVideo

4

Set the video profiles.

Resolution, frame rate, and bitrate.

setVideoProfile

5

Set the user role.

Host or audience(default).

setClientRole

6

Set the stream mode.

Set the stream mode single or dual.

enableDualStreamMode

7

Set the stream type to be received.

High video stream or low video stream

setRemoteVideoStreamType

8

Start the live broadcast.

Join the channel.

joinChannel

9

Exit the live broadcast.

Leave the channel.

leaveChannel