Notice: This forum has been recovered from an old backup, so some content, links, and dates may be outdated. The forum is currently read-only while we restore sign-in and registration functionality. Details
If you find this forum valuable and would like to help keep it online, donations to help cover hosting and domain costs are greatly appreciated, but never expected. You can support the forum through Buy Me a Coffee or Ko-fi. Thank you for helping preserve the EventGhost community.
If you find this forum valuable and would like to help keep it online, donations to help cover hosting and domain costs are greatly appreciated, but never expected. You can support the forum through Buy Me a Coffee or Ko-fi. Thank you for helping preserve the EventGhost community.
Text-to-Speech / Wait until finished
Text-to-Speech / Wait until finished
Is there any way to get EG to wait until text is finished speaking when using the TTS action, before moving onto the next action?
- Pako
- Plugin Developer
- Posts: 2294
- Joined: Sat Nov 11, 2006 1:31 pm
- Location: Czech Republic
- Contact:
Re: Text-to-Speech / Wait until finished
I know of no simple ways to achieve this.jlutsky wrote:Is there any way to get EG to wait until text is finished speaking when using the TTS action, before moving onto the next action?
However, one workaround I have for you:
1) Use a plugin IntelliSpeech instead of Speech plugin
2) Divide your macro into two parts.
3) When speaking finishes, an event IntelliSpeech.SpeakingFinished is triggered
4) The second macro run using the above event
Pako
Re: Text-to-Speech / Wait until finished
Thanks! This plugin does exactly what I needed.Pako wrote:I know of no simple ways to achieve this.jlutsky wrote:Is there any way to get EG to wait until text is finished speaking when using the TTS action, before moving onto the next action?
However, one workaround I have for you:
1) Use a plugin IntelliSpeech instead of Speech plugin
2) Divide your macro into two parts.
3) When speaking finishes, an event IntelliSpeech.SpeakingFinished is triggered
4) The second macro run using the above event
Pako
Unfortunately, I prefer the custom voice dialects I already have installed that the basic text-to-speech plugin is able to use. But I was able to figure out an almost perfect work-around. If I have my first action be IntelliSpeech: Speak text with the volume at 1, followed immediately by the Speech: Speak action of the default plugin, both fire off some spoken text that take almost the same amount of time to finish, so I can still use the SpeakingFinished trigger to move on after that.
However, even at volume 1 I can still hear very faint speech from IntelliSpeech. Is it possible to set volume to 0, or mute the audio from IntelliSpeech entirely?
- Pako
- Plugin Developer
- Posts: 2294
- Joined: Sat Nov 11, 2006 1:31 pm
- Location: Czech Republic
- Contact:
Re: Text-to-Speech / Wait until finished
I think it is not a good idea. It will never be reliable.jlutsky wrote:But I was able to figure out an almost perfect work-around. If I have my first action be IntelliSpeech: Speak text with the volume at 1, followed immediately by the Speech: Speak action of the default plugin, both fire off some spoken text that take almost the same amount of time to finish, so I can still use the SpeakingFinished trigger to move on after that.
A better solution is when Speech plugin will have the same function.
You can try it out. Adjusted plugin can be downloaded from the SVN repository.
Pako
Re: Text-to-Speech / Wait until finished
Hello Pako,
I tried to implement an additional action to speak after interrupting any on-going speech in the 'Speech' plugin. This will help to handle priorities in notifications.
It would have been better to keep the same action and just add an 'Interrupt' parameter with a tick option but designing UI in Python is still a pain for me (even for a tick box).
I have looked a the code of the 'Speech' plugin and made few changes. They are commented with the '#ADDED: ' tag.
But because I am not familiar neither with Python nor with SAPI, my implentation might not be totally smart...
Is the thread closing correctly with my tts.Pause() action?
Why my new action 'TextToSpeechInterrupt' is not displying with the correct label in the Eg treeview of actions?
Your feedback is appreciated
I tried to implement an additional action to speak after interrupting any on-going speech in the 'Speech' plugin. This will help to handle priorities in notifications.
It would have been better to keep the same action and just add an 'Interrupt' parameter with a tick option but designing UI in Python is still a pain for me (even for a tick box).
I have looked a the code of the 'Speech' plugin and made few changes. They are commented with the '#ADDED: ' tag.
But because I am not familiar neither with Python nor with SAPI, my implentation might not be totally smart...
Is the thread closing correctly with my tts.Pause() action?
Why my new action 'TextToSpeechInterrupt' is not displying with the correct label in the Eg treeview of actions?
Your feedback is appreciated
- Attachments
-
- __init__.py
- (16.31 KiB) Downloaded 116 times