adjustCustomAudioPlayoutVolume abstract method

Future<void> adjustCustomAudioPlayoutVolume({
  1. required int trackId,
  2. required int volume,
})

Adjusts the local playback volume of a custom audio track.

After calling this method to set the local playback volume of the audio, if you want to adjust the volume again, you can call this method again. Before calling this method, make sure you have already called createCustomAudioTrack to create a custom audio track.

  • trackId Audio track ID. Set this parameter to the custom audio track ID returned by the createCustomAudioTrack method.
  • volume Playback volume of the custom audio capture. Range: 0,100. 0 means mute, 100 means original volume.

Returns When the method call succeeds, there is no return value; when fails, the AgoraRtcException exception is thrown. You need to catch the exception and handle it accordingly. See Error Codes for details and resolution suggestions. < 0: Method call failed. See Error Codes for details and resolution suggestions.

Implementation

Future<void> adjustCustomAudioPlayoutVolume(
    {required int trackId, required int volume});