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_hindi 7.7KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517
  1. //====================================================
  2. // Hindi
  3. //====================================================
  4. phoneme : // Lengthen the previous vowel by "length"
  5. virtual
  6. length 100
  7. endphoneme
  8. phoneme @
  9. vowel flag1 starttype #@ endtype #@
  10. length 130
  11. ChangeIfDiminished(@-)
  12. IF nextPh(H) THEN
  13. FMT(vowel/@_low)
  14. ENDIF
  15. FMT(vowel/@_bck)
  16. endphoneme
  17. phoneme V
  18. vowel flag1 starttype #@ endtype #@
  19. length 130
  20. IF thisPh(isNotStressed) THEN
  21. IF prevPh(H) THEN
  22. ChangePhoneme(@)
  23. ENDIF
  24. IF thisPh(isWordEnd) THEN
  25. ChangePhoneme(NULL)
  26. ENDIF
  27. IF nextVowel(isFlag1) THEN
  28. ELSE
  29. IF thisPh(isSeqFlag1) THEN
  30. // delete the last inherent vowel of a sequence
  31. ChangePhoneme(NULL)
  32. ELSE
  33. IF thisPh(isFirstVowel) THEN
  34. ELSE
  35. // delete if not the first vowel, and is an isolated 'a'
  36. ChangePhoneme(NULL)
  37. ENDIF
  38. ENDIF
  39. ENDIF
  40. ENDIF
  41. IF prevPh(isPalatal) THEN
  42. ChangePhoneme(@3)
  43. ELSEIF prevPh(r) THEN
  44. ChangePhoneme(@2)
  45. ELSE
  46. IF thisPh(isNotStressed) THEN
  47. ChangePhoneme(@)
  48. ENDIF
  49. IF nextPh(H) THEN
  50. FMT(vowel/@_low)
  51. ENDIF
  52. ENDIF
  53. FMT(vowel/V_3)
  54. endphoneme
  55. phoneme @2
  56. vowel flag1 starttype #@ endtype #@
  57. length 130
  58. FMT(vowel/@_low)
  59. endphoneme
  60. phoneme @3
  61. vowel flag1 starttype #@ endtype #@
  62. length 130
  63. ChangeIfDiminished(@-)
  64. FMT(vowel/@_3)
  65. endphoneme
  66. phoneme i:
  67. vowel long starttype #i endtype #i
  68. length 230
  69. IfNextVowelAppend(;)
  70. FMT(vowel/i_fnt)
  71. endphoneme
  72. phoneme i // as [i:] but not marked as 'long'
  73. vowel starttype #i endtype #i
  74. length 230
  75. IfNextVowelAppend(;)
  76. FMT(vowel/i_6)
  77. endphoneme
  78. phoneme I
  79. vowel starttype #i endtype #i
  80. length 100
  81. IfNextVowelAppend(;)
  82. FMT(vowel/ii_3)
  83. endphoneme
  84. phoneme e:
  85. vowel long starttype #e endtype #e
  86. length 220
  87. FMT(vowel/e_2)
  88. endphoneme
  89. phoneme e
  90. vowel starttype #e endtype #e
  91. length 130
  92. FMT(vowel/e_2)
  93. endphoneme
  94. phoneme E:
  95. vowel long starttype #e endtype #e
  96. length 220
  97. FMT(vdiph/ee-e)
  98. endphoneme
  99. phoneme E
  100. vowel starttype #e endtype #e
  101. length 130
  102. FMT(vowel/e_mid)
  103. endphoneme
  104. phoneme &:
  105. vowel long starttype #a endtype #a
  106. length 220
  107. FMT(vowel/&)
  108. endphoneme
  109. phoneme a:
  110. vowel long starttype #a endtype #a
  111. length 230
  112. FMT(vowel/aa_9)
  113. endphoneme
  114. phoneme a
  115. vowel long starttype #a endtype #a
  116. length 130
  117. FMT(vowel/a#_3)
  118. endphoneme
  119. phoneme o:
  120. vowel long starttype #o endtype #o
  121. length 220
  122. FMT(vowel/o_2)
  123. endphoneme
  124. phoneme o
  125. vowel starttype #o endtype #o
  126. length 130
  127. FMT(vowel/o)
  128. endphoneme
  129. phoneme O:
  130. vowel long starttype #o endtype #o
  131. length 210
  132. FMT(vowel/oo_4)
  133. endphoneme
  134. phoneme O
  135. vowel starttype #o endtype #o
  136. length 130
  137. FMT(vowel/0)
  138. endphoneme
  139. phoneme U
  140. vowel starttype #u endtype #u
  141. length 120
  142. FMT(vowel/uu_bck)
  143. endphoneme
  144. phoneme u:
  145. vowel long starttype #u endtype #u
  146. length 230
  147. FMT(vowel/u_bck)
  148. endphoneme
  149. // Nasal vowels
  150. //=============
  151. phoneme i~
  152. vowel long starttype #i endtype #i
  153. length 220
  154. FMT(vnasal/i_n2)
  155. endphoneme
  156. phoneme I~
  157. vowel long starttype #i endtype #i
  158. length 170
  159. FMT(vnasal/ii_n)
  160. endphoneme
  161. phoneme e~
  162. vowel long starttype #e endtype #e
  163. length 220
  164. FMT(vnasal/e_n)
  165. endphoneme
  166. phoneme E~
  167. vowel long starttype #e endtype #e
  168. length 230
  169. FMT(vnasal/ee_n2)
  170. endphoneme
  171. phoneme a~
  172. vowel long starttype #a endtype #a
  173. length 250
  174. FMT(vnasal/aa_n)
  175. endphoneme
  176. phoneme V~
  177. vowel long starttype #@ endtype #@
  178. length 250
  179. FMT(vnasal/V_n)
  180. endphoneme
  181. phoneme O~
  182. vowel long starttype #o endtype #o
  183. length 230
  184. FMT(vnasal/oo_n2)
  185. endphoneme
  186. phoneme o~
  187. vowel long starttype #o endtype #o
  188. length 220
  189. FMT(vnasal/o_n)
  190. endphoneme
  191. phoneme U~
  192. vowel starttype #u endtype #u
  193. length 170
  194. FMT(vnasal/u_n)
  195. endphoneme
  196. phoneme u~
  197. vowel long starttype #u endtype #u
  198. length 230
  199. FMT(vnasal/u_n)
  200. endphoneme
  201. // Diphthongs
  202. //===========
  203. phoneme aI
  204. vowel long starttype #@ endtype #i
  205. length 240
  206. long
  207. FMT(vdiph/&i)
  208. endphoneme
  209. phoneme aU
  210. vowel long starttype #a endtype #u
  211. length 240
  212. long
  213. FMT(vdiph/aau_3)
  214. endphoneme
  215. // CONSONANTS
  216. //===========
  217. phoneme v // approximant, not fricative
  218. import_phoneme base/v#
  219. voicingswitch f
  220. endphoneme
  221. phoneme H // use for full "h"
  222. import_phoneme base/h
  223. endphoneme
  224. // bilabial plosives
  225. //==================
  226. phoneme p
  227. import_phoneme consonants/p-
  228. endphoneme
  229. phoneme ph
  230. import_phoneme consonants/ph
  231. endphoneme
  232. phoneme b // this is [b]
  233. import_phoneme base/b
  234. endphoneme
  235. phoneme bh
  236. vcd blb stop
  237. lengthmod 5
  238. voicingswitch ph
  239. Vowelin f1=0 f2=1000 -50 -100 f3=-200 80
  240. Vowelout f1=0 f2=1000 -500 -350 f3=-300 80 rms=30
  241. IF PreVoicing THEN
  242. FMT(b/xb)
  243. ENDIF
  244. FMT( b/b@2) addWav(ustop/p_asp, 70)
  245. endphoneme
  246. // dental plosives
  247. //==================
  248. phoneme t // dental variant of /t/
  249. import_phoneme base/t[
  250. voicingswitch d
  251. endphoneme
  252. phoneme th // dental variant of /t/
  253. vls dnt stop
  254. lengthmod 2
  255. voicingswitch d
  256. Vowelin f1=0 f2=1500 -300 300 f3=-100 80 amp=16
  257. Vowelout f1=0 f2=1500 -300 250 f3=-100 80 rms=20
  258. IF nextPh(isPause2) THEN
  259. WAV(ustop/t_dnt, 35)
  260. ENDIF
  261. WAV(ustop/t_dnt, 50)
  262. endphoneme
  263. phoneme d // dental variant of /d/
  264. import_phoneme base/d[
  265. voicingswitch t
  266. endphoneme
  267. phoneme dh
  268. vcd dnt stop
  269. lengthmod 5
  270. voicingswitch th
  271. Vowelin f1=0 f2=1500 -300 300 f3=-100 80
  272. Vowelout f1=0 f2=1500 -300 250 f3=-100 80 rms=20
  273. IF PreVoicing THEN
  274. FMT(d/xd)
  275. ENDIF
  276. FMT(d/xd3) addWav(ustop/t_dnt, 40)
  277. endphoneme
  278. // retroflex plosives
  279. //===================
  280. phoneme t.
  281. vls rfx stop
  282. lengthmod 2
  283. ipa ʈ
  284. voicingswitch d.
  285. Vowelin f1=0 f2=1800 -300 300 f3=-400 80
  286. Vowelout f1=0 f2=1800 -300 250 f3=-400 80 rms=20 colr=2
  287. WAV(ustop/t_short)
  288. endphoneme
  289. phoneme th.
  290. vls rfx stop
  291. lengthmod 2
  292. ipa ʈh
  293. voicingswitch dh.
  294. Vowelin f1=0 f2=1800 -300 300 f3=-400 80
  295. Vowelout f1=0 f2=1800 -300 250 f3=-400 80 rms=20 colr=2
  296. // WAV(ustop/th_rfx)
  297. WAV(ustop/t)
  298. endphoneme
  299. phoneme d.
  300. vcd rfx stop
  301. lengthmod 5
  302. voicingswitch t.
  303. ipa ɖ
  304. Vowelin f1=1 f2=1800 -300 300 f3=-400 80
  305. Vowelout f1=1 f2=1800 -300 300 f3=-400 80 colr=2
  306. IF PreVoicing THEN
  307. FMT(d/xdr)
  308. ENDIF
  309. IF nextPh(isPause2) THEN
  310. FMT(d/d_) addWav(x/d_)
  311. ENDIF
  312. FMT(d/dr) addWav(x/d)
  313. endphoneme
  314. phoneme dh.
  315. vcd rfx stop
  316. lengthmod 5
  317. ipa ɖh
  318. voicingswitch th.
  319. Vowelin f1=1 f2=1800 -300 300 f3=-400 80
  320. Vowelout f1=1 f2=1800 -300 300 f3=-400 80 colr=2
  321. IF PreVoicing THEN
  322. FMT(d/xdr)
  323. ENDIF
  324. FMT(d/dr) addWav(ustop/t)
  325. // FMT(d/dr) addWav(ustop/th_rfx)
  326. endphoneme
  327. // palatal plosives
  328. //=================
  329. // also try [tS] and [dZ]
  330. phoneme c
  331. import_phoneme base/c
  332. endphoneme
  333. phoneme ch
  334. CALL base/tS;
  335. ipa ch
  336. endphoneme
  337. phoneme J
  338. import_phoneme base/J
  339. endphoneme
  340. phoneme Jh
  341. vcd pal afr sibilant
  342. lengthmod 5
  343. voicingswitch ch
  344. Vowelin f1=0 f2=2700 400 600 f3=300 80 rate len=70
  345. Vowelout f1=0 f2=2700 400 600 f3=300 80 colr=1
  346. IF PreVoicing THEN
  347. FMT(dzh/xdz_pzd)
  348. ENDIF
  349. FMT(dzh/xdz_pzd) addWav(ustop/ts_pzd)
  350. endphoneme
  351. // velar plosives
  352. //==================
  353. phoneme k
  354. import_phoneme consonants/k-
  355. voicingswitch g
  356. endphoneme
  357. phoneme kh
  358. import_phoneme consonants/kh
  359. voicingswitch gh
  360. endphoneme
  361. phoneme g
  362. import_phoneme base/g
  363. voicingswitch k
  364. endphoneme
  365. phoneme gh
  366. vcd dnt stop
  367. lengthmod 5
  368. voicingswitch kh
  369. Vowelin f1=1 f2=2300 200 300 f3=-150 80 rms=20
  370. Vowelout f1=0 f2=2300 300 400 f3=-150 80 rms=20
  371. IF PreVoicing THEN
  372. FMT(g2/xg)
  373. ENDIF
  374. IF nextPh(isPause2) THEN
  375. FMT(g2/xg) addWav(ustop/k_asp, 35)
  376. ENDIF
  377. FMT(g2/xg) addWav(ustop/k_asp, 50)
  378. endphoneme
  379. //================
  380. phoneme #X2 // click, use for indicating combining long vowels
  381. vls alv frc sibilant
  382. lengthmod 3
  383. WAV(ustop/percus02, 60)
  384. endphoneme