Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #
- # pip install gtts
- #
- from gtts import gTTS
- import os
- tts = gTTS(text='Good Day, what a nice day today.', lang='en')
- tts.save("voice.mp3")
- os.system("xplayer voice.mp3")
- tts = gTTS(text='Witaj. Ładna dzisiaj pogoda.', lang='pl')
- tts.save("voice.mp3")
- os.system("xplayer voice.mp3")
- tts = gTTS(text='Доброе утро, сегодня хороший день.', lang='ru')
- tts.save("voice.mp3")
- os.system("xplayer voice.mp3")
Add Comment
Please, Sign In to add comment