mdog has asked for the wisdom of the Perl Monks concerning the following question:
I know how to get text to speech work thanks to Rudif in this thread.
But how do you specify what engine you want to use? I have the AT&T NaturalVoices engine but when I use the code snippet below, it uses the MS TTS. It does this even after I go into my Windows-->Control Panel-->Speech and specify the AT&T voice.
Any ideas?
Thanks,
mdog
use strict; use warnings; use Win32::OLE; # Set up speech. my $voice = Win32::OLE->new("Speech.VoiceText") or die("TTS failed"); $voice->Register("", "$0"); $voice->{Enabled} = 1; # optional my $question = <<__EOS__; Would you like to play a game? How about global thermonuclear war? __EOS__ my $answer = <<__EOS__; __EOS__ $voice->Speak($question, 1); $voice->Speak($answer, 1); while ($voice->IsSpeaking()) { sleep 1; }
Edit by tye, remove domain from internal links
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Text To Speech: Specifying Your Engine
by PodMaster (Abbot) on May 07, 2003 at 11:41 UTC | |
|
Re: Text To Speech: Specifying Your Engine
by Jouke (Curate) on May 07, 2003 at 18:11 UTC |