I am building my app on iOS and Android with Agora's Video SDK. For some reason if the user changes his/her role during the live streaming, the volume of the stream changes. Is there a way to prevent that?
Asked
Active
Viewed 144 times
1 Answers
0
To ensure a better audio experience in different scenarios, by default, the SDK adjusts the underlying audio settings when the user switches user roles, as follows:
- The audience role uses the media volume control.
- The host role uses the call volume control. The media volume and call volume have separate volume control mechanisms.
To avoid volume changes when the user switches user roles, ensure that the volume type used by the SDK remains the same before and after the switch. The volume type used by the SDK varies from case to case. See Volume type introduction for details.
For example, if you use AUDIO_SCENARIO_CHATROOM_ENTERTAINMENT on Android and AUDIO_SCENARIO_GAME_STREAMING on iOS, then even if the user role switches and the audio routing changes, the user's volume type does not change, and thus the volume is not affected.

Rick Cheng
- 654
- 3
- 7
-
Hey, I am having another problem using agora rtc engine in flutter. I am new with the library. I posted the question here https://stackoverflow.com/questions/74280910/trouble-using-agora-rtc-engine-in-my-flutter-app – LearnFlutter Nov 02 '22 at 15:11