eSpeak NG is an open source speech synthesizer that supports more than hundred languages and accents.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

ph_latvian 5.9KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337
  1. // IF thisPh(isStressed) THEN
  2. // FMT(vowel/..., 100)
  3. // ELIF thisPh(isDiminished) AND NOT prevVowel(isStressed) THEN
  4. // FMT(vowel/..., 50)
  5. // ELSE
  6. // FMT(vowel/..., 75)
  7. // ENDIF
  8. phoneme a
  9. vwl starttype #a endtype #a
  10. length 120
  11. FMT(vwl_lv/a, 100) // adjusted from aa_3
  12. endphoneme
  13. phoneme a:
  14. vwl starttype #a endtype #a
  15. length 300
  16. lng
  17. FMT(vwl_lv/aa, 90)
  18. endphoneme
  19. phoneme E
  20. vwl starttype #e endtype #e
  21. length 120
  22. FMT(vwl_lv/e2, 100)
  23. endphoneme
  24. phoneme E:
  25. vwl starttype #e endtype #e
  26. length 300
  27. FMT(vwl_lv/ee2, 100)
  28. endphoneme
  29. phoneme e
  30. vwl starttype #e endtype #e
  31. length 120
  32. FMT(vwl_lv/e, 100) // other alternative e_5
  33. endphoneme
  34. phoneme e:
  35. vwl starttype #e endtype #e
  36. length 300
  37. FMT(vwl_lv/ee, 100) // other alternative e_8
  38. endphoneme
  39. phoneme i
  40. vwl starttype #i endtype #i
  41. length 120
  42. FMT(vwl_lv/i, 110) // was i_6
  43. endphoneme
  44. phoneme i:
  45. vwl starttype #i endtype #i
  46. length 300
  47. FMT(vwl_lv/ii, 100) // was i_7
  48. endphoneme
  49. phoneme y // English y, short Latgalian "hard i"
  50. vwl starttype #i endtype #i
  51. length 120
  52. FMT(vowel/y_2)
  53. endphoneme
  54. phoneme y: // Long Latgalian "hard i"
  55. vwl starttype #i endtype #i
  56. length 300
  57. FMT(vowel/y_2)
  58. endphoneme
  59. phoneme o
  60. vwl starttype #o endtype #o
  61. length 120
  62. FMT(vwl_lv/o, 90)
  63. endphoneme
  64. phoneme o:
  65. vwl starttype #o endtype #o
  66. length 300
  67. FMT(vwl_lv/oo, 75)
  68. endphoneme
  69. phoneme u
  70. vwl starttype #u endtype #u
  71. length 120
  72. FMT(vwl_lv/u, 140)
  73. endphoneme
  74. phoneme u:
  75. vwl starttype #u endtype #u
  76. length 300
  77. FMT(vwl_lv/uu, 120)
  78. endphoneme
  79. phoneme ai
  80. vwl starttype #a endtype #i
  81. length 250
  82. lng
  83. FMT(vdiph/aai, 100)
  84. endphoneme
  85. phoneme au
  86. vwl starttype #a endtype #u
  87. length 275
  88. lng
  89. FMT(vdiph/aau, 100)
  90. endphoneme
  91. phoneme ei
  92. vwl starttype #e endtype #i
  93. length 250
  94. lng
  95. FMT(vdiph/eei_2, 100)
  96. endphoneme
  97. phoneme ie
  98. vwl starttype #i endtype #e
  99. length 250
  100. lng
  101. FMT(vdiph2/ie_2, 100)
  102. endphoneme
  103. phoneme iu
  104. vwl starttype #i endtype #u
  105. length 250
  106. lng
  107. FMT(vdiph2/iu_2, 100)
  108. endphoneme
  109. phoneme ui
  110. vwl starttype #u endtype #i
  111. length 250
  112. lng
  113. FMT(vdiph/ui, 100)
  114. endphoneme
  115. phoneme uo
  116. vwl starttype #u endtype #a
  117. length 260
  118. lng
  119. FMT(vdiph2/uaa, 100)
  120. endphoneme
  121. phoneme o` // shorter version of uo
  122. vwl starttype #u endtype #a
  123. length 180
  124. lng
  125. FMT(vdiph2/uaa, 100)
  126. endphoneme
  127. phoneme oi
  128. vwl starttype #o endtype #i
  129. length 250
  130. lng
  131. FMT(vdiph/ooi, 100)
  132. endphoneme
  133. phoneme ts
  134. vls alv afr nolink
  135. voicingswitch J
  136. length 55
  137. lengthmod 1
  138. WAV(ustop/ts2, 60)
  139. endphoneme
  140. phoneme tS
  141. vls pla afr sib
  142. voicingswitch dZ
  143. lengthmod 2
  144. length 80
  145. WAV(ustop/tsh,40)
  146. endphoneme
  147. phoneme n-
  148. vwl starttype #a endtype #a
  149. ipa nU+0329
  150. lengthmod 4
  151. length 120
  152. FMT(n/n-syl)
  153. endphoneme
  154. phoneme R // Latvian hard r
  155. liquid trl
  156. lengthmod 6
  157. Vowelin f1=0 f2=1700 -300 300 f3=-300 80
  158. Vowelout f1=2 f2=1700 -300 300 f3=-300 80 brk
  159. FMT(r3/r_trill) addWav(r3/r_trill.wav, 60)
  160. endphoneme
  161. phoneme r // Latvian soft r
  162. liquid trl
  163. lengthmod 6
  164. Vowelin f1=0 f2=1700 -300 300 f3=-300 80
  165. Vowelout f1=2 f2=1700 -300 300 f3=-300 80 brk
  166. FMT(j/j_) addWav(r3/r_trill.wav, 25)
  167. endphoneme
  168. phoneme t
  169. vls alv stp //lengthenstop
  170. lengthmod 1
  171. voicingswitch d
  172. IF nextPh(isPause2) THEN
  173. WAV(ustop/t_dnt, 40)
  174. ENDIF
  175. WAV(ustop/t_dnt, 50)
  176. endphoneme
  177. phoneme p
  178. vls blb stp
  179. lengthmod 2
  180. voicingswitch b
  181. Vowelin f1=0 f2=1000 -50 -100 f3=-200 80
  182. Vowelout f1=0 f2=1000 -500 -350 f3=-300 80 rms=30
  183. IF nextPh(isPause2) THEN
  184. WAV(ustop/p_unasp_, 80)
  185. ENDIF
  186. IF nextPh(l) THEN
  187. WAV(ustop/pl)
  188. ENDIF
  189. WAV(ustop/p_unasp, 120)
  190. endphoneme
  191. phoneme k
  192. vls vel stp
  193. lengthmod 2
  194. voicingswitch g
  195. Vowelin f1=0 f2=2300 200 400 f3=-100 80
  196. Vowelout f1=0 f2=2300 300 400 f3=-100 80 rms=20
  197. IF nextPh(isPause2) THEN
  198. WAV(ustop/k_)
  199. ENDIF
  200. IF nextPh(#i) OR nextPh(l^) THEN
  201. WAV(ustop/ki)
  202. ENDIF
  203. IF nextPh(l) THEN
  204. WAV(ustop/kl)
  205. ENDIF
  206. WAV(ustop/k_unasp, 60) // weaker
  207. endphoneme
  208. phoneme c
  209. vls pal stp pzd
  210. voicingswitch J
  211. WAV(ustop/c, 80)
  212. endphoneme
  213. phoneme D // louder and shorter version of d
  214. vcd alv stp
  215. voicingswitch t
  216. length 10
  217. lengthmod 5
  218. Vowelin f1=1 f2=1700 -300 300 f3=-100 80
  219. Vowelout f1=2 f2=1700 -300 300 f3=-100 80 brk
  220. IF PreVoicing THEN
  221. FMT(d/xd, 110)
  222. ENDIF
  223. IF nextPh(isPause2) THEN
  224. FMT(d/d_, 120) addWav(x/d_,110)
  225. ENDIF
  226. FMT(d/d, 110) addWav(x/d,110)
  227. endphoneme
  228. phoneme z` // Shortened version of z for diphthong dz
  229. vcd alv frc sib
  230. voicingswitch s
  231. length 10
  232. lengthmod 6
  233. Vowelout f1=0 f2=1700 -300 300 f3=-100 60 len=50
  234. IF KlattSynth THEN
  235. Vowelin f1=0 f2=1390 -300 300 f3=0 0
  236. Vowelout f1=1 f2=1390 -300 300 f3=-100 60 len=50 brk
  237. ENDIF
  238. IF nextPh(isPause2) THEN
  239. length 20
  240. FMT(voc/z_, 120) addWav(ufric/s_, 95)
  241. ENDIF
  242. FMT(voc/z, 110) addWav(ufric/s_, 100)
  243. endphoneme
  244. phoneme Z` // Shortened version of Z for diphthong dZ
  245. vcd pla frc sib
  246. voicingswitch S
  247. length 30
  248. lengthmod 6
  249. Vowelin f1=0 f2=2000 0 300 f3=-200 80
  250. Vowelout f1=2 f2=2000 0 300 f3=-200 80 brk
  251. IF KlattSynth THEN
  252. IF nextPh(isPause2) THEN
  253. FMT(klatt/zh_, 70) addWav(vocw/zh, 70)
  254. ENDIF
  255. FMT(klatt/zh) addWav(vocw/zh, 130)
  256. ENDIF
  257. IF nextPh(isPause2) THEN
  258. FMT(voc/zh_, 80) addWav(vocw/zh, 70)
  259. ENDIF
  260. FMT(voc/zh) addWav(vocw/zh, 130)
  261. endphoneme
  262. phoneme > // lengthen previous vowel less than using ":"
  263. virtual
  264. length 20 // it actually seems working shorter, but anyway...
  265. endphoneme
  266. phoneme } // Tiny, 5ms non-linked pause (used between phonemes in word)
  267. pause
  268. // starttype _ endtype _
  269. // lengthmod 1
  270. nolink
  271. length 5
  272. endphoneme
  273. // TODO should use this with correct lengthening
  274. //phoneme l
  275. // liquid
  276. // unstressed
  277. // dnt
  278. // length 150
  279. // FMT(vwl_hi/l-voc)
  280. //endphoneme
  281. phoneme s
  282. vls alv frc sib
  283. voicingswitch z
  284. lengthmod 3
  285. Vowelin f1=0 f2=1700 -300 300 f3=-100 80
  286. Vowelout f1=0 f2=1700 -300 250 f3=-100 80 rms=20
  287. WAV(ufric/s,60)
  288. endphoneme