setAudioDualMonoMode abstract method

Future<void> setAudioDualMonoMode(
  1. AudioDualMonoMode mode
)

Sets the channel mode of the current audio file.

In stereo audio files, the left and right channels can store different audio data. Depending on your needs, you can set the channel mode to original, left channel, right channel, or mixed mode. For example, in a KTV scenario, the left channel of an audio file stores the accompaniment, and the right channel stores the original vocal. If you only want to hear the accompaniment, call this method to set the channel mode to left channel; if you want to hear both the accompaniment and the original vocal, set the channel mode to mixed mode. You need to call this method after calling open. This method applies to stereo audio files only.

  • mode Channel mode. See AudioDualMonoMode.

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.

Implementation

Future<void> setAudioDualMonoMode(AudioDualMonoMode mode);