Text to speech service delay


  1. cmasmas

    cmasmas Member

    Hi everyone,

    I'm making use of TTS on a application. The point is that it takes a few seconds to start up TTS service, and the voice comes with a delay. Is there a way to avoid this delay, or to make the Activity wait until TTS is ready?
    Thanks for the info!

    Advertisement
    :
  2. gpsTrainer

    gpsTrainer New Member

    Have you found anything on this? I am having the same problems
  3. cmasmas

    cmasmas Member

    Hi!!

    I found a way so the application waits until tts finishes to "speak".
    Here is the code:

    public void speak(String s)
    {
    mTts.speak(s, TextToSpeech.QUEUE_ADD, null);
    while (mTts.isSpeaking())
    {}
    }

    Hope it helps.
Loading...

Share This Page