ChannelMediaRelayConfiguration
Cross-channel media relay configuration information.
export class ChannelMediaRelayConfiguration {
srcInfo?: ChannelMediaInfo;
destInfos?: ChannelMediaInfo[];
destCount?: number;
}
Properties
- srcInfo
- Source channel information ChannelMediaInfo, including the following members:
channelName: Name of the source channel. The default value is null, which means the SDK fills in the current channel name.token: Thetokenused to join the source channel. It is generated based on thechannelNameanduidyou set insrcInfo.- If App Certificate is not enabled, you can set this parameter to the default value null, which means the SDK fills in the App ID.
- If App Certificate is enabled, you must provide a
tokengenerated using thechannelNameanduid, and theuidmust be 0.
uid: The UID that identifies the media stream being relayed in the source channel. The default value is 0. Do not modify it.
- destInfos
-
Note: Since token expiration in any destination channel will cause all cross-channel streaming to stop, it is recommended that you set the same expiration duration for tokens in all destination channels.Destination channel information ChannelMediaInfo, including the following members:
channelName: Name of the destination channel.token: Thetokenused to join the destination channel. It is generated based on thechannelNameanduidyou set indestInfos.- If App Certificate is not enabled, you can set this parameter to the default value null, which means the SDK fills in the App ID.
- If App Certificate is enabled, you must provide a
tokengenerated using thechannelNameanduid.
uid: The UID that identifies the media stream being relayed in the destination channel. The value range is [0, 2^32-1]. Make sure it is different from all UIDs in the destination channel. The default value is 0, which means the SDK randomly assigns a UID.
- destCount
- Number of destination channels. The default value is 0. Value range is [0,6]. This parameter should match the number of ChannelMediaInfo objects defined in
destInfos.