Browse Source

[1.39.48]

Fix lettergroups: Sort items to longest first.

Lang en-us: Use rhotic [3] in place of [@] when [r] follows.

Voice files: add attribute "fast-test" to experiment with faster talking speeds.


git-svn-id: https://espeak.svn.sourceforge.net/svnroot/espeak/trunk@212 d46cf337-b52f-0410-862d-fd96e6ae7743
master
jonsd 16 years ago
parent
commit
eabd70afbf
53 changed files with 444 additions and 331 deletions
  1. 2
    2
      dictsource/af_list
  2. 9
    5
      dictsource/cs_list
  3. 0
    9
      dictsource/cs_rules
  4. 19
    2
      dictsource/de_list
  5. 1
    20
      dictsource/de_rules
  6. 26
    23
      dictsource/dict_phonemes
  7. 6
    4
      dictsource/en_list
  8. 4
    3
      dictsource/en_rules
  9. 4
    4
      dictsource/eo_list
  10. 6
    4
      dictsource/fi_list
  11. 1
    3
      dictsource/fi_rules
  12. 4
    4
      dictsource/fr_list
  13. 10
    6
      dictsource/hbs_list
  14. 0
    15
      dictsource/hbs_rules
  15. 42
    3
      dictsource/hu_list
  16. 0
    16
      dictsource/hu_rules
  17. 0
    1
      dictsource/it_list
  18. 7
    7
      dictsource/pl_list
  19. 14
    5
      dictsource/pt_list
  20. 0
    22
      dictsource/pt_rules
  21. 10
    5
      dictsource/ro_list
  22. 2
    11
      dictsource/ro_rules
  23. 18
    8
      dictsource/sk_list
  24. 6
    4
      dictsource/tr_list
  25. 1
    1
      dictsource/tr_rules
  26. 52
    46
      phsource/compile_report
  27. 0
    12
      phsource/ph_english
  28. 12
    0
      phsource/ph_english_n
  29. 13
    9
      phsource/ph_english_us
  30. 12
    0
      phsource/ph_english_wm
  31. 15
    1
      phsource/ph_polish
  32. 7
    6
      phsource/phonemes
  33. BIN
      phsource/vdiph2/u@
  34. BIN
      phsource/vowel/0_3
  35. BIN
      phsource/vowel/@_low2
  36. BIN
      phsource/vowel/a
  37. BIN
      phsource/vowel/vowelchart.png
  38. BIN
      phsource/vwl_en_us/3_us2
  39. BIN
      phsource/vwl_en_us/ar
  40. 6
    2
      src/compiledata.cpp
  41. 33
    4
      src/compiledict.cpp
  42. 4
    1
      src/numbers.cpp
  43. 2
    0
      src/phoneme.h
  44. 7
    0
      src/phonemelist.cpp
  45. 1
    1
      src/readclause.cpp
  46. 21
    9
      src/setlengths.cpp
  47. 3
    3
      src/synth_mbrola.cpp
  48. 1
    1
      src/synthdata.cpp
  49. 6
    8
      src/synthesize.cpp
  50. 9
    3
      src/synthesize.h
  51. 3
    3
      src/tr_languages.cpp
  52. 4
    3
      src/translate.h
  53. 41
    32
      src/voices.cpp

+ 2
- 2
dictsource/af_list View File

@@ -1,4 +1,4 @@
//maintainer: Willem van der Walt
//maintainer: Willem van der Walt
// email: [email protected]
// tel: +27 12 8413996
// Meraka Institute, CSIR
@@ -313,6 +313,7 @@ david _^_EN
(da vinci) da||v'intSi
debora d@bo@ra
debussy d@bus'i:
de d@
(de la) d@||la $u // de la Rey/de la Bat, etc.
der d@r
derick dErik
@@ -608,7 +609,6 @@ voor $u $strend2


// misc unstressed
de d@
dat $u $strend
te t@ $verbf
nie $unstressend $verbextend

+ 9
- 5
dictsource/cs_list View File

