Try to speed up audio for tts
This commit is contained in:
@@ -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'
|
file_name = 'temp/' + ''.join(random.choice(string.ascii_lowercase) for i in range(12)) + '.mp3'
|
||||||
tts.save(file_name)
|
tts.save(file_name)
|
||||||
source = discord.PCMVolumeTransformer(
|
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():
|
def destroy():
|
||||||
|
|||||||
Reference in New Issue
Block a user