By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
440,550 Members | 1,161 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 440,550 IT Pros & Developers. It's quick & easy.

Text-to-speech

P: n/a
Does anyone know of a cross-platform (OSX and Windows at least) library
for text-to-speech? I know there's an OSX API, and probably also for
Windows. I know PyTTS exists, but it seems to talk only to the Windows
engine. I'd like to write a single Python module to handle this on both
platforms, but I guess I'm asking too much -- it's too hardware
dependent, I suppose. Any hints?

Charles Hartman
Professor of English, Poet in Residence
http://cherry.conncoll.edu/cohar
http://villex.blogspot.com

Jul 18 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
Charles Hartman wrote:
Does anyone know of a cross-platform (OSX and Windows at least) library
for text-to-speech? I know there's an OSX API, and probably also for
Windows. I know PyTTS exists, but it seems to talk only to the Windows
engine. I'd like to write a single Python module to handle this on both
platforms, but I guess I'm asking too much -- it's too hardware
dependent, I suppose. Any hints?


Googling around a bit, I get

http://www.freebsoft.org/speechd
http://www.festvox.org/festival/
http://www.speech.cs.cmu.edu/flite/

Some of them might be useful as a start.

--
Robert Kern
rk***@ucsd.edu

"In the fields of hell where the grass grows high
Are the graves of dreams allowed to die."
-- Richard Harter
Jul 18 '05 #2

P: n/a
On some flavors of Windows you can use:
import pyTTS

tts = pyTTS.Create()
tts.Speak('This is the sound of my voice.')

On Mac OS X you can use:
import os

os.system("say 'This is the sound of my voice.'")

You could write a wrapper that takes a string and checks to see which
OS you are on and executes the appropriate of the two above choices.
But you probably need something slicker, and I don't know what that
might be.

Jul 18 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.