@@ -84,8 +84,6 @@ _" uvozovki
_, tSa:Rka
_- mi:nus
_; zdR^edn^i:k
_= Rovno
_* hvjezJitSka
_? otazn^i:k
__ pottr-Zen^i:
_` 'obRa:ts,ena:||tS'a:Rka
@@ -99,14 +97,20 @@ _< menSi:
_> vjetSi:
_| sv'isla:||tS'a:Ra
_: dv'ojtetSka
% pRotsento
+ plus

. tetSka $max3
* hvjezJitSka $max3
= Rovno $max3
* hvjezJitSka $max3
% pRotsento $max3
+ plus $max3
! vigR^itSn^i:k $max3
€ eURo
@ zavina:tS
& ampr-sent
# gR^i:Zek
/ lomeno
_\ beksleS
\ beksleS

° stupen^
× kRa:t

+ 0
- 9
dictsource/cs_rules View File

@@ -631,18 +631,9 @@ _flegma) ti ti
ü i

$ dola:R
! vigR^itSn^i:k

. tetSka
. (. _:
\.) .

__) - (_D mi:nus
A_) - (_D _
C_) - (_D _
--) -

* hvj'ezJitSka
*) * (*
**
**) * (_ _::

+ 19
- 2
dictsource/de_list View File

@@ -15,9 +15,19 @@
// spoken when "speak punctuation" option is on.

_. pUnkt
_, kOma

* StE*n $max3
% p@-*o:ts'Ent $max3
+ plUs $max3
= glaIC $max3
# nUm3 $max3
€ OY*o:
£ paUnd
& Unt
@ kl'ame:*,af@
~ tIld@
\ bEkslES

_, kOma
_| paIp
_: d'Op@lp,UNkt
_; St@-*'ICpUNkt
@@ -64,6 +74,13 @@ _rng k@-*'u:Ze:k
_stk S@-*'Egst@-*IC
_tld t'Ild@

æ $accent
é $accent
ç $accent
č $accent
š $accent
ž $accent

// Not Roman numbers
v faU
x Iks

+ 1
- 20
dictsource/de_rules View File

@@ -1150,24 +1150,5 @@

, (D kOma
$ dOl'A:
€ OY*o:
£ paUnd
% p@-*o:ts'Ent
& Unt
@ kl'ame:*,af@
# nUm3
+ plUs
= glaIC
~ tIld@
\ bEkslES


. pUnkt
. (. _:
\.) .

* StE*n
*) * (*
**
**) * (_ _::



+ 26
- 23
dictsource/dict_phonemes View File

@@ -20,6 +20,7 @@ Dictionary bn_dict
& a a: a~ e E e~ i
I i: i:~ i~ l- o O o:
O~ o~ r- U u u: u:~ u~
V

* b B bh c C ch d
d. d.h dh g gh h j J
@@ -46,10 +47,11 @@ Dictionary cs_dict
i i: l- o o: oU r- u
u:

* ; b c d dZ f g
h j J k l l^ m n
N n^ p r R R^ R^/ s
S t tS ts v x z Z
* ; b c d dZ dz f
g h j J k l l^ m
n N n^ p r R R^ R^/
s S t tS ts v x z
Z


Dictionary cy_dict
@@ -180,10 +182,10 @@ Dictionary hbs_dict
E e e: i I i: l- O
o o: oU r* r- u U u:

* ; b d dZ dZ; f g
h j k l l^ m n N
n^ p r R R2 s S t
tS ts tS; v x z Z
* ; b d dZ dz dZ; f
g h j k l l^ m n
N n^ p r R R2 s S
t tS ts tS; v x z Z


Dictionary hi_dict
@@ -323,9 +325,9 @@ i: ie iu o o: u u: ui
uo

: b c d dZ f g h
j J k l l^ m n n^
p r R R2 s S t tS
ts v x z Z
j J k l l^ m n N
n^ p r R R2 s S t
tS ts v z Z


Dictionary mk_dict
@@ -334,10 +336,10 @@ Dictionary mk_dict
e e: i I i: l- o o:
oU r- u u:

* b d dZ dZ; f g h
j k k^ l l^ m n N
n^ p r R s S t tS
ts tS; v x z Z
* b d dZ dz dZ; f g
h j k k^ l l^ m n
N n^ p r R s S t
tS ts tS; v x z Z


Dictionary ml_dict
@@ -411,10 +413,10 @@ a E E# E~ i O O~ u
y

: ; b c C d d; dZ
dz; f g h j k l m
n N n^ p r R s S
s; S; t t; tS ts ts; tS;
v w x z Z Z;
dz dz; f g h j k l
m n N n^ p r R s
S s; S; t t; tS ts ts;
tS; v w x z Z Z;


Dictionary pt_dict
@@ -476,10 +478,11 @@ Dictionary sk_dict
l- l: o o: oU r- r: u
u:

* ; b d d; dZ f g
h j k l l^ m n N
n^ p r R R^ R^/ s S
t t; tS ts v x z Z
* ; b d d; dZ dz f
g h j k l l^ m n
N n^ p r R R^ R^/ s
S t t; tS ts v x z
Z


Dictionary sq_dict

+ 6
- 4
dictsource/en_list View File

@@ -178,6 +178,8 @@ _‴ trIp@LpraIm
_‼ Ekskla2m'eIS@nz
_₠ jU@roU

@ _at_
& _and
\ bakstroUk $max3
/ stroUk $max3
?3 \ bakslaS $max3
@@ -2279,7 +2281,7 @@ Berlin b3:l'In
Bhutan bu:t'an
Bogota b0g@t'A:
?3 Boston bOst@n
Bucharest bu:k@r'Est
Bucharest bu:ka2r'Est
Budapest bu:d@p'Est
Buenos bweIn0s
Burundi bUr'UndI
@@ -2308,7 +2310,7 @@ Djibouti dZIb'u:tI
Egyptian IdZ'IpS@n
Eire e@r@
Geneva dZ@ni:v@
Harare h@rA:rI
Harare ha2rA:rI
Hanoi han'OI
Hawaii h@w'aIi:
Hawai'i h@w'aIi:
@@ -2327,7 +2329,7 @@ Jakarta $2
Jerusalem dZ@ru:s@l@m
Johannesburg $2
Kalgoorlie kalgU@lI
Karachi k@rA@tSI
Karachi ka2rA@tSI
Kentucky $2
Kiev ki:Ev
Khmer kmi@3
@@ -2413,7 +2415,7 @@ Taipei t,aIp'eI
Taiwan taI'wan
(tel aviv) t,El||a2v'i:v
Tibet tI2b'Et
Totonto t@r0ntoU
Toronto t@r0ntoU
Timor ti:mo@
Tokyo toUkIoU
Toulouse tu:l'u:z

+ 4
- 3
dictsource/en_rules View File

@@ -730,6 +730,7 @@
r) anged (S1 d
perm) an @n
ang (er aNg
h) ang (er aN
m) anoeu (v @nu:
_qu) an 0n
_w) an 0n
@@ -3404,7 +3405,9 @@
cla) ng (er Ng
ta) ngi ndZI
i) ng (er Ng
bi) ng (er ndZ
ri) ng (er N
si) ng (er N
bi) ng (er ndZ
gi) ng (er ndZ
o) ng (er Ng
you) ng (er Ng
@@ -5338,8 +5341,6 @@
: koUl@n
D_) : (_DD_ // omit colon in time, eg: 2:30
$ d0l3
@ at_:
& _!%and
!= n0ti:kw@Lz
>= greIt@O@i:kw@L
<= lEsO@i:kw@L

+ 4
- 4
dictsource/eo_list View File

@@ -61,14 +61,14 @@ _- dividost@-*eko
__ subst@-*eko
~ tildo
° gradoI
% p@-*otsento
% p@-*otsento $max3
@ _tSe_
& kaI
= egala
& _kaI
= egala $max3
\ deklivo
/ oblikvo
| duktosigno
* asteRisko
* asteRisko $max3
© kopiRaIto
_( R'ondak@-*'ampo
_) f'eRmaRondak@-*'ampo

+ 6
- 4
dictsource/fi_list View File

@@ -67,15 +67,17 @@ _< p'ienempIk'uin
_> s'u:*empIk'uin
_- vi:va2
__ ala2vi:va2
+ plus
+ plus $max3
* asteriski $max3
= 'yht&k'uin $max3
% p@-*osent:I $max3
/ kaut:a2
\ keno
€ eu*o
£ punta2
¤ valu:t:a2
& et
@ &t
% p@-*osent:I
& _et
@ _&t
~ tilde

_acu 'aku:t:I

+ 1
- 3
dictsource/fi_rules View File

@@ -207,13 +207,11 @@

.group
å o
å o:
åå o:
š S
ž Z

$ dollarin
* asteriski
= 'yht&k'uin
__) - (_D mi:nus
A_) - (_D _
C_) - (_D _

+ 4
- 4
dictsource/fr_list View File

@@ -111,7 +111,6 @@ _# djEz
_' a2postr'Of
_( 'uvR@-parA~t'Ez
_) f'Erm parA~t'Ez
_* asterisk:
_, virgyl
_- tirE
_. _|pw%E~
@@ -142,10 +141,11 @@ _§ sEksj'O~

// symbols that are normally spoken when reading text
@ arobaz
% pursA~
& e $u $brk
% pursA~ $max3
* asterisk: $max3
& _e
_& _e_komErsj'al
+ plys
+ plys $max3
~ tilde
€ @ro
¢ sEnt

+ 10
- 6
dictsource/hbs_list View File

@@ -51,7 +51,7 @@ _ú $accent
_lig l'ig&t,UR&
_acu 'akUt
_ac2 dv'ostr**UkI;'akUt
//_brv
_brv br**'Ev // ??
_ced ts'EdIl&
_cir ts'iRkUmflEks
_dia 'uml&Ut
@@ -71,8 +71,12 @@ _tld t'ild&
_cap k'apIt&l // ?? use English until I find the correct word

© 'aUtoRsk&||pr*av&
% p'osto
+ plus
* zvj'ezdits& $max3
= _j'edn&ko $max3
% p'osto $max3
+ plus $max3
. totSk& $max3
?4 . tatSk& $max3
€ 'euRo
?4 € 'evr*o
@ _'at
@@ -82,9 +86,9 @@ _tld t'ild&
?2 ! 'uzvItSnIk
: dv'ototSk&
?4 : dv'ot&tSk&
# br*'oj_
/ kr*'oz_
\\ b'EkslES
# br*'oj_ $max3
/ kr*'oz_ $max3
\ b'EkslES $max3
^ ts'iRkumfleks
~ t'ild&
¤ v'alut&

+ 0
- 15
dictsource/hbs_rules View File

@@ -148,25 +148,10 @@

$ d'ol&R

. totSk&
?4 . tatSk&
. (. _:
\.) .

__) - (_D minus
A_) - (_D _
C_) - (_D _
--) -

* zvj'ezdits&
*) * (*
**
**) * (_ _::

= _j'edn&ko
= (==
=) = (=
==) = (_ _::

.group 0xce // Greek letters


+ 42
- 3
dictsource/hu_list View File

@@ -50,7 +50,7 @@ _lig ligAtu:R2A
_acu e:lES
_ac2 kEt:Y:S
_brv fe:lkYR2
//_ced // cedilla
_ced tse:dillE
_cir tsiR2kumflEks
_dia tR2e:mA
//_dot // dot above
@@ -343,10 +343,49 @@ ty ce:
ly Ellipsilon
ny En^

_. pont
ä $accent
æ $accent
ç $accent
ñ $accent
ø $accent
ß _^_DE

. pont $max3
* tS'illAg $max3
% sa:zAle:k $max3
+ plus $max3
= EJEnlY:Se:g $max3
@ kukAts
& e:SjEl
€ EuR2o
¶ bEkEzde:S
§ pAR2AgR2AfuS
~ tildE
^ hia:n^
° fokjEl
Ft foR2int


_, vEss2Y:
_; pontoSvEss2Y:
_: kEt:Y:Spont
_! fElkia:lto:
_? ke:R2dY:
_- kYtY:jEl
__ Ala:hu:za:S
_' ApostR2o:f
_– nAJkYtY:
_— kviR2tmi:nus
_" ide:zY:
_( za:R2o:
_) za:R2o:
_[ s'YglEtES||z'a:R2o:
_] s'YglEtES||z'a:R2o:
_{ k'AptSoS||z'a:R2o:
_} k'AptSoS||z'a:R2o:
_# sa:mjEl
_… ha:R2_mASpont
_• di:spont
_\ viss2ApER2

// Main Exceptions List
//=====================

+ 0
- 16
dictsource/hu_rules View File

@@ -336,19 +336,3 @@ _szára) zs (ág zS
ç tS
ñ n^
ø Y

% sa:zAle:k
@ kukAts
€ EuR2o
+ plus
§ pAR2AgR2AfuS

. pont
. (. _:
\.) .


* tS'illAg // asterisk
*) * (*
**
**) * (_ _::

+ 0
- 1
dictsource/it_list View File

@@ -441,7 +441,6 @@ principi $1
tesser tess'ER
uomini $1


// $alt = use ò or è in the stressed syllable
// If the final vowel is omitted, then the rule applies to 'a' 'e' 'i' 'o'
$textmode

+ 7
- 7
dictsource/pl_list View File

@@ -174,21 +174,21 @@ _{ n,av;as||klamROvy
_} pRavy||n,av;as||klamR'Ovy
_' ap'OstROf

. kR'Opka
. kR'Opka $max3
~ t'ylda
= R'uvna||S;E
/ slES
* gv;'astka
\ b'EkslES
= R'uvna||S;E $max3
/ slES $max3
* gv;'astka $max3
\ b'EkslES $max3
| kR,Eska||p;On'Ova
# haS
# haS $max3
_$ d'OlaR
% pR'OtsEnt
^ d'aSEk // what's be better?
& and
` 'aktsEnt
@ m'awpa
+ plus
+ plus $max3

