2012-09-29

Devol Speaks!

I have made a new node for the filtergraph. This time it is a wrapper for the excellent open source eSpeak text to speech synthesis system, that basically allows my robot software to utter words and sentences in english. My test code for the new node looks like this:
void test_speech_synthesis() {
 cout << "allocin --------------------- \n";
 AudioSpeechSynth tts;
 AudioFileSink afs_mono("mono_tts.raw");
 cout << "buildin --------------------- \n";
 afs_mono.subscribeTo(tts);
 cout << "openin --------------------- \n";
 cout << "pumpin --------------------- \n";
 string s("hello devold");
 tts.speak(s);
 cout << "done pumpin, breaking --------------------- \n";
 afs_mono.unsubscribeFrom(tts);
 cout << "done breaking, closin --------------------- \n";
 cout << "done closin, COMPLETE!\n";
} 
  
I have yet to design a proper voice that matches the robot personality. More on that later.