Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Flutter text to speech low volume on ios

Tags:

flutter

In my app on ios, I am using flutter tts. It is working as expected on Android but on ios the volume is very low because the audio is coming from the earpiece(not from the speaker). Because of this, the volume is very very low. How do I switch the audio output to the speaker? Any suggestions are welcomed. Thanks in advance.

This is my code:

    await flutterTts.setSpeechRate(Platform.android == true ? 0.97 : 0.53);
    await flutterTts.speak("I am a Flutter developer");
like image 718
Joshua Avatar asked Sep 02 '25 06:09

Joshua


1 Answers

Try:

await flutterTts.setIosAudioCategory(IosTextToSpeechAudioCategory.playback, [
  IosTextToSpeechAudioCategoryOptions.defaultToSpeaker
]);
like image 81
Daniel Lutton Avatar answered Sep 04 '25 22:09

Daniel Lutton