From d39f19570baa86026b6612fe19508276f1ad4be7 Mon Sep 17 00:00:00 2001 From: jonsd Date: Fri, 19 Jun 2009 11:32:58 +0000 Subject: [PATCH] [1.40.22] Fix numbers greater than 1000000, for Indian languages. git-svn-id: https://espeak.svn.sourceforge.net/svnroot/espeak/trunk@221 d46cf337-b52f-0410-862d-fd96e6ae7743 --- dictsource/dict_phonemes | 2 +- dictsource/en_list | 2 -- dictsource/en_rules | 4 ++-- dictsource/fr_list | 20 ++++++++++++-------- dictsource/fr_rules | 14 +++++++------- dictsource/hi_list | 5 +++-- dictsource/is_list | 2 +- dictsource/is_rules | 19 ++++++++++--------- phsource/compile_report | 6 +++--- phsource/ph_french | 24 ++++++++++++------------ phsource/vwl_fr/r_a | Bin 1369 -> 1023 bytes src/synthdata.cpp | 2 +- src/translate.cpp | 4 ++-- 13 files changed, 54 insertions(+), 50 deletions(-) diff --git a/dictsource/dict_phonemes b/dictsource/dict_phonemes index 1245f8fc..2526932e 100644 --- a/dictsource/dict_phonemes +++ b/dictsource/dict_phonemes @@ -249,7 +249,7 @@ y y# Yy D f g h j J k l l# m m# n N n# N# n^ n^# p Q r R r# R2 s -S s2 t T tl# v x z +s2 t T tl# v x z Dictionary it_dict diff --git a/dictsource/en_list b/dictsource/en_list index 8f3383f5..bc923d78 100644 --- a/dictsource/en_list +++ b/dictsource/en_list @@ -1044,7 +1044,6 @@ everything EvrI2TIN evildoers i:v@Ldu:3z ewe ju: evening i:vnI2N -every Iv3:t evit EvI2t // inevitable exalt Egz'0lt execute EksI2kju:t // not $2 @@ -2434,7 +2433,6 @@ Peking pi:k'IN Peru p@ru: Phillipine fIlI2pi:n Philipine fIlI2pi:n // misspell -Poland poUl@nd Polish poUlIS $capital $only Portuguese po@tju:g'i:z Potomac $2 diff --git a/dictsource/en_rules b/dictsource/en_rules index 1c73ad87..8b9d3ad8 100644 --- a/dictsource/en_rules +++ b/dictsource/en_rules @@ -704,6 +704,7 @@ adv) an (c an _) an (cie eIn &l) an (d @n + yl) an (d an usb) an (d @n @) an (Ca_ 'an ando (_ 'andoU @@ -3239,8 +3240,6 @@ w) l (_ l r) l (_ l Al) l (_ - &) la (nd_ la2 - over) la (nd la &) lim (ent lIm &t) ling (_ _lI2N &B) ling (_ lI2N @@ -3652,6 +3651,7 @@ .group ol &st) ol (_ @L + ol (and_ oUl ol (ar oUl @@) ol (ar 'oUl h) ol (ar 0l diff --git a/dictsource/fr_list b/dictsource/fr_list index c70f0b7a..0bfa9379 100755 --- a/dictsource/fr_list +++ b/dictsource/fr_list @@ -24,7 +24,7 @@ // 2006-11-18 Gilles Casse // -// Updated 2009-05-14 Michel Such +// Updated 2009-06-08 Michel Such // // * Numbers, a few abbreviations and exceptions. // @@ -266,6 +266,8 @@ kde $abbrev kg kilogram khz kiloErts km kilomètre $text +(km player) ka,EmplEj'Wr +(kmplayer) ka,EmplEj'Wr kw kilowat m. m@siY mbit megabit @@ -334,14 +336,14 @@ mais $u+ ou $u $brk eh $u $brk et e $u $brk -ni $u $brk -car $u $brk +ni $u +car $u car $noun -cependant $brk -néanmoins $brk -toutefois $brk -avant $u+ $brk -après $u+ $brk +cependant +néanmoins $u+ +toutefois $u+ +avant $u+ +après $u+ (temps en temps) tA~zA~tA~ alors alOr $u+ depuis $u+ @@ -362,6 +364,8 @@ que $u+ (parce qu'elles) parskElz2 $u+ (parce qu'on) parskO~n2 $u+ tant tA~t2 $u+ +(tant mieux) tA~mjY $u+ +(tant pis) tA~pi $u+ qui $verbf $u+ quoique $u quant kA~t2 $u diff --git a/dictsource/fr_rules b/dictsource/fr_rules index b479af20..2be173a6 100755 --- a/dictsource/fr_rules +++ b/dictsource/fr_rules @@ -23,7 +23,7 @@ // 2006-11-18 Gilles Casse // -// Updated: 2009-05-14 Michel Such +// Updated: 2009-05-28 Michel Such // // Letter classes: @@ -605,11 +605,11 @@ iew) er (X er2 vin) gt (_neuvi t gt (_ // vingt doigts - gt t // vingtaine doigté + gui gi // anguille - ai) gu (il gy // aiguillage - in) gu (is gy // linguiste + ai) gui (l gw^i // aiguillage + in) gui (s gw^i // linguiste g (C g _ran) g (_ // rang @@ -1253,9 +1253,9 @@ A) t (- t2 C) ucci utSi // capuccino c) ueill Wj // cueillir c) ueil (_ Wj // recueil - _g) u (a u - ag) u (a_ u - tig) u (a_ u + _g) ua wA + ag) ua (_ wA + Ctig) ua (_ wA _c) ul (_ y _) ultra (P5 yltra g) u (ay u diff --git a/dictsource/hi_list b/dictsource/hi_list index 509236dd..17e05a48 100755 --- a/dictsource/hi_list +++ b/dictsource/hi_list @@ -14,7 +14,7 @@ _8 'a:t.h _9 n'O: ?3 _9 n'aU -_10 dVs +_10 d'Vs _11 gj'a:r@2 _12 b'a:r@2 _13 t'E:r@2 @@ -117,7 +117,8 @@ _0C s'O: _0M1 h@z'a:r _0M2 l'a:kh _0M3 cr'ore -_0M4 b'ilion // ?? English +_0M4 'Vr@b +_0M5 kh'Vr@b _dpt _d@s@ml'o:_ // ?? what is Hi for "." ? // Single consonants diff --git a/dictsource/is_list b/dictsource/is_list index cce79d82..0e0bcc91 100755 --- a/dictsource/is_list +++ b/dictsource/is_list @@ -20,7 +20,7 @@ _3f Tr#j'u: _4f fj'W:Qyrr# _5 f'Im _6 s'e:xs -_7 S'W: +_7 sj'W: _8 'aUhd& _9 n'i:;y _10 t'i:;y diff --git a/dictsource/is_rules b/dictsource/is_rules index 2566c354..5d9a1972 100644 --- a/dictsource/is_rules +++ b/dictsource/is_rules @@ -5,6 +5,9 @@ // letter group F p,t,k,s // letter group H j,r,v, +.replace + x xz + .group a a a: @@ -53,7 +56,7 @@ e (CC E e (ng eI e (nk eI - + egi eI:jI ei eI: ey eI: ei (FH eI: @@ -116,7 +119,6 @@ hj C hl l# hn hn# - hr r# hv kv @@ -184,6 +186,7 @@ ó) nn dn ú) nn dn ý) nn dn + æ) nn dn au) nn dn ei) nn dn ey) nn dn @@ -223,13 +226,13 @@ .group r - _) r R2 + _) r _|R2 C) r @-R l) r **R A) r (A *R B) r r# r (B rr# - r (_ rr# + r (_ _|R r _|R2 rr R*R rl dl @@ -240,7 +243,6 @@ .group s s s ss ss2 - sj S .group t @@ -259,7 +261,6 @@ u (CC y K) u (ng u K) u (nk u - &) ur (_ y#r# .group ú @@ -277,8 +278,8 @@ .group x - x xs - + x ks + xz ks .group y y I: @@ -319,6 +320,6 @@ _) ö (@P1N ,W: .group - $ dolar + $ dOllar diff --git a/phsource/compile_report b/phsource/compile_report index b01f3d89..bfbf4c1c 100644 --- a/phsource/compile_report +++ b/phsource/compile_report @@ -684,8 +684,6 @@ r/xr [(@)] base [(o)] base [(u)] base [Y] fr - [a] fr - [A~] fr ufric/ch [C] base [J^] base [C2] de @@ -2248,7 +2246,8 @@ vwl_fr/@R2 [R] fr_ca vwl_fr/@R3 [Q2] hy vwl_fr/@R4 [Q2] hy vwl_fr/@R5 [Q2] hy -vwl_fr/r_a [wA] fr +vwl_fr/r_a [a] fr + [wA] fr vwl_fr/r_e [E] fr [e] fr vwl_fr/r_i [i] fr @@ -2265,6 +2264,7 @@ vwl_fr/r_y [y] fr vwl_fr/tr [r] fr vwl_fr/w_a [wA] fr vwl_fr/xr [a] fr + [wA] fr [A~] fr vwl_hi/l-voc [l-] jbo [l-] hi diff --git a/phsource/ph_french b/phsource/ph_french index 866634ee..be938678 100644 --- a/phsource/ph_french +++ b/phsource/ph_french @@ -37,8 +37,8 @@ phoneme a formants vowel/a_6 after l l/la-15 before l/ DFT+l/l_a - before (r) DFT-10+vwl_fr/xr - before r/2 DFT+r/xr + before (r) DFT+vwl_fr/xr + before r/2 DFT-20+vwl_fr/r_a endphoneme @@ -71,7 +71,7 @@ phoneme i after (l) l/li-15 before l/ DFT+l/l_i before (r) DFT-20+vwl_fr/r_i - before r/2 DFT+vwl_fr/r_i + before r/2 DFT-20+vwl_fr/r_i endphoneme @@ -125,7 +125,7 @@ phoneme O formants vowel/o_mid after (l) l/lo-10 before l/ DFT+l/l_o - before r/2 DFT+vwl_fr/r_o + before r/2 DFT-20+vwl_fr/r_o reduceto o2 1 endphoneme @@ -137,7 +137,7 @@ phoneme O2 // Like O but no reduceto after (l) l/lo-10 before l/ DFT+l/l_o before (r) DFT+vwl_fr/r_o - before r/2 DFT+vwl_fr/r_o + before r/2 DFT-20+vwl_fr/r_o endphoneme @@ -148,7 +148,7 @@ phoneme u after l l/lu-20 before l/ DFT-20+l/l_u before (r) DFT+vwl_fr/r_u - before r/2 DFT+vwl_fr/r_u + before r/2 DFT-30+vwl_fr/r_u before i DFT-50 endphoneme @@ -171,7 +171,7 @@ phoneme y after l l/lu-20 before l/ DFT-30+l/l_y before (r) DFT+vwl_fr/r_y - before r/2 DFT+vwl_fr/r_y + before r/2 DFT-30+vwl_fr/r_y before E~ DFT-50 endphoneme @@ -194,7 +194,7 @@ phoneme W after (l) l/l@-20 before l/ DFT-20+l/l_@ before (r) DFT+vwl_fr/r_@2 - before r/2 DFT+vwl_fr/r_@2 + before r/2 DFT-30+vwl_fr/r_@2 reduceto Y 1 endphoneme @@ -216,7 +216,7 @@ phoneme wA formants vwl_fr/w_a after (l) l/lo-10 before l/ DFT-10+l/l_a - before (r) DFT+vwl_fr/r_a + before (r) DFT+vwl_fr/xr before r/2 DFT+vwl_fr/r_a endphoneme @@ -238,7 +238,7 @@ phoneme A~ formants vnasal/aa_n4 before l/ DFT+l/l_a before (r) DFT+vwl_fr/xr - before r/2 DFT+r/xr-40 + before r/2 DFT+vwl_fr/xr endphoneme @@ -429,7 +429,7 @@ endphoneme phoneme r liquid starttype (r) endtype (r) - vowelin f1=0 f2=1800 10 10 f3=-200 100 + vowelin f1=1 f2=1800 10 10 f3=-200 100 vowelout f1=1 f2=1800 10 10 f3=-200 100 length 100 lengthmod 7 @@ -444,7 +444,7 @@ phoneme r after p vwl_fr/tr+r3/rx%35 after s vwl_fr/tr+r3/rx%30 after S vwl_fr/tr+r3/rx%45 - after t vwl_fr/tr+r3/rx%15 + after t vwl_fr/tr+r3/rx%30 after v vwl_fr/tr+r3/rx%30 after z vwl_fr/tr+r3/rx%30 after Z vwl_fr/tr+r3/rx%30 diff --git a/phsource/vwl_fr/r_a b/phsource/vwl_fr/r_a index 938f44745a1eb157187df1a5fc6c67cb48ab1b44..f894f81320960581bcfa57647b6a2b1cb73a4efc 100755 GIT binary patch delta 264 zcmcb~^`BiJIKb68B-k~OnSp_!C_a&Sqd+cWnmgkG&N?P0kQl>rCI-QCj5$mo_8k@m z{s)XQV0Iqo0j>v(4;Vq>9J~!s_PhUU_#4<@;_NaE%rJI^90Q{T6GXj+vKNp&*_QcT zeK1h_yZ;4@46F|rb-;!hFflNGV8{ToJ6ISPVB#0p8Gza$2ITNCutV7I{$~gLxp delta 287 zcmey*ev?ZeIKb68B-k~OnSp_!C_a&8qd+d>L{BTGcmF50>P)t0J}`MHlTk(q0|VDQ zCNYpA23{rx;RvP&j3D+xRt5nXDEkEm1Lp%qi1;2J1`Y`O-Tx9k7@L71L7IUXrlvxU z0jLwAUPD<8%!XR1Qy&F1{M~;6pd}v6f56sy0LciZ2quuV0jvxRGE6dHwhAW$1I!o$ s9vB;_mk-8fU|1l7U<0j%tJhG5u*Db@flz`$35b;$3>X|I2QaS(0Et>XG5`Po diff --git a/src/synthdata.cpp b/src/synthdata.cpp index 629da885..2fdad1f9 100755 --- a/src/synthdata.cpp +++ b/src/synthdata.cpp @@ -35,7 +35,7 @@ #include "translate.h" #include "wave.h" -const char *version_string = "1.40.21 29.May.09"; +const char *version_string = "1.40.22 19.Jun.09"; const int version_phdata = 0x014015; int option_device_number = -1; diff --git a/src/translate.cpp b/src/translate.cpp index 2b7c1a1e..56cdd494 100755 --- a/src/translate.cpp +++ b/src/translate.cpp @@ -2563,7 +2563,7 @@ if((c == '/') && (tr->langopts.testing & 2) && IsDigit09(next_in) && IsAlpha(pre char *pn; char *pw; static unsigned int break_numbers1 = 0x49249248; - static unsigned int break_numbers2 = 0x492492a8; // for languages which have numbers for 100,000 and 100,00,000 + static unsigned int break_numbers2 = 0x24924aa8; // for languages which have numbers for 100,000 and 100,00,000, eg Hindi static unsigned int break_numbers3 = 0x49249268; // for languages which have numbers for 100,000 and 1,000,000 unsigned int break_numbers; char number_buf[80]; @@ -2620,7 +2620,7 @@ if((c == '/') && (tr->langopts.testing & 2) && IsDigit09(next_in) && IsAlpha(pre pn = &number_buf[1]; nx = n_digits; - if(tr->langopts.numbers2 & NUM2_100000a) + if((tr->langopts.numbers2 & NUM2_100000a) == NUM2_100000a) break_numbers = break_numbers3; else if(tr->langopts.numbers2 & NUM2_100000)