// other characters


+ 14
- 5
dictsource/pt_list View File

@@ -53,11 +53,11 @@ _ô $accent
_õ $accent
_ú $accent
_ü $accent
ß _^_DE

v ve // not Roman numbers
x Sis#


_cap maI'uskulU
_?A l'etR&_
_?? s'imbolU_
@@ -65,21 +65,31 @@ _#32 esp'asU
?1 _#32 Sp'asU
_#9 tab

_. p'oNtU
* &ste*'iskU $max3
= __igw'&l_ $max3
. p'oNtU $max3
+ maIs# $max3
% pors'eINtU $max3
& _'e_
@ &x'ob&
¤ 'eU*U
€ 'eU*U
§ p&*'agRafU


_! ,eskl&mas'&U~
_" 'asp&s#

?1 _# k,ardin'al
?2 _# k,ardZin'aU
_$ s,ifR'&U~
_% pors'eINtU
_& 'e
?1 _' ap'Ostr,ofy
?2 _' &p'OstRofU
_( ,abRipa*'eINtezy
_) f,ES&pa*'eINtezy
_* &ste*'iskU
_+ m'aIs#
_− m'enUs

_, v'irgul&
_- 'ifeIN
@@ -91,7 +101,6 @@ _< men'Or
?2 _= igw'aU
_> maI'Or
_? ,iNtex,ogas'&U~
_@ &x'ob&
_[ ,abRikowS'etSi
_\ b,ax&,iNvertS'id&
_] f,ES&kowS'etSi

+ 0
- 22
dictsource/pt_rules View File

@@ -838,39 +838,17 @@
ü u
ß s

% pors'eINtU
$ sifR'&U~
_r_) $
− m'enUs
+ maIs#
& 'e
@ &x'ob&
¤ 'eU*U
€ 'eU*U
§ p&*'agRafU

D_) º %o // ordinal
D_) ª %a // ordinal


// don't speak multiple occurances of these symbols
, (D v'irgul&
. p'oNtU
. (. _:
\.) .

* &ste*'iskU
*) * (*
**
**) * (_ _::

__) - (_D m'enUs
A_) - (_D _
C_) - (_D _
--) -

