setAudioMixingDualMonoMode method
Sets the channel mode
of the current music file.
In a stereo music file, the left and right channels can store different audio data. According to your needs, you can set the channel mode to original mode, left channel mode, right channel mode, or mixed channel mode. For example, in the KTV scenario, the left channel of the music file stores the musical accompaniment, and the right channel stores the singing voice. If you only need to listen to the accompaniment, call this method to set the channel mode of the music file to left channel mode; if you need to listen to the accompaniment and the singing voice at the same time, call this method to set the channel mode to mixed channel mode.
Parameter mode
The channel mode. See AudioMixingDualMonoMode.
Note:
- Call this method after calling startAudioMixing and receiving the RtcEngineEventHandler.audioMixingStateChanged event callback with state code AudioMixingStateCode.Playing.
- This method only applies to stereo audio files.
Implementation
@override
Future<void> setAudioMixingDualMonoMode(AudioMixingDualMonoMode mode) {
return _invokeMethod('setAudioMixingDualMonoMode', {
'mode': AudioMixingDualMonoModeConverter(mode).value(),
});
}