2 summary:: lets you use the Apple speech synthesizer
8 "hi i'm talking with the default voice now, i guess".speak;
11 Speech consists of an link::Classes/Array:: of SpeechChannels. By default Speech is initialized with only one channel, but can be set up to use up to 16 by providing an argument to init. Channels may be used through a link::Classes/SpeechChannel:: or by setting the channel in Speech's methods (see examples below).
13 Speech is a function of the operating system and not the server. By consequence, strong::it is not possible to use UGens to filter or record the output directly::. You may be able to patch system output to system input (either by hardware of by software) to rout it to the server.
16 Currently only supported on OS X. In SwingOSC there is the equivalent JSpeech.
27 Speech.channels[0].speak("hallo");
28 Speech.channels[0].isActive;
29 Speech.channels[0].voice_(3);
30 Speech.channels[0].speak("hallo");
31 Speech.channels[0].pitch_(60);
32 Speech.channels[0].speak("hallo");
33 Speech.channels[0].volume_(-20.dbamp);
34 Speech.channels[0].pitchMod_(50);
35 Speech.channels[0].speak("hallo");
36 Speech.channels[0].stop(\immediate);
37 Speech.channels[0].stop(\endOfWord);
38 Speech.channels[0].stop(\endOfSentence);
41 Force the voice to speaking something different by setting the second argument of speak to true.
43 Speech.channels[0].speak("Force the voice to speaking something different.");
44 Speech.channels[0].speak("Force the voice to speaking something different.".reverse, true);
47 First argument is always the voice channel number, second the value.
49 Speech.setSpeechVoice(0,14);
50 Speech.setSpeechPitch(0, 40); //pitch in MIDI Num
51 Speech.setSpeechRate(0, 10);
52 Speech.setSpeechVolume(0,0.1);
53 Speech.setSpeechPitchMod(0, 200);
57 Two actions can be applied:
59 Speech.wordAction = {arg voiceNum;
61 // the currently speaking text may not be changed
62 //Speech.setSpeechPitch(voiceNum,[41,60].choose);
63 //Speech.setSpeechRate(voiceNum,[60,80, 10].choose);
65 Speech.doneAction_({arg voiceNum;
66 Speech.setSpeechPitch(voiceNum,[41,48,40,43,30,60].choose);
70 Pause the speech while speaking: 1=pause, 0= start
75 Initialization happens automatically, by default with one voice channel.
76 You may explicitly initalize with more channels, up to 16:
83 [0.1, 0.18, 0.2].choose.wait;
84 Speech.setSpeechRate(i,[90, 30, 60].choose);
85 Speech.setSpeechVolume(i,0.07);
86 "no this is private. float . boolean me. char[8] ".speak(i);
91 //jan@sampleAndHold.org 04/2003