muteAllRemoteAudioStreams
Stops or resumes subscribing to the audio streams of all remote users.
abstract muteAllRemoteAudioStreams(mute: boolean): number;
Details
After successfully calling this method, the local user stops or resumes subscribing to the audio streams of all remote users, including all subsequent users.
Note:
- Call this method after the or joinChannel method.
- When using the spatial audio effect, if you need to set whether to stop subscribing to the audio streams of all remote users, Agora recommends calling this method instead of the muteAllRemoteAudioStreams method in IRtcEngine.
- After calling this method, you need to call updateSelfPosition and updateRemotePosition to update the spatial location of the local user and the remote user; otherwise, the settings in this method do not take effect.
Parameters
- mute
-
Whether to stop subscribing to the audio streams of all remote users:
true
: Stop subscribing to the audio streams of all remote users.false
: Subscribe to the audio streams of all remote users.
Returns
- 0: Success.
- < 0: Failure.