termux / termux-api-package

Termux package containing scripts to call functionality in Termux:API.
MIT License
994 stars 314 forks source link

How to use TTS in termux without delay #148

Open aniket16122004 opened 2 years ago

aniket16122004 commented 2 years ago

I want to create a python speak() function by termux-tts-speech but there is a delay because the engine is restarting every time I call the function.

def speak(text): subprocess call(["termux-tts-speak",f"{text}])

Problem description

Whenever I call the function there also comes a delay caused by the TTS engine to start . Is there any way to fix it ?

aniket16122004 commented 2 years ago

H