Option "language <name>"already causes SelectTranslator(<name>) to be called. Having two options to do almost the same thing is unnecessary and confusing. In the long term, all options from SelectTranslator() should have a switch case in LoadVoice() so they are user configurable (see #218). If needed, a new option (maybe called "LoadOptions") could be added to load an existing voice or language file. Changes language configuration files for: hak, cmn, yue, ltg, ms, mb-ma1. No changes to users.master
 Juho Hiltunen
					
					4 years ago
						Juho Hiltunen
					
					4 years ago
				| language ltg | language ltg | ||||
| maintainer Valdis Vitolins <valdis.vitolins@odo.lv> | maintainer Valdis Vitolins <valdis.vitolins@odo.lv> | ||||
| status testing | status testing | ||||
| translator lv // Reuse pronunciation rules from Latvian | |||||
| phonemes lv | phonemes lv | ||||
| dictionary lv | dictionary lv | ||||
| dictrules 2 // Setting for Latgalian pronunciation | dictrules 2 // Setting for Latgalian pronunciation | 
| language ms | language ms | ||||
| phonemes id | phonemes id | ||||
| translator id | |||||
| stressLength 160 200 180 180 0 0 220 240 | stressLength 160 200 180 180 0 0 220 240 | ||||
| stressAmp 16 18 18 18 0 0 22 21 | stressAmp 16 18 18 18 0 0 22 21 | ||||
| intonation 3 // Less intonation, and comma does not raise the pitch. | intonation 3 // Less intonation, and comma does not raise the pitch. | 
| language zh-cmn | language zh-cmn | ||||
| language zh | language zh | ||||
| translator zh | |||||
| phonemes zh | phonemes zh | ||||
| dictionary zh | dictionary zh | ||||
| words 1 | words 1 | 
| language hak | language hak | ||||
| maintainer Chen Chien-ting <yoxem.tem98@nctu.edu.tw> | maintainer Chen Chien-ting <yoxem.tem98@nctu.edu.tw> | ||||
| status testing | status testing | ||||
| translator hak | |||||
| phonemes hak | phonemes hak | ||||
| dictionary hak | dictionary hak | 
| language zh-yue | language zh-yue | ||||
| language zh 8 | language zh 8 | ||||
| translator zhy | |||||
| phonemes zhy | phonemes zhy | ||||
| dictionary zhy | dictionary zhy | ||||
| gender female | gender female | ||||
| pitch 140 260 | pitch 140 260 | ||||
| phonemes id | phonemes id | ||||
| translator id | |||||
| mbrola ma1 ma1_phtrans | mbrola ma1 ma1_phtrans | ||||
| } | } | ||||
| break; | break; | ||||
| case L('l', 'v'): // latvian | case L('l', 'v'): // latvian | ||||
| case L3('l', 't', 'g'): // latgalian | |||||
| { | { | ||||
| static const unsigned char stress_amps_lv[8] = { 14, 10, 10, 8, 0, 0, 20, 15 }; | static const unsigned char stress_amps_lv[8] = { 14, 10, 10, 8, 0, 0, 20, 15 }; | ||||
| static const short stress_lengths_lv[8] = { 180, 180, 180, 160, 0, 0, 230, 180 }; | static const short stress_lengths_lv[8] = { 180, 180, 180, 160, 0, 0, 230, 180 }; | 
| V_NAME = 1, | V_NAME = 1, | ||||
| V_LANGUAGE, | V_LANGUAGE, | ||||
| V_GENDER, | V_GENDER, | ||||
| V_TRANSLATOR, | |||||
| V_PHONEMES, | V_PHONEMES, | ||||
| V_DICTIONARY, | V_DICTIONARY, | ||||
| V_VARIANTS, | V_VARIANTS, | ||||
| { "formant", V_FORMANT }, | { "formant", V_FORMANT }, | ||||
| { "pitch", V_PITCH }, | { "pitch", V_PITCH }, | ||||
| { "phonemes", V_PHONEMES }, | { "phonemes", V_PHONEMES }, | ||||
| { "translator", V_TRANSLATOR }, | |||||
| { "dictionary", V_DICTIONARY }, | { "dictionary", V_DICTIONARY }, | ||||
| { "stressLength", V_STRESSLENGTH }, | { "stressLength", V_STRESSLENGTH }, | ||||
| { "stressAmp", V_STRESSAMP }, | { "stressAmp", V_STRESSAMP }, | ||||
| current_voice_selected.age = age; | current_voice_selected.age = age; | ||||
| } | } | ||||
| break; | break; | ||||
| case V_TRANSLATOR: | |||||
| if (tone_only) break; | |||||
| sscanf(p, "%s", translator_name); | |||||
| if (new_translator != NULL) | |||||
| DeleteTranslator(new_translator); | |||||
| new_translator = SelectTranslator(translator_name); | |||||
| langopts = &new_translator->langopts; | |||||
| break; | |||||
| case V_DICTIONARY: // dictionary | case V_DICTIONARY: // dictionary | ||||
| sscanf(p, "%s", new_dictionary); | sscanf(p, "%s", new_dictionary); | ||||
| break; | break; |