setElectronicEffects method
Turn on or off the electronic sound effect.
Available since: 2.13.0 Description: Call this function to turn on or off the electronic sound effect. Use cases: Often used in live broadcasting, voice chatroom and sung unaccompanied scenes. Default value: When this function is not called, the electronic sound effect is not enabled by default. When to call: It needs to be called after createEngine. Restrictions: None. Caution: When the mode parameter is Harmonic Minor, the tonal parameter does not take effect. Related APIs: Common electronic sound effect configurations can be set via setVoiceChangerPreset.
enabletrue to turn on the electronic sound effect, false to turn off the electronic sound effect.modeMode of Electronic Effects reference.tonalThe starting pitch of an electric tone in a given mode, representing 12 semitones in one octave of the sound, in the range0, 11.
Implementation
Future<void> setElectronicEffects(
bool enable, ZegoElectronicEffectsMode mode, int tonal) async {
return await ZegoExpressImpl.instance
.setElectronicEffects(enable, mode, tonal);
}