From cdeb9016a8788c8db1e73c547fc5b76d22c3f7a3 Mon Sep 17 00:00:00 2001 From: Siphalor Date: Thu, 7 Oct 2021 13:15:46 +0200 Subject: [PATCH] Try to speed up audio for tts --- lib/utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/utils.py b/lib/utils.py index 66c68e2..5f22a41 100644 --- a/lib/utils.py +++ b/lib/utils.py @@ -42,7 +42,7 @@ def text_to_speech(text: str, lang: str = "de") -> (discord.AudioSource, Callabl file_name = 'temp/' + ''.join(random.choice(string.ascii_lowercase) for i in range(12)) + '.mp3' tts.save(file_name) source = discord.PCMVolumeTransformer( - discord.FFmpegPCMAudio(source=file_name, before_options='-v quiet') + discord.FFmpegPCMAudio(source=file_name, before_options='-v quiet -filter:a "atempo=1.5"') ) def destroy():