Open KonerDev opened 1 year ago
speed will be a nice feature, Is there a way to give pause in the sentence?
still needs the feature.
Google Translate only has two arbitrary speech speed options ("normal" and "slow"), to modify the speed, gTTS would need to tap into some sound libraries, which it currently leaves to the developer.
I don't think I'd want to add it in (unless I add some extra optional dependancies, perhaps), but I could eventually provide examples of how achieve it, TBD. Will put this documentation.
I have implement it by ffmpeg:
output_audio_file = "output_audio.mp3"
ffmpeg_command = ["ffmpeg", "-y", "-i", temp_audio_file, "-filter:a", "atempo=1.3", output_audio_file]
subprocess.run(ffmpeg_command, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
Prerequisites
pip install --upgrade gTTS
)Proposed Behaviour
I suggest adding a feature that allows users to modify the speed of the tts output.
Context
There is currently no way to make the speed particularly fast. Can you please add that?