Pages

2010-03-25

Make festival work with Pulseaudio

Debian Squeeze runs PulseAudio which provides a /dev/dsp however festival can't open it:



echo "test" | festival --ttsLinux: can't open /dev/dsp

Using emulation causes a segementation fault:

echo "test" | padsp festival --tts
Segmentation fault


The way to do it right is to create /etc/festival.scm with the following contents:

;;;; Use pulseaudio to output sound
(Parameter.set 'Audio_Command "paplay -n festival $FILE")
(Parameter.set 'Audio_Method 'Audio_Command)
(Parameter.set 'Audio_Required_Format 'snd)


Then use festival as usual:



echo "test" | festival --tts

That's it!

No comments:

Post a Comment