= __igw'&l_
= (==
=) = (=
==) = (_ _::


+ 10
- 5
dictsource/ro_list View File

@@ -46,6 +46,7 @@ z zet
â ,ydin'a $atend
ă '@ $atend
î ,ydin'i $atend
ö $accent

_?? ka*akt'er
_cap maZusk'ul@
@@ -69,7 +70,7 @@ _tld t'ild@


// punctuation and symbols
_. punkt
_, v'irgul@
_: do'u@p'unkte
_; p'unkt||Siv'irgul@
@@ -93,9 +94,11 @@ _| b'ar@vertik'al@
_#9 t'ab
_#32 sp'atsiU

= eg'al
# dj'ez
+ plus
. punkt $max3
* aste*isk $max3
= eg'al $max3
# dj'ez $max3
+ plus $max3
& ampersand
© k'apiraIt
@ a*'ond
@@ -104,7 +107,6 @@ _#32 sp'atsiU
° g@-*ade



// numeric
//********
_0 z'e*o
@@ -180,6 +182,9 @@ _dpt _v'irgul@
_0Z2 s'utimi
_0Z3 m'iImi

// not Roman numbers
vi vi
vii viI

// Abbreviations
//**************

+ 2
- 11
dictsource/ro_rules View File

@@ -7,7 +7,8 @@
.replace
ș ş
ț ţ

Ș ş // because Windows doesn't convert upper-case Ș Ț to lower-case
Ț ţ

.group a
a a
@@ -471,19 +472,9 @@

, (D v'irgul@

. punkt
. (. _:
\.) .

__) - (_D m'inus
A_) - (_D _
C_) - (_D _
--) -

* aste*isk
*) * (*
**
**) * (_ _::




+ 18
- 8
dictsource/sk_list View File

@@ -47,6 +47,8 @@ y ipsilon
_z zet
ž Zet

ě $accent

// accent names
_lig l'igat,u:Rov,ane:
_acu s_d'l:Zn^om
@@ -72,16 +74,19 @@ _#9 t'ab
_#32 'medzeRa
_?A znak

* hviezda $max3
+ plus $max3
= Rovna:sa $max3
@ zavina:tS
& ampeRsand
# kRi:Zik $max3

_! vi:kRitSn^i:k
_" u:vodzovki
_# kRi:Zik
_$ dola:R
_& ampeRsand
_' apostRof
_( za:tvoRka
_) zatvoRit;
_* hviezda
+ plus
_, tSiaRka
_- poml-tSka
__ podtSiaRknutie
@@ -90,10 +95,8 @@ _/ lomeno
_: dvojbodka
_; bodkotSiaRka
_< menSi:
_= Rovna:sa
_> vetSSi:
_? ota:zn^ik
_@ zavina:tS
_[ hRanata:||za:tvoRka
_\ opatSne:||lomeno
_] hRanata:||zatvoRit;
@@ -179,8 +182,15 @@ _2C dv'est'o
_0M1 t;'isi:ts
_1M1 t;'isi:ts
_2M1 dv'et;'isi:ts
_0M2 m'ilio:n
_0M3 m'iljaRda
_0M2 m'ilio:nou // others, 5-9
_0MA2 m'ilio:ni // for 2,3,4 million
_1M2 m'ilio:n // for 1 million
_0M3 m'iljaRt
_0MA3 m'iljaRdi
_1M3 m'iljaRda
_0M4 b'ilio:nou
_0MA4 b'ilio:ni
_1M4 b'ilio:n
_dpt _:tSj,arka_



+ 6
- 4
dictsource/tr_list View File

@@ -44,7 +44,7 @@ _?A haRf
_acu vURg'UimI
_ac2 tS'IftvURg'UimI
_brv ku#s'altmaimI
_ced tSEnJ'El
_ced h'aRf
_cir Sapk'a
_dia Umla'Ut
_dot YstnOkt'a
@@ -75,15 +75,17 @@ _^ IndZ'EltmEiSa*et'I
_& v'EiSa*et'I
_* j'u#ldu#z
_@ kUjRUkl'U'a
_\\ t'ERs||ej,IktSIzg'I
_\ t'ERs||ej,IktSIzg'I
¶ pa*agR'af
§ tSEnJ'El
° de*edZ'E
_# dij'Ez
_~ jaklaS'u#k
__ ,alttSIzg'I
+ aRt'u#
€ avR'O
= ESIt $max3
% jYzdE $max3
+ aRtu# $max3
€ avRO


_0 su#fu#R

+ 1
- 1
dictsource/tr_rules View File

@@ -321,5 +321,5 @@

.group
$ dolar
' (Pb % // split a word at ' and translate the first part separately.
' (Pb // split a word at ' and translate the first part separately.


+ 52
- 46
phsource/compile_report View File

@@ -2,12 +2,12 @@
new total
base 103 103
base2 24 122
en 51 149
en_n 31 149
en_us 36 150
en 50 149
en_n 32 149
en_us 37 150
en_sc 39 151
en_rp 34 149
en_wm 30 149
en_wm 31 149
en_wi 30 149
af 39 135
cy 29 129
@@ -22,12 +22,12 @@
hu 23 119
lv 29 126
nl 28 126
pl 19 116
sk 28 134
cs 6 134
hr 26 139
mk 3 140
sr 14 139
pl 20 117
sk 28 135
cs 6 135
hr 26 140
mk 3 141
sr 14 140
ru 39 134
it 17 125
la 21 121
@@ -49,15 +49,15 @@
tr 18 127
ku 18 127
id 15 124
sq 35 127
hy 24 119
rw 15 129
ko 18 159
da 15 133
sq 35 127
ml 13 151
kn 15 151
bn 59 155
ne 18 157
hy 24 119
om 25 125
en_klatt 77 149
ga 18 117
@@ -184,6 +184,7 @@ d/xd [d] base
[d.h] hi
[d] hu
[d] pl
[dz] pl
[d] hr
[d] ru
[d;] ro
@@ -192,9 +193,9 @@ d/xd [d] base
[d] id
[d] sq
[dz] sq
[dz] hy
[d] bn
[d.] bn
[dz] hy
[d[] ga
d/xd2 [d`] om
d/xd3 [dh] hi
@@ -751,10 +752,12 @@ n/nj [n] base
[n] da
n/n_long_ [n] zh
nn/_nn [N] base
[N] en
[N] en_n
[N] en_wm
[N] zh
nn/nn_ [N] base
[N] en
[N] en_n
[N] en_wm
nn/nn@ [(@)] base
[(@)] en_klatt
nn/nn#_ [N#] is
@@ -945,8 +948,8 @@ ufric/s [s] base
[z2] fr
[s] es
[s#] pt
[s`] ko
[z] sq
[s`] ko
[s] en_klatt
ufric/s_ [s] base
[z] base
@@ -1103,10 +1106,10 @@ ustop/k_unasp [k] base
[k] sk
[k] el
[k] zhy
[k`] ko
[k] sq
[k] bn
[k] hy
[k`] ko
[k] bn
ustop/k_unasp_ [k] zh
ustop/null [?] base
ustop/p [p] base
@@ -1119,8 +1122,8 @@ ustop/p_ [p] base
[p2] fr
[ph] hi
[ph] zh
[ph] bn
[p#] hy
[ph] bn
ustop/p_asp [bh] hi
[ph] hi
[p#] hy
@@ -1138,10 +1141,10 @@ ustop/pl [p] base
[p] la
[p;] ro
[p] sq
[p] bn
[ph] bn
[p] hy
[p#] hy
[p] bn
[ph] bn
ustop/pr [p] base
[p] base2
[p] fi
@@ -1151,10 +1154,10 @@ ustop/pr [p] base
[p] hu
[p] la
[p;] ro
[p] bn
[ph] bn
[p] hy
[p#] hy
[p] bn
[ph] bn
ustop/p_unasp [p] base
[p] base2
[p] fi
@@ -1166,10 +1169,10 @@ ustop/p_unasp [p] base
[p] la
[p;] ro
[p] zh
[p`] ko
[p] sq
[p] bn
[p] hy
[p`] ko
[p] bn
ustop/p_unasp_ [p] base2
[p] fi
[p] hi
@@ -1179,8 +1182,8 @@ ustop/p_unasp_ [p] base2
[p] la
[p;] ro
[p] sq
[p] bn
[p] hy
[p] bn
ustop/q [q] base
ustop/q_u [q] base
ustop/t [t] base
@@ -1216,18 +1219,18 @@ ustop/t_dnt [t] base
[t;] ro
[t[] vi
[t] sw
[t`] ko
[t] sq
[t] bn
[t] hy
[t`] ko
[t] bn
[t[] ga
ustop/t_dnt2 [t[] vi
ustop/t_ejc [t`] om
ustop/t_hi [t] hi
[t] sq
[t] hy
[t] bn
[th] bn
[t] hy
ustop/t_pzd [t;] pl
[t;] ru
ustop/tr [t] base
@@ -1240,6 +1243,7 @@ ustop/ts [ts] base2
[ts] eo
[ts] hu
[ts] pl
[dz] pl
[ts] ru
[ts;] ro
[z] zhy
@@ -1254,6 +1258,7 @@ ustop/ts_ [ts] base2
[ts] hu
[ts] lv
[ts] pl
[dz] pl
[ts] ru
[ts;] ro
[ts] sq
@@ -1289,13 +1294,13 @@ ustop/ts_pzd [tS;] base
[ch] bn
ustop/ts_pzd_ [c] hi
[c] hu
[c] bn
[c] hy
[c] bn
ustop/ts_pzd2 [c] hi
[c] hu
[c] hy
[c`] ko
[c] bn
[c] hy
ustop/ts_pzd3 [tS;] hr
[dZ;] hr
ustop/t_sr [d] sr
@@ -1406,8 +1411,8 @@ vdiph/ai [aI] base2
[aI] pt
[a:I] vi
[aI] id
[aI] kn
[aI] hy
[aI] kn
vdiph/ai_2 [aI] en
[aI] cy
[aY] cy
@@ -1440,8 +1445,8 @@ vdiph/eei [EI] base2
[EI] de
[EI] nl
[EI] vi
[eI] ne
[eI] hy
[eI] ne
vdiph/eei_2 [eI] eo
[ei] fi
[ei] lv
@@ -1704,10 +1709,10 @@ vowel/@ [@] base
[@] en_rp
[V] cy
[@4] hi
[@] hy
[@] ml
[@] kn
[@4] bn
[@] hy
[@] ga
vowel/@- [@-] base
[r*] hr
@@ -1726,7 +1731,8 @@ vowel/0 [0] en
vowel/0_2 [0] en_n
[O] pt_pt
[o] sw
vowel/0_3 [O] en_sc
vowel/0_3 [O:] en_us
[O] en_sc
[0] en_rp
[A] hu
vowel/@_2 [@] vi
@@ -1754,7 +1760,6 @@ vowel/@_4 [@] en_us
[@] nl
[@] no
vowel/@_5 [W] fr
vowel/@_6 [@/] en_us
vowel/8 [o-] zh
vowel/8_2 [U] en_us
[8] sv
@@ -1820,8 +1825,8 @@ vowel/a_3 [a] en_sc
[a:] la
[a] is
[A] zh
[A] da
[a] sq
[A] da
vowel/a#_3 [a2] en
[a2] en_n
[a2] en_us
@@ -1871,8 +1876,7 @@ vowel/aa_2 [A:] en
[A] zh
vowel/aa_3 [A:] af
[A] sq
vowel/aa_4 [O:] en_us
[A:] sv
vowel/aa_4 [A:] sv
[O] vi
vowel/aa_5 [A:] en_n
[A:] en_wm
@@ -1915,11 +1919,11 @@ vowel/e [e] base2
[e] grc
[e] vi
[e] id
[e] sq
[e] rw
[e#] rw
[e] ko
[e] da
[e] sq
[e] ml
[e:] ml
[e:] kn
@@ -1991,9 +1995,9 @@ vowel/e_mid [E] en_rp
[E] tr
[E] id
[E2] id
[e] hy
[E] da
[E] bn
[e] hy
vowel/e_mid2 [E] af
[E] de
[E2] de
@@ -2007,8 +2011,8 @@ vowel/e_mid2 [E] af
[e] el
[e] sw
[e] tr
[E] ko
[e#] sq
[E] ko
[e] kn
[E] om
[E#] om
@@ -2038,13 +2042,13 @@ vowel/i [i] base2
[i] zhy
[i] zh
[i] sw
[i] hy
[i] rw
[i#] rw
[i] ko
[i:] ml
[i:] kn
[i] ne
[i] hy
[i:] om
[i:] ga
vowel/i# [y:] cy
@@ -2156,6 +2160,8 @@ vowel/@_low [3] en_rp
[@2] bn
[V] ne
[@/] ne
vowel/@_low2 [@/] en_us
[@2] en_us
vowel/o [o] base2
[o:] en
[oU] en_n
@@ -2172,6 +2178,7 @@ vowel/o [o] base2
[o] grc
[o:] sv
[o] id
[o] hy
[o] rw
[o#] rw
[o] ml
@@ -2179,7 +2186,6 @@ vowel/o [o] base2
[o] kn
[o:] kn
[o] bn
[o] hy
[o:] ga
vowel/o_2 [o:] cy
[o2] fr
@@ -2204,8 +2210,8 @@ vowel/o_7 [o] ku
vowel/oe [W] en
[W] af
[W] de
[W] da
[W] hy
[W] da
vowel/oe_2 [W] no
[W] tr
vowel/oe_4 [W] sv
@@ -2342,12 +2348,12 @@ vowel/u_bck [u] base2
[u] is
[u] zhy
[u] zh
[u] hy
[u] rw
[u#] rw
[u] ko
[u:] bn
[u] ne
[u] hy
[u:] ga
vowel/u_bck2 [u:] la
[u] sq

+ 0
- 12
phsource/ph_english View File

@@ -27,18 +27,6 @@ phoneme t2 // [t] which doesn't reduce
endphoneme


phoneme N
vcd vel nasal
vowelout f1=3 f2=2300 300 400 f3=-200 80 len=40 rms=20 brk
length 100
formants NULL
after _ nn/_nn
before _ nn/nn_
lengthmod 8 // longer than 'n'
linkout g-
endphoneme


phoneme l
liquid
length 100

+ 12
- 0
phsource/ph_english_n View File

@@ -1,4 +1,16 @@

phoneme N
vcd vel nasal
vowelout f1=3 f2=2300 300 400 f3=-200 80 len=40 rms=20 brk
length 100
formants NULL
after _ nn/_nn
before _ nn/nn_
lengthmod 8 // longer than 'n'
linkout g-
endphoneme



//*******************************************************************
// VOWELS

+ 13
- 9
phsource/ph_english_us View File

@@ -1,5 +1,4 @@


//*******************************************************************
// VOWELS
//*******************************************************************
@@ -10,7 +9,6 @@ phoneme 3 // Schwa, used for rhotic schwa in American
formants vwl_en_us/3_us
unstressed
linkout r-
// beforevowel @
length 210
endphoneme

@@ -19,16 +17,24 @@ phoneme @ // Schwa
vowel starttype (@) endtype (@)
formants vowel/@_4
unstressed
before_r 3
length 130
endphoneme

phoneme @/ // Schwa, end of word
vowel starttype (@) endtype (@)
formants vowel/@_6
formants vowel/@_low2
unstressed
length 130
endphoneme

phoneme @2 // Schwa, changes to I before a vowel
vowel starttype (@) endtype (@)
formants vowel/@_low2
unstressed
beforevowel I2
length 120
endphoneme

phoneme @L
vowel starttype (@) endtype l
@@ -137,7 +143,7 @@ endphoneme

phoneme A@ // Used for [A:] when followed by 'r', becomes [A:]+[r] in American
vowel starttype (a) endtype (@)
length 250
length 260
formants vwl_en_us/ar
appendph r
endphoneme
@@ -160,12 +166,10 @@ endphoneme


phoneme O:
vowel starttype (a) endtype (a)
vowel starttype (o) endtype (o)
length 210
formants vowel/aa_4
// formants vowel/aa_4
formants vowel/0_3
before r vwl_en_us/oor
// before r vwl_en_us/or
reduceto @ 0
endphoneme

@@ -188,7 +192,7 @@ endphoneme


phoneme O
vowel starttype (a) endtype (a)
vowel starttype (o) endtype (o)
length 200
formants vowel/aa#
reduceto @ 0

+ 12
- 0
phsource/ph_english_wm View File

@@ -1,4 +1,16 @@

phoneme N
vcd vel nasal
vowelout f1=3 f2=2300 300 400 f3=-200 80 len=40 rms=20 brk
length 100
formants NULL
after _ nn/_nn
before _ nn/nn_
lengthmod 8 // longer than 'n'
linkout g-
endphoneme



//*******************************************************************
// VOWELS

+ 15
- 1
phsource/ph_polish View File

@@ -138,7 +138,6 @@ phoneme d;
endphoneme



phoneme ts
vls alv afr sibilant
vowelin f1=0 f2=1700 -300 300 f3=-100 80
@@ -146,10 +145,25 @@ phoneme ts
lengthmod 2
wave ustop/ts
before _ ustop/ts_
switchvoicing dz
endphoneme


phoneme dz
vcd alv afr sibilant
vowelin f1=1 f2=1700 -300 300 f3=-100 80
vowelout f1=2 f2=1700 -300 300 f3=-100 80
formants d/xd+ustop/ts
before _ d/xd+ustop/ts_
after _ NULL
after @ d/xd
lengthmod 5
switchvoicing ts
endphoneme




phoneme w
liquid
length 100

+ 7
- 6
phsource/phonemes View File

@@ -365,6 +365,7 @@ endphoneme

phoneme r
liquid starttype #r endtype #r
rhotic
length 100
lengthmod 7
beforenotvowel r/
@@ -1324,6 +1325,12 @@ include ph_kurdish
phonemetable id base2
include ph_indonesian

phonemetable sq base
include ph_albanian

phonemetable hy base
include ph_armenian



phonemetable rw base2
@@ -1335,9 +1342,6 @@ include ph_korean
phonemetable da is
include ph_danish

phonemetable sq base
include ph_albanian

phonemetable ml hi
include ph_malayalam

@@ -1350,9 +1354,6 @@ include ph_bengali
phonemetable ne hi
include ph_nepali

phonemetable hy base
include ph_armenian

phonemetable om base
include ph_oromo


BIN
phsource/vdiph2/u@ View File


BIN
phsource/vowel/0_3 View File


BIN
phsource/vowel/@_low2 View File


BIN
phsource/vowel/a View File


BIN
phsource/vowel/vowelchart.png View File


BIN
phsource/vwl_en_us/3_us2 View File


BIN
phsource/vwl_en_us/ar View File


+ 6
- 2
src/compiledata.cpp View File

@@ -69,6 +69,7 @@
#define tBEFORENOTVOWEL 19
#define tBEFORENOTVOWEL2 20
#define tSWITCHVOICING 21
#define tBEFORE_R 22

#define tLINKOUT 23
#define tVOWELIN 24
@@ -83,7 +84,7 @@
#define tSTRESSTYPE 32


static const int flags_alternative[] = {phBEFOREVOWEL,phBEFOREVOWELPAUSE,phBEFORENOTVOWEL,phBEFORENOTVOWEL2,phSWITCHVOICING};
static const int flags_alternative[] = {phBEFOREVOWEL,phBEFOREVOWELPAUSE,phBEFORENOTVOWEL,phBEFORENOTVOWEL2,phSWITCHVOICING,phBEFORE_R};

extern void MakeVowelLists(void);
extern void FindPhonemesUsed(void);
@@ -243,6 +244,7 @@ static keywtab_t keywords[] = {
{"beforevowelpause", tBEFOREVOWELPAUSE},
{"beforenotvowel",tBEFORENOTVOWEL},
{"beforenotvowel2",tBEFORENOTVOWEL2},
{"before_r",tBEFORE_R},
{"linkout",tLINKOUT},
{"switchvoicing",tSWITCHVOICING},
{"vowelin",tVOWELIN},
@@ -263,6 +265,7 @@ static keywtab_t keywords[] = {
{"palatal", 0x2000000+phPALATAL},
{"long", 0x2000000+phLONG},
{"brkafter", 0x2000000+phBRKAFTER},
{"rhotic", 0x2000000+phRHOTIC},
{"nonsyllabic",0x2000000+phNONSYLLABIC},
{"lengthenstop",0x2000000+phLENGTHENSTOP},

@@ -1465,6 +1468,7 @@ int Compile::CPhoneme()
case tBEFORENOTVOWEL:
case tBEFORENOTVOWEL2:
case tSWITCHVOICING:
case tBEFORE_R:
ph->phflags |= flags_alternative[item - tBEFOREVOWEL];
if((phcode = NextItem(tPHONEMEMNEM)) == -1)
phcode = LookupPhoneme(item_string,1);
@@ -1813,7 +1817,7 @@ int LoadEnvelope2(FILE *f, const char *fname)
n = sscanf(line_buf,"%f %f %d",&env_x[n_points],&env_y[n_points],&env_lin[n_points]);
if(n >= 2)
{
env_x[n_points] *= 1.28; // convert range 0-100 to 0-128
env_x[n_points] *= (float)1.28; // convert range 0-100 to 0-128
n_points++;
}
}

+ 33
- 4
src/compiledict.cpp View File

@@ -1271,7 +1271,16 @@ static void output_rule_group(FILE *f_out, int n_rules, char **rules, char *name
static int compile_lettergroup(char *input, FILE *f_out)
{//=====================================================
char *p;
char *p_start;
int group;
int ix;
int n_items;
int length;
int max_length = 0;

#define N_LETTERGP_ITEMS 200
char *items[N_LETTERGP_ITEMS];
char item_length[N_LETTERGP_ITEMS];

p = input;
if(!isdigit(p[0]) || !isdigit(p[1]))
@@ -1296,18 +1305,38 @@ static int compile_lettergroup(char *input, FILE *f_out)
fputc(group + 'A', f_out);
letterGroupsDefined[group] = 1;

for(;;)
n_items = 0;
while(n_items < N_LETTERGP_ITEMS)
{
while(isspace2(*p)) p++;
if(*p == 0)
break;

items[n_items] = p_start = p;
while((*p & 0xff) > ' ')
{
fputc(*p++, f_out);
p++;
}
fputc(0,f_out);
*p++ = 0;
length = p - p_start;
if(length > max_length)
max_length = length;
item_length[n_items++] = length;
}

// write out the items, longest first
while(max_length > 1)
{
for(ix=0; ix < n_items; ix++)
{
if(item_length[ix] == max_length)
{
fwrite(items[ix],1,max_length,f_out);
}
}
max_length--;
}

fputc(RULE_GROUP_END,f_out);

return(0);

+ 4
- 1
src/numbers.cpp View File

@@ -829,7 +829,10 @@ static const char *M_Variant(int value)
{//====================================
// returns M, or perhaps MA for some cases
if(((value % 100)>20) || ((value % 100)<10)) // but not teens, 10 to 19
if((translator->langopts.numbers2 & 0x100) && (value >= 2) && (value <= 4))
return("0MA"); // Czech, Slovak
else
if(((value % 100) < 10) || ((value % 100) > 20)) // but not teens, 10 to 19
{
if ((translator->langopts.numbers2 & 0x40) &&
((value % 10)>=2) &&

+ 2
- 0
src/phoneme.h View File

@@ -55,10 +55,12 @@
#define phBEFORENOTVOWEL 0x0c00
#define phBEFORENOTVOWEL2 0x1000
#define phSWITCHVOICING 0x0800
#define phBEFORE_R 0x1400

#define phNONSYLLABIC 0x100000 // don't count this vowel as a syllable when finding the stress position
#define phLONG 0x200000
#define phLENGTHENSTOP 0x400000 // make the pre-pause slightly longer
#define phRHOTIC 0x800000

// fixed phoneme code numbers, these can be used from the program code
#define phonCONTROL 1

+ 7
- 0
src/phonemelist.cpp View File

@@ -427,6 +427,13 @@ void MakePhonemeList(Translator *tr, int post_pause, int start_sentence)
if(next->type == phVOWEL)
alternative = ph->alternative_ph;
break;

case phBEFORE_R:
if(next->phflags & phRHOTIC)
{
alternative = ph->alternative_ph;
}
break;
}
}
if(ph->phflags & phBEFOREPAUSE)

+ 1
- 1
src/readclause.cpp View File

@@ -1750,7 +1750,7 @@ static int ProcessSsmlTag(wchar_t *xml_buf, char *outbuf, int &outix, int n_outb
}
if((attr2 = GetSsmlAttribute(px,"time")) != NULL)
{
value = (attrnumber(attr2,0,1) * 25) / speed_factor1; // compensate for speaking speed to keep constant pause length
value = (attrnumber(attr2,0,1) * 25) / speed.speed_factor1; // compensate for speaking speed to keep constant pause length

if(terminator == 0)
terminator = CLAUSE_NONE;

+ 21
- 9
src/setlengths.cpp View File

@@ -136,24 +136,37 @@ void SetSpeed(int control)
{
// these are used in synthesis file
s1 = (x * voice->speedf1)/256;
speed_factor1 = (256 * s1)/115; // full speed adjustment, used for pause length
if(speed_factor1 < 15)
speed_factor1 = 15;
speed.speed_factor1 = (256 * s1)/115; // full speed adjustment, used for pause length
if(speed.speed_factor1 < 15)
speed.speed_factor1 = 15;
if(wpm >= 170)
// speed_factor2 = 100 + (166*s1)/128; // reduced speed adjustment, used for playing recorded sounds
speed_factor2 = 110 + (150*s1)/128; // reduced speed adjustment, used for playing recorded sounds
speed.speed_factor2 = 110 + (150*s1)/128; // reduced speed adjustment, used for playing recorded sounds
else
speed_factor2 = 128 + (128*s1)/130; // = 215 at 170 wpm
speed.speed_factor2 = 128 + (128*s1)/130; // = 215 at 170 wpm

if(wpm2 > 369)
{
if(wpm2 > 390)
wpm2 = 390;
speed_factor2 = faster[wpm2 - 370];
speed.speed_factor2 = faster[wpm2 - 370];
}
}

speed_min_sample_len = 450;
speed.min_sample_len = 450;
speed.speed_factor3 = 110; // controls the effect of FRFLAG_LEN_MOD reduce length change

if(wpm2 >= 370)
{
// TESTING
// use experimental fast settings if they have been specified in the Voice
if(speed.fast_settings[0] > 0)
speed.speed_factor1 = speed.fast_settings[0];
if(speed.fast_settings[1] > 0)
speed.speed_factor2 = speed.fast_settings[1];
if(speed.fast_settings[2] > 0)
speed.speed_factor3 = speed.fast_settings[2];
}
} // end of SetSpeed


@@ -528,8 +541,7 @@ void CalcLengths(Translator *tr)
length_mod *= speed3;

length_mod = length_mod / 128;
// if(length_mod < 9)
// length_mod = 9; // restrict how much lengths can be reduced

if(length_mod < 8)
length_mod = 8; // restrict how much lengths can be reduced


+ 3
- 3
src/synth_mbrola.cpp View File

@@ -597,13 +597,13 @@ void MbrolaTranslate(PHONEME_LIST *plist, int n_phonemes, FILE *f_mbrola)
{
// a pause phoneme, which has not been changed by the translation
name = '_';
len = (p->length * speed_factor1)/256;
len = (p->length * speed.speed_factor1)/256;
// if(len == 0) continue;
if(len == 0)
len = 1;
}
else
len = (80 * speed_factor2)/256;
len = (80 * speed.speed_factor2)/256;

#ifdef USE_MBROLA_LIB
MbrolaMarker(espeakEVENT_PHONEME, (p->sourceix & 0x7ff) + clause_start_char, 0, ph->mnemonic);
@@ -664,7 +664,7 @@ void MbrolaTranslate(PHONEME_LIST *plist, int n_phonemes, FILE *f_mbrola)
break;

case phVSTOP:
len = (80 * speed_factor2)/256;
len = (80 * speed.speed_factor2)/256;
break;

case phFRICATIVE:

+ 1
- 1
src/synthdata.cpp View File

@@ -35,7 +35,7 @@
#include "translate.h"
#include "wave.h"

const char *version_string = "1.39.42 17.Dec.08";
const char *version_string = "1.39.48 19.Dec.08";
const int version_phdata = 0x013900;

int option_device_number = -1;

+ 6
- 8
src/synthesize.cpp View File

@@ -45,9 +45,7 @@ PHONEME_LIST phoneme_list[N_PHONEME_LIST];
int mbrola_delay;
char mbrola_name[20];

int speed_factor1;
int speed_factor2;
int speed_min_sample_len;
SPEED_FACTORS speed;

static int last_pitch_cmd;
static int last_amp_cmd;
@@ -192,9 +190,9 @@ int PauseLength(int pause, int control)
int len;

if(control == 0)
len = (pause * speed_factor1)/256;
len = (pause * speed.speed_factor1)/256;
else
len = (pause * speed_factor2)/256;
len = (pause * speed.speed_factor2)/256;

if(len < 5) len = 5; // mS, limit the amount to which pauses can be shortened
return(len);
@@ -253,8 +251,8 @@ static int DoSample2(int index, int which, int length_mod, int amp)
length = length1;


length = (length * speed_factor2)/256;
min_length = speed_min_sample_len;
length = (length * speed.speed_factor2)/256;
min_length = speed.min_sample_len;
if(format==0)
min_length *= 2;

@@ -982,7 +980,7 @@ if(which==1)
length_factor = length_mod;
if(frame1->frflags & FRFLAG_LEN_MOD) // reduce effect of length mod
{
length_factor = (length_mod*4 + 256*3)/7;
length_factor = (length_mod*(256-speed.speed_factor3) + 256*speed.speed_factor3)/256;
}
len = (frame_length * samplerate)/1000;
len = (len * length_factor)/256;

+ 9
- 3
src/synthesize.h View File

@@ -213,6 +213,14 @@ typedef struct {
int control;
} MBROLA_TAB;

typedef struct {
int speed_factor1;
int speed_factor2;
int speed_factor3;
int min_sample_len;
int fast_settings[8];
} SPEED_FACTORS;


// phoneme table
extern PHONEME_TAB *phoneme_tab[N_PHONEME_TAB];
@@ -304,9 +312,7 @@ int CompileDictionary(const char *dsource, const char *dict_name, FILE *log, cha

extern unsigned char *envelope_data[18];
extern int formant_rate[]; // max rate of change of each formant
extern int speed_factor1;
extern int speed_factor2;
extern int speed_min_sample_len;
extern SPEED_FACTORS speed;

extern long count_samples;
extern int outbuf_size;

+ 3
- 3
src/tr_languages.cpp View File

@@ -282,7 +282,7 @@ Translator *SelectTranslator(const char *name)
SetLetterBitsRange(tr,LETTERGP_F,0x3e,0x4c); // vowel signs, but not virama

tr->langopts.numbers = 0x1;
tr->langopts.numbers2 = 0x100;
tr->langopts.numbers2 = NUM2_100000;
}
break;

@@ -849,13 +849,13 @@ SetLengthMods(tr,3); // all equal
tr->langopts.param[LOPT_COMBINE_WORDS] = 4; // combine some prepositions with the following word

tr->langopts.numbers = 0x0401 + 0x4000 + NUM_ROMAN;
tr->langopts.numbers2 = 0x40;
tr->langopts.numbers2 = 0x100;
tr->langopts.thousands_sep = 0; //no thousands separator
tr->langopts.decimal_sep = ',';

if(name2 == L('c','s'))
{
tr->langopts.numbers2 = 0x48; // variant numbers before milliards
tr->langopts.numbers2 = 0x108; // variant numbers before milliards
}

SetLetterVowel(tr,'y');

+ 4
- 3
src/translate.h View File

@@ -349,14 +349,15 @@ typedef struct {
// bit21= say "roman" after the number, not before
int numbers;

#define NUM2_100000 0x100 // numbers for 100,000 and 10,000,000
#define NUM2_100000a 0x500 // numbers for 100,000 and 1,000,000
#define NUM2_100000 0x800 // numbers for 100,000 and 10,000,000
#define NUM2_100000a 0xc00 // numbers for 100,000 and 1,000,000
// bits 1-4 use variant form of numbers before thousands,millions,etc.
// bit6=(LANG=pl) two forms of plural, M or MA
// bit7=(LANG-ru) use MB for 1 thousand, million, etc
// bit8=(LANG=hi) special word for 100,000 and 10,000,000
// bit8=(LANG=cs,sk) two forms of plural, M or MA
// bit9=(LANG=rw) say "thousand" and "million" before its number, not after
// bit10=(LANG=sw) special word for 100,000 and 1,000,000
// bit11=(LANG=hi) special word for 100,000 and 10,000,000
int numbers2;

int max_roman;

+ 41
- 32
src/voices.cpp View File

@@ -69,44 +69,46 @@ static int len_path_voices;
espeak_VOICE voice_selected;


#define V_NAME 1
#define V_LANGUAGE 2
#define V_GENDER 3
#define V_TRANSLATOR 4
#define V_PHONEMES 5
#define V_DICTIONARY 6
enum {
V_NAME = 1,
V_LANGUAGE,
V_GENDER,
V_TRANSLATOR,
V_PHONEMES,
V_DICTIONARY,

// these affect voice quality, are independent of language
#define V_FORMANT 7
#define V_PITCH 8
#define V_ECHO 9
#define V_FLUTTER 10
#define V_ROUGHNESS 11
#define V_CLARITY 12
#define V_TONE 13
#define V_VOICING 14
#define V_BREATH 15
#define V_BREATHW 16
V_FORMANT,
V_PITCH,
V_ECHO,
V_FLUTTER,
V_ROUGHNESS,
V_CLARITY,
V_TONE,
V_VOICING,
V_BREATH,
V_BREATHW,

// these override defaults set by the translator
#define V_WORDGAP 17
#define V_INTONATION 18
#define V_STRESSLENGTH 19
#define V_STRESSAMP 20
#define V_STRESSADD 21
#define V_DICTRULES 22
#define V_STRESSRULE 23
#define V_CHARSET 24
#define V_NUMBERS 25
#define V_OPTION 26

#define V_MBROLA 27
#define V_KLATT 28
V_WORDGAP,
V_INTONATION,
V_STRESSLENGTH,
V_STRESSAMP,
V_STRESSADD,
V_DICTRULES,
V_STRESSRULE,
V_CHARSET,
V_NUMBERS,
V_OPTION,

V_MBROLA,
V_KLATT,
V_FAST,

// these need a phoneme table to have been specified
#define V_REPLACE 29
#define V_CONSONANTS 30
V_REPLACE,
V_CONSONANTS
};



@@ -147,6 +149,7 @@ static keywtab_t keyword_tab[] = {
{"mbrola", V_MBROLA},
{"consonants", V_CONSONANTS},
{"klatt", V_KLATT},
{"fast_test", V_FAST},

// these just set a value in langopts.param[]
{"l_dieresis", 0x100+LOPT_DIERESES},
@@ -385,6 +388,7 @@ void VoiceReset(int tone_only)
voice->consonant_amp = 100;
voice->consonant_ampv = 100;
memset(voice->klatt,0,sizeof(voice->klatt));
memset(speed.fast_settings,0,sizeof(speed.fast_settings));

#ifdef PLATFORM_RISCOS
voice->roughness = 1;
@@ -880,6 +884,11 @@ voice_t *LoadVoice(const char *vname, int control)
voice->klatt[KLATT_Kopen] -= 40;
break;

case V_FAST:
Read8Numbers(p,speed.fast_settings);
SetSpeed(2);
break;

default:
if((key & 0xff00) == 0x100)
{

Loading…
Cancel
Save