enableAudioEncoding method

Future enableAudioEncoding(
  1. bool enable
)

@hidden for internal use only @region custom audio acquisition rendering @brief whether to use sdk audio encoding. @param enable whether to use audio encoding.
。 - true: audio encoding is turned on.(default) - false: audio encoding is turned off. @note - use before pushExternalEncodedAudioFrame{@link #RTCEngine#pushExternalEncodedAudioFrame}.

Implementation

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

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