我觉得TTS (Text to Speech) 可以这么用:比如你一直在电脑前看文档,需要离开一下椅子,但是还希望接着"看",可以让TTS程序来帮你把文字读出来。这样不耽误事情,还可以继续学东西。
Linux试用了两个TTS程序:espeak和festival。
Espeak:
Package: espeak
Version: 1.41.01-0ubuntu1
Description: A multi-lingual software speech synthesizer
eSpeak is a software speech synthesizer for English, and some other
languages.
.
eSpeak produces good quality English speech. It uses a different synthesis
method from other open source text to speech (TTS) engines, and sounds quite
different. It's perhaps not as natural or "smooth", but some find the
articulation clearer and easier to listen to for long periods.
.
It can run as a command line program to speak text from a file or from stdin.
.
It works well as a "Talker" with the KDE text to speech system (KTTS), as an
alternative to Festival for example. As such, it can speak text which has been
selected into the clipboard, or directly from the Konqueror browser or the Kate
editor.
.
* Includes different Voices, whose characteristics can be altered.
* Can produce speech output as a WAV file.
* Can translate text to phoneme codes, so it could be adapted as a front end
for another speech synthesis engine.
* Potential for other languages. Rudimentary (and probably humourous)
attempts at German and Esperanto are included.
* Compact size. The program and its data total about 350 kbytes.
* Written in C++.
Homepage:
http://espeak.sourceforge.net/Festival:
Package: festival
Version: 1.96~beta-9ubuntu1
Description: General multi-lingual speech synthesis system
Festival offers a full text to speech system with various APIs, as well an
environment for development and research of speech synthesis techniques. It
includes a Scheme-based command interpreter.
.
Besides research into speech synthesis, festival is useful as a stand-alone
speech synthesis program. It is capable of producing clearly understandable
speech from text.
Homepage:
http://www.cstr.ed.ac.uk/projects/festival/Espeak默认从stdin读入文字,然后用英语读出。Espeak支持55种语言,试了试英语、法语,还有普通话,挺好玩的,停顿很自然。
Festival貌似用到了Lisp语言,默认进入交互模式,用
festival> (SayText "linux is great")
或者
festival> (tts "/home/tux/ss" nil)
用文本文件作为参数读出来。
Festival要安装festvox开头的包,才能有语音出来。