Spoken Numbers
How to create a new Audio-Plug-in for the "Spoken Numbers" category?
A sound-Plug-in for the category "Spoken Numbers" is based on syllables in
order to get a human flavor for the audio output. In order to create a new
plug-in for a language, you have to record all number related syllables and
save them as .wav or .au. For example, for the German language you need 93
syllables ("ein", "eins", "eine", "minus", "null", etc.). Save the sound
files to a directory called data/sounds/<lang>. <lang> will be
explained later.
If you store a file called info in that directory, the file will be read.
The info file has to be a text file that contains key/value pairs. Supported
are the keys called format and voice. The supported values for format are
.au or .wav. If format is missing, .wav is expected. Supported values for
voice are male and female. If voice is missing, female is expected. Pack
everything together in one single .jar file, the jar program that is part of
each JDK is the preferred tool to do that. Basically a .jar file is a
.zip-file with UTF-8 encoding for the filenames. So please be warned, most
zip-programs don't work with UTF-8 by default. The return value of the
method called getSoundDir() has to be used for <lang>. Read the
sourcecode in net.numericalchameleon.SpokenNumbers for more information.
Name the .jar-file ncsound-<lang>.jar and copy it to the lib-folder.
Note:
The NumericalChameleon
2.0.0 supports the uncompressed .wav and .au format.
The mp3-format would be a choice from a quality point of view, however it
cannot be selected since mp3 is protected by patents until 2018. See also
http://en.wikipedia.org/wiki/Mp3#Licensing_and_patent_issues
Ogg Vorbis would be an alternative choice, however IMHO the available free
Java implementations of Ogg Forbis are not good enough. Therefore for now
only .wav and .au are supported.