brailcom/speechd

Support speaking out the contents of a file (like `espeak -f`)

Closed this issue · 2 comments

Is your feature request related to a problem? Please describe.
I would like to call spd-say from a script, to read out a file.

Describe the solution you'd like

I want spd-say -f text_file.txt to work like espeak-ng -f test_file.txt

Describe alternatives you've considered

Some complicated pipeline of spd-say --pipe-mode might work, like on old OSS, cat text_file.txt | spd-say -e > /dev/dsp, but pulseaudio has no /dev/dsp, and I am not sure this way won't fail somewhere unexpectedly.

Mmm, does spd-say --pipe-mode < text_file.txt > /dev/null not work like you want? what spd-say produces on stdout in that case is not the audio, but the text itself, and it produces the audio on the audio card too.

Not the audio? The man page clearly says

Pipe from stdin to stdout plus Speech Dispatcher

stdin + speech dispatcher = audio

Maybe just clarify that line a little bit?