Synthesizing Voice From the Command Line
I don't do a lot of audio/video stuff with my system, but the other day I had the urge to see if there was some voice synthesis software available on Linux and it turned out that I already had it installed: it's called Festival. Turns out there are a number of voice synthesis and analysis packages available.
Festival is, according to the website:
Festival offers a general framework for building speech synthesis systems as well as including examples of various modules. As a whole it offers full text to speech through a number APIs: from shell level, though [sic] a Scheme command interpreter, as a C++ library, from Java, and an Emacs interface. Festival is multi-lingual (currently English (British and American), and Spanish) though English is the most advanced.
As far as simple commands, Festival comes with two: saytime and text2wave. Saytime does what you would expect, it speaks the time (as well as outputting the spoken text to stdout). Note though, the time that is output tends to be less than specific:
$ saytime The time is now, just after half past 10, in the morning.
A wave file of the output is attached (time.wav).
The second command that comes with Festival is text2wave which converts text read from stdin to a .wav file output:
$ echo Your job has completed | text2wave >job.wav $ aplay job.wav # OR $ echo Your job has completed | text2wave | aplay
The wave file is attached (job.wav).
Mitch Frazier is an Associate Editor for Linux Journal.
Today five randomly drawn entrants will win:
Rock, Paper, Scissors, Lizard, Spock mug and LJ subscription
Enter to Win
|December Daily Giveaways are Back!||Dec 01, 2015|
|December 2015 Video Preview||Nov 30, 2015|
|Take Control of Your PC with UEFI Secure Boot||Nov 30, 2015|
|Geek Hide-away in Guatemala - Stay for Free!||Nov 26, 2015|
|Microsoft and Linux: True Romance or Toxic Love?||Nov 25, 2015|
|Non-Linux FOSS: Install Windows? Yeah, Open Source Can Do That.||Nov 24, 2015|
- Take Control of Your PC with UEFI Secure Boot
- Cipher Security: How to harden TLS and SSH
- Non-Linux FOSS: Install Windows? Yeah, Open Source Can Do That.
- December Daily Giveaways are Back!
- Web Stores Held Hostage
- Firefox's New Feature for Tighter Security
- Microsoft and Linux: True Romance or Toxic Love?
- Geek Hide-away in Guatemala - Stay for Free!
- diff -u: What's New in Kernel Development
- PuppetLabs Introduces Application Orchestration