enableVocalInstrumentBalance method

Future<int?> enableVocalInstrumentBalance(
  1. bool enable
)

@detail api @author majun.lvhiei @brief 开启/关闭音量均衡功能。
开启音量均衡功能后,人声的响度会调整为 -16lufs。如果已调用 setAudioMixingLoudness 传入了混音音乐的原始响度,此音乐播放时,响度会调整为 -20lufs。 @param enable 是否开启音量均衡功能:
- true: 是 - false: 否 @return - 0: 调用成功。 - < 0 : 调用失败。查看 ReturnStatus{@link #ReturnStatus} 获得更多错误说明 @note 该接口须在调用 start{@link #IAudioEffectPlayer#start} 开始播放音频文件之前调用。

Implementation

Future<int?> enableVocalInstrumentBalance(bool enable) async {
  $a() => ($instance as $p_a.RTCEngine).enableVocalInstrumentBalance(enable);
  $i() =>
      ($instance as $p_i.ByteRTCEngine).enableVocalInstrumentBalance(enable);

  if (Platform.isAndroid) {
    return $a();
  } else if (Platform.isIOS) {
    return $i();
  } else {
    throw UnsupportedError(
        'Not Support Platform ${Platform.operatingSystem}');
  }
}