enableCustomAudioIO method

Future<void> enableCustomAudioIO(
  1. bool enable,
  2. ZegoCustomAudioConfig config,
  3. {ZegoPublishChannel? channel}
)

Enables the custom audio I/O function (for the specified channel), support PCM, AAC format data.

Available since: 1.10.0 Description: Enable custom audio IO function, support PCM, AAC format data. Use cases: If the developer wants to implement special functions (such as voice change, bel canto, etc.) through custom processing after the audio data is collected or before the remote audio data is drawn for rendering. When to call: It needs to be called before startPublishingStream, startPlayingStream, startPreview, createMediaPlayer, createAudioEffectPlayer and createRealTimeSequentialDataManager to be effective. Restrictions: None.

  • enable Whether to enable custom audio IO, default is false.
  • config Custom audio IO config.
  • channel Specify the publish channel to enable custom audio IO.

Implementation

Future<void> enableCustomAudioIO(bool enable, ZegoCustomAudioConfig config,
    {ZegoPublishChannel? channel}) async {
  return await ZegoExpressImpl.instance
      .enableCustomAudioIO(enable, config, channel: channel);
}