diff options
Diffstat (limited to 'tools/genvoice.sh')
-rwxr-xr-x | tools/genvoice.sh | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/tools/genvoice.sh b/tools/genvoice.sh index f32ab9476a..15028e3bd1 100755 --- a/tools/genvoice.sh +++ b/tools/genvoice.sh | |||
@@ -34,13 +34,17 @@ TTS_ENGINE=festival | |||
34 | ENCODER=lame | 34 | ENCODER=lame |
35 | # Where to save temporary files | 35 | # Where to save temporary files |
36 | TEMPDIR=/tmp | 36 | TEMPDIR=/tmp |
37 | # List of IDs to send to voicefont | ||
38 | VOICEFONTIDS=voicefontids | ||
37 | 39 | ||
38 | ################### | 40 | ################### |
39 | # End of settings # | 41 | # End of settings # |
40 | ################### | 42 | ################### |
41 | 43 | ||
44 | TARGET_ID="$4" | ||
42 | createvoicefile() { | 45 | createvoicefile() { |
43 | $VOICEFONT "$LANG_FILE" "$TEMPDIR/" "./$RLANG.voice" | 46 | $GENLANG -e=$ENGLISH -o -t=$TARGET $LANG_FILE > $VOICEFONTIDS |
47 | $VOICEFONT "$VOICEFONTIDS" "$TARGET_ID" "$TEMPDIR/" "./$RLANG.voice" | ||
44 | } | 48 | } |
45 | 49 | ||
46 | deletefiles() { | 50 | deletefiles() { |
@@ -106,7 +110,7 @@ generateclips() { | |||
106 | } | 110 | } |
107 | 111 | ||
108 | if [ -z "$3" ]; then | 112 | if [ -z "$3" ]; then |
109 | echo "Usage: $0 rockboxdirectory language target [settingsfile]"; | 113 | echo "Usage: $0 rockboxdirectory language target targetid [settingsfile]"; |
110 | exit 32 | 114 | exit 32 |
111 | else | 115 | else |
112 | if [ ! -d "$1" ] || [ ! -f "$1/tools/genlang" ]; then | 116 | if [ ! -d "$1" ] || [ ! -f "$1/tools/genlang" ]; then |
@@ -117,12 +121,12 @@ else | |||
117 | echo "Error: $2 is not a valid language" | 121 | echo "Error: $2 is not a valid language" |
118 | exit 34 | 122 | exit 34 |
119 | fi | 123 | fi |
120 | if [ ! -z "$4" ]; then | 124 | if [ ! -z "$5" ]; then |
121 | if [ -f "$4" ]; then | 125 | if [ -f "$5" ]; then |
122 | # Read settings from file | 126 | # Read settings from file |
123 | source "$4" | 127 | source "$5" |
124 | else | 128 | else |
125 | echo "Error: $4 does not exist" | 129 | echo "Error: $5 does not exist" |
126 | exit 36 | 130 | exit 36 |
127 | fi | 131 | fi |
128 | fi | 132 | fi |