eSpeak / Gespeaker: How to Convert Text to Speech

speaker

All the people who have some type of visual problem also have the right to use GNU / Linux distributions. You may be thinking of using some kind of software that converts text to speech, and in that way to be able to read all kinds of texts without problem. Another possibility would be for those who want to convert text to speech for some reason, such as converting a book into an audiobook and recording it in MP3, to convert text in other languages ​​into audio to practice pronunciation with this speech synthesizer, etc.

Whatever your purpose, in this tutorial we will teach you everything you need to know about this open source app that is available with voice libraries in English and other languages, also in Spanish. You have two options, on the one hand you have the eSpeak tool and on the other hand you also have the Gespeaker tool at your disposal. Both have the same functionality, in fact they are related.

Distros designed to improve accessibility

ADRIAN

Source: ADRIANE

All the accessibility tools In macOS and Windows they are quite good, in GNU / Linux there are still things to polish so that those who have some kind of disability, or problem of any kind that allows the normal use of computer systems, can enjoy them. However, the community has gone to great lengths to bring distros to everyone. Proof of this is the SONAR distro, although it has unfortunately been discontinued.

And SONAR is not the only one distro designed to improve accessibilityIn fact, most current distros usually include some accessibility settings to change the contrast, enlarge the fonts, magnifying glass, on-screen keyboard, etc.

Vinux was also another distro for them, or the ADRIANE project (based on Kanoppix) intended for the visually impaired, or Talking Arch Linux, etc. Also, as my intention with this article is to help the more people the better, here is another list of projects that may interest you, apart from those that we will detail later:

As you can see, most are for people who are blind or have other vision problems, since they are the ones that present the most difficulties when using a computer system. For example, people with hearing problems can use a system normally, except that they cannot hear. Those who have some kind of mobility problem can also use any distro, they simply must have special keyboards, on-screen keyboards, change the mouse or touchpad settings, etc.

eSpeak vs Gespeaker

espeake command

So much eSpeak and Gespeaker They are related, the latter is a front-ent for the former, although the former can be used completely independently as speech synthesizers to convert text into speech. The difference between one and the other is:

  • eSpeak: is a text-based speech synthesis tool, that is, for the command line. Basically what it does is take an input in the form of a text string that you enter as a parameter after the (stdin) command, or a text file as input and reproduce it with a synthetic voice produced by the computer. Specifically, you will find up to 107 different languages ​​and accents to choose from. So it has many possibilities ...
  • speaker: the most graphical and intuitive alternative with GUI for those who do not like to work so much from the console. Use a GTK + interface over espeak for this. It is also free and open source. But it allows you to adjust the parameters in a simpler way, such as the voice settings, languages, volume, tone, speed, etc. In addition, it allows you to record a WAV file to listen to it later or to transform it into another format such as MP3 and then use it on a portable player, etc.

That is, eSpeak is a more rudimentary but functional tool, while Gespeaker is the similar graphical version, or as alternative, to TextAloud for Windows....

Install and use espeak

To use espeak the first thing you should do is install this tool in your system if you don't already have it. To do this, it may vary depending on the distro you use, but it will be more or less as simple using the following commands:

  • Debian / Ubuntu / Derivatives:
sudo apt-get install espeak -y

  • openSUSE/SUSE:
sudo zypper install espeak-ng

  • RHEL/CentOS/Fedora:
sudo yum install espeak -y

  • ArchLinux:
sudo pacman -S espeak

Once installed, you can start using it. To get information, you can use one of the following commands. The first to see the version, and the second to know more about the use:

espeak --version
espeak --help
man espeak

To use it you can do it in two ways, one is to enter the text or the text file directly as a command parameter and the other is in interactive mode, that is, the second option that will let you type the text you want and then read it:

espeak "Hola, esto es un mensaje"
espeak -f /home/isaac/leer.txt
espeak

As simple as that...

Install and use Gespeaker

speaker

For install the graphical version, which you may like a lot more and is more practical and intuitive, you can use this procedure for the main distros:

Important: for Gespeaker to work you must have the python-dbus package installed, so you must also install it if you don't have it ...

  • Graphics mode: Go to your distro's app store. For example, if you are on Ubuntu, you can go to the Ubuntu Software app, then, in the search engine type the name gespeaker to search for it. Among the results you will find this app. You just have to press the Install button and you will have it ready to use ...
  • Text mode: for text mode, you can use the same commands in the espeak section, but substituting the package name for gespeaker to try to install it.

Once installed, its use is quite simple, you have all the configuration options available in the graphical interface:. Launch the app to start it from the apps menu of your desktop environment and once you see the main program window, you can paste or write text in the blank space to read or save it in audio format. In the following image I explain the main options:

Gespeaker menu

This way everything is better and faster than using commands, although you still have espeak after this beautiful infertility...

I hope I've helped. In case you have any recommendations or suggestions, and also doubts, you already know that you can leave comments.


Leave a Comment

Your email address will not be published. Required fields are marked with *

*

*

  1. Responsible for the data: AB Internet Networks 2008 SL
  2. Purpose of the data: Control SPAM, comment management.
  3. Legitimation: Your consent
  4. Communication of the data: The data will not be communicated to third parties except by legal obligation.
  5. Data storage: Database hosted by Occentus Networks (EU)
  6. Rights: At any time you can limit, recover and delete your information.

  1.   vipamon said

    how to fill in the command su [options] [-] [ […]]