AgoraIO-Extensions / Agora-Flutter-SDK

Flutter plugin of Agora RTC SDK for Android/iOS/macOS/Windows
https://pub.dev/packages/agora_rtc_engine
MIT License
739 stars 382 forks source link

muteAllRemoteAudioStreams not working #674

Closed Losspost closed 2 years ago

Losspost commented 2 years ago

Describe the bug When calling muteAllRemoteAudioStreams in the flutter sdk it will not mute the audio streams. It is still possible to hear all users.

To Reproduce Steps to reproduce the behavior:

  1. join voice channel
  2. call muteAllRemoteAudioStreams inside the code3.

Expected behavior Mute all remote Audio stream, can't hear the other users anymore.

Desktop (please complete the following information):

Initialize engine:

Future<StreamController> initEngine() async {

    _agoraUid = _userService.currentUser!.uid.hashCode;
    _engine = await RtcEngine.createWithContext(RtcEngineContext(appId));

    _addListeners();
  }

Join Channel:

Future<void> joinAudio(String channelName) async {
    // get Token for channel
    String token = await getAgoraToken(_agoraUid, channelName);
    await _engine.enableAudio();
    await _engine.setChannelProfile(ChannelProfile.LiveBroadcasting);
    await _engine.setClientRole(ClientRole.Broadcaster);

    await _engine
        .joinChannel(token, channelName, null, _agoraUid)
        .catchError((onError) {
      print(onError);
      logSink.log('error ${onError.toString()}');
    });

    _engine.muteAllRemoteAudioStreams(true);
  }
littleGnAl commented 2 years ago

Hello @Losspost, I'm sorry that I can't reproduce this issue, can you provide a reproducible demo for this case?

github-actions[bot] commented 2 years ago

Without additional information, we are unfortunately not sure how to resolve this issue. We are therefore reluctantly going to close this bug for now. If you find this problem please file a new issue with the same description, what happens, logs and the output. All system setups can be slightly different so it's always better to open new issues and reference the related ones. Thanks for your contribution.

github-actions[bot] commented 1 year ago

This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please raise a new issue.