mirror of
https://github.com/rhasspy/espeak-ng.git
synced 2026-10-31 05:35:35 +00:00
1.46.18 (from espeak.sourceforge.net/test/latest.html)
This commit is contained in:
+12
-1
@@ -1,4 +1,4 @@
|
||||
|
||||
|
||||
// This file is UTF8 encoded
|
||||
// Punjabi/Gurmukhi
|
||||
|
||||
@@ -130,6 +130,8 @@ _dpt _dOth // ??
|
||||
ੱ VddVk
|
||||
ਃ visaRg
|
||||
੍ hVlVnt
|
||||
ॄ addak
|
||||
|
||||
|
||||
ਅ 'ERV
|
||||
ੲ 'IRI
|
||||
@@ -155,6 +157,15 @@ _ਔ 'ERV||kVnOR'a
|
||||
ੌ kVn'ORa
|
||||
|
||||
। d.'Vnd.i
|
||||
₹ rupi
|
||||
|
||||
|
||||
ਸਰਕਾਰ sR@k'aR
|
||||
ਸਰਕਾਰੀ sR@k'aRi
|
||||
|
||||
|
||||
// English words
|
||||
ਸੋਫਟਵਿਅਰ s'OftwER
|
||||
ਵੈਬਪੇਜ w'EbpeIdZ
|
||||
ਈਮੇਲ 'i:meIl
|
||||
ਕੀਬੋਰਡ k'i:boRd
|
||||
|
||||
+24
-32
@@ -28,12 +28,6 @@
|
||||
#include <stdio.h>
|
||||
#include <stddef.h>
|
||||
|
||||
#ifdef __WIN32__
|
||||
#define ESPEAK_API __declspec(dllexport)
|
||||
#else
|
||||
#define ESPEAK_API
|
||||
#endif
|
||||
|
||||
#define ESPEAK_API_REVISION 6
|
||||
/*
|
||||
Revision 2
|
||||
@@ -163,13 +157,11 @@ typedef enum {
|
||||
EE_NOT_FOUND=2
|
||||
} espeak_ERROR;
|
||||
|
||||
#define espeakINITIALIZE_PHONEME_EVENTS 0x0001
|
||||
#define espeakINITIALIZE_DONT_EXIT 0x8000
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
ESPEAK_API int espeak_Initialize(espeak_AUDIO_OUTPUT output, int buflength, const char *path, int options);
|
||||
int espeak_Initialize(espeak_AUDIO_OUTPUT output, int buflength, const char *path, int options);
|
||||
/* Must be called before any synthesis functions are called.
|
||||
output: the audio data can either be played by eSpeak or passed back by the SynthCallback function.
|
||||
|
||||
@@ -177,8 +169,8 @@ ESPEAK_API int espeak_Initialize(espeak_AUDIO_OUTPUT output, int buflength, cons
|
||||
|
||||
path: The directory which contains the espeak-data directory, or NULL for the default location.
|
||||
|
||||
options: bit 0: 1=allow espeakEVENT_PHONEME events.
|
||||
bit 15: 1=don't exit if espeak_data is not found (used for --help)
|
||||
options: bit 0: 1=allow espeakEVENT_PHONEME events.
|
||||
|
||||
|
||||
Returns: sample rate in Hz, or -1 (EE_INTERNAL_ERROR).
|
||||
*/
|
||||
@@ -188,7 +180,7 @@ typedef int (t_espeak_callback)(short*, int, espeak_EVENT*);
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
ESPEAK_API void espeak_SetSynthCallback(t_espeak_callback* SynthCallback);
|
||||
void espeak_SetSynthCallback(t_espeak_callback* SynthCallback);
|
||||
/* Must be called before any synthesis functions are called.
|
||||
This specifies a function in the calling program which is called when a buffer of
|
||||
speech sound data has been produced.
|
||||
@@ -216,7 +208,7 @@ int SynthCallback(short *wav, int numsamples, espeak_EVENT *events);
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
ESPEAK_API void espeak_SetUriCallback(int (*UriCallback)(int, const char*, const char*));
|
||||
void espeak_SetUriCallback(int (*UriCallback)(int, const char*, const char*));
|
||||
/* This function may be called before synthesis functions are used, in order to deal with
|
||||
<audio> tags. It specifies a callback function which is called when an <audio> element is
|
||||
encountered and allows the calling program to indicate whether the sound file which
|
||||
@@ -257,7 +249,7 @@ int UriCallback(int type, const char *uri, const char *base);
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
ESPEAK_API espeak_ERROR espeak_Synth(const void *text,
|
||||
espeak_ERROR espeak_Synth(const void *text,
|
||||
size_t size,
|
||||
unsigned int position,
|
||||
espeak_POSITION_TYPE position_type,
|
||||
@@ -313,7 +305,7 @@ ESPEAK_API espeak_ERROR espeak_Synth(const void *text,
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
ESPEAK_API espeak_ERROR espeak_Synth_Mark(const void *text,
|
||||
espeak_ERROR espeak_Synth_Mark(const void *text,
|
||||
size_t size,
|
||||
const char *index_mark,
|
||||
unsigned int end_position,
|
||||
@@ -337,7 +329,7 @@ ESPEAK_API espeak_ERROR espeak_Synth_Mark(const void *text,
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
ESPEAK_API espeak_ERROR espeak_Key(const char *key_name);
|
||||
espeak_ERROR espeak_Key(const char *key_name);
|
||||
/* Speak the name of a keyboard key.
|
||||
If key_name is a single character, it speaks the name of the character.
|
||||
Otherwise, it speaks key_name as a text string.
|
||||
@@ -351,7 +343,7 @@ ESPEAK_API espeak_ERROR espeak_Key(const char *key_name);
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
ESPEAK_API espeak_ERROR espeak_Char(wchar_t character);
|
||||
espeak_ERROR espeak_Char(wchar_t character);
|
||||
/* Speak the name of the given character
|
||||
|
||||
Return: EE_OK: operation achieved
|
||||
@@ -396,7 +388,7 @@ typedef enum {
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
ESPEAK_API espeak_ERROR espeak_SetParameter(espeak_PARAMETER parameter, int value, int relative);
|
||||
espeak_ERROR espeak_SetParameter(espeak_PARAMETER parameter, int value, int relative);
|
||||
/* Sets the value of the specified parameter.
|
||||
relative=0 Sets the absolute value of the parameter.
|
||||
relative=1 Sets a relative value of the parameter.
|
||||
@@ -433,7 +425,7 @@ ESPEAK_API espeak_ERROR espeak_SetParameter(espeak_PARAMETER parameter, int valu
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
ESPEAK_API int espeak_GetParameter(espeak_PARAMETER parameter, int current);
|
||||
int espeak_GetParameter(espeak_PARAMETER parameter, int current);
|
||||
/* current=0 Returns the default value of the specified parameter.
|
||||
current=1 Returns the current value of the specified parameter, as set by SetParameter()
|
||||
*/
|
||||
@@ -441,7 +433,7 @@ ESPEAK_API int espeak_GetParameter(espeak_PARAMETER parameter, int current);
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
ESPEAK_API espeak_ERROR espeak_SetPunctuationList(const wchar_t *punctlist);
|
||||
espeak_ERROR espeak_SetPunctuationList(const wchar_t *punctlist);
|
||||
/* Specified a list of punctuation characters whose names are to be spoken when the
|
||||
value of the Punctuation parameter is set to "some".
|
||||
|
||||
@@ -456,7 +448,7 @@ ESPEAK_API espeak_ERROR espeak_SetPunctuationList(const wchar_t *punctlist);
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
ESPEAK_API void espeak_SetPhonemeTrace(int value, FILE *stream);
|
||||
void espeak_SetPhonemeTrace(int value, FILE *stream);
|
||||
/* Controls the output of phoneme symbols for the text
|
||||
value=0 No phoneme output (default)
|
||||
value=1 Output the translated phoneme symbols for the text
|
||||
@@ -469,7 +461,7 @@ ESPEAK_API void espeak_SetPhonemeTrace(int value, FILE *stream);
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
ESPEAK_API void espeak_CompileDictionary(const char *path, FILE *log, int flags);
|
||||
void espeak_CompileDictionary(const char *path, FILE *log, int flags);
|
||||
/* Compile pronunciation dictionary for a language which corresponds to the currently
|
||||
selected voice. The required voice should be selected before calling this function.
|
||||
|
||||
@@ -522,7 +514,7 @@ typedef struct {
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
ESPEAK_API const espeak_VOICE **espeak_ListVoices(espeak_VOICE *voice_spec);
|
||||
const espeak_VOICE **espeak_ListVoices(espeak_VOICE *voice_spec);
|
||||
/* Reads the voice files from espeak-data/voices and creates an array of espeak_VOICE pointers.
|
||||
The list is terminated by a NULL pointer
|
||||
|
||||
@@ -534,7 +526,7 @@ ESPEAK_API const espeak_VOICE **espeak_ListVoices(espeak_VOICE *voice_spec);
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
ESPEAK_API espeak_ERROR espeak_SetVoiceByName(const char *name);
|
||||
espeak_ERROR espeak_SetVoiceByName(const char *name);
|
||||
/* Searches for a voice with a matching "name" field. Language is not considered.
|
||||
"name" is a UTF8 string.
|
||||
|
||||
@@ -547,7 +539,7 @@ ESPEAK_API espeak_ERROR espeak_SetVoiceByName(const char *name);
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
ESPEAK_API espeak_ERROR espeak_SetVoiceByProperties(espeak_VOICE *voice_spec);
|
||||
espeak_ERROR espeak_SetVoiceByProperties(espeak_VOICE *voice_spec);
|
||||
/* An espeak_VOICE structure is used to pass criteria to select a voice. Any of the following
|
||||
fields may be set:
|
||||
|
||||
@@ -567,7 +559,7 @@ ESPEAK_API espeak_ERROR espeak_SetVoiceByProperties(espeak_VOICE *voice_spec);
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
ESPEAK_API espeak_VOICE *espeak_GetCurrentVoice(void);
|
||||
espeak_VOICE *espeak_GetCurrentVoice(void);
|
||||
/* Returns the espeak_VOICE data for the currently selected voice.
|
||||
This is not affected by temporary voice changes caused by SSML elements such as <voice> and <s>
|
||||
*/
|
||||
@@ -575,7 +567,7 @@ ESPEAK_API espeak_VOICE *espeak_GetCurrentVoice(void);
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
ESPEAK_API espeak_ERROR espeak_Cancel(void);
|
||||
espeak_ERROR espeak_Cancel(void);
|
||||
/* Stop immediately synthesis and audio output of the current text. When this
|
||||
function returns, the audio output is fully stopped and the synthesizer is ready to
|
||||
synthesize a new message.
|
||||
@@ -588,14 +580,14 @@ ESPEAK_API espeak_ERROR espeak_Cancel(void);
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
ESPEAK_API int espeak_IsPlaying(void);
|
||||
int espeak_IsPlaying(void);
|
||||
/* Returns 1 if audio is played, 0 otherwise.
|
||||
*/
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
ESPEAK_API espeak_ERROR espeak_Synchronize(void);
|
||||
espeak_ERROR espeak_Synchronize(void);
|
||||
/* This function returns when all data have been spoken.
|
||||
Return: EE_OK: operation achieved
|
||||
EE_INTERNAL_ERROR.
|
||||
@@ -604,7 +596,7 @@ ESPEAK_API espeak_ERROR espeak_Synchronize(void);
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
ESPEAK_API espeak_ERROR espeak_Terminate(void);
|
||||
espeak_ERROR espeak_Terminate(void);
|
||||
/* last function to be called.
|
||||
Return: EE_OK: operation achieved
|
||||
EE_INTERNAL_ERROR.
|
||||
@@ -614,8 +606,8 @@ ESPEAK_API espeak_ERROR espeak_Terminate(void);
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
ESPEAK_API const char *espeak_Info(const char **path_data);
|
||||
const char *espeak_Info(void* ptr);
|
||||
/* Returns the version number string.
|
||||
path_data returns the path to espeak_data
|
||||
The parameter is for future use, and should be set to NULL
|
||||
*/
|
||||
#endif
|
||||
|
||||
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,198 @@
|
||||
// Irish Phonemes
|
||||
// written by Ronan McGuirk
|
||||
// April 2012 version 0.3
|
||||
|
||||
//====================================================
|
||||
//====================================================
|
||||
|
||||
|
||||
phoneme a
|
||||
vowel starttype #a endtype #a
|
||||
length 180
|
||||
FMT(vowel/a_4)
|
||||
endphoneme
|
||||
|
||||
phoneme E
|
||||
vowel starttype #e endtype #e
|
||||
length 140
|
||||
FMT(vowel/ee_5)
|
||||
endphoneme
|
||||
|
||||
phoneme I
|
||||
vowel starttype #i endtype #i
|
||||
length 110
|
||||
IfNextVowelAppend(;)
|
||||
FMT(vowel/ii_2)
|
||||
endphoneme
|
||||
phoneme i // optional variant of [I] for end of words
|
||||
vowel starttype #i endtype #i
|
||||
ipa ?
|
||||
length 80
|
||||
FMT(vowel/ii_7)
|
||||
endphoneme
|
||||
|
||||
|
||||
|
||||
phoneme O
|
||||
vowel starttype #o endtype #o
|
||||
length 190
|
||||
FMT(vowel/oo)
|
||||
endphoneme
|
||||
|
||||
phoneme U
|
||||
vowel starttype #u endtype #u
|
||||
length 180
|
||||
FMT(vowel/u_bck2)
|
||||
endphoneme
|
||||
|
||||
phoneme 0
|
||||
vowel starttype #a endtype #a
|
||||
length 180
|
||||
ipa ??
|
||||
ChangeIfDiminished(@)
|
||||
FMT(vowel/aa_8)
|
||||
endphoneme
|
||||
|
||||
phoneme A:
|
||||
vowel starttype #a endtype #a
|
||||
length 200
|
||||
FMT(vowel/aa_2)
|
||||
endphoneme
|
||||
|
||||
phoneme A1:
|
||||
vowel starttype #a endtype #@
|
||||
length 200
|
||||
FMT(vowel/aa_2)
|
||||
endphoneme
|
||||
|
||||
phoneme A0:
|
||||
vowel starttype #a endtype #o
|
||||
length 200
|
||||
FMT(vowel/aa_2)
|
||||
endphoneme
|
||||
phoneme 0A:
|
||||
vowel starttype #o endtype #a
|
||||
length 200
|
||||
FMT(vowel/aa_2)
|
||||
endphoneme
|
||||
phoneme A9:
|
||||
vowel starttype #@ endtype #a
|
||||
length 200
|
||||
FMT(vowel/aa_2)
|
||||
endphoneme
|
||||
|
||||
|
||||
phoneme e:
|
||||
vowel starttype #e endtype #e
|
||||
length 210
|
||||
FMT(vowel/e)
|
||||
endphoneme
|
||||
phoneme i:
|
||||
vowel starttype #i endtype #i
|
||||
length 210
|
||||
FMT(vowel/i)
|
||||
endphoneme
|
||||
|
||||
|
||||
|
||||
phoneme o:
|
||||
vowel starttype #o endtype #o
|
||||
length 190
|
||||
FMT(vowel/o)
|
||||
endphoneme
|
||||
|
||||
phoneme o2
|
||||
vowel starttype #o endtype #@
|
||||
length 190
|
||||
FMT(vowel/o)
|
||||
endphoneme
|
||||
phoneme o3
|
||||
vowel starttype #o endtype #a
|
||||
length 190
|
||||
FMT(vowel/o)
|
||||
endphoneme
|
||||
|
||||
phoneme u:
|
||||
vowel starttype #u endtype #u
|
||||
length 210
|
||||
FMT(vowel/u)
|
||||
endphoneme
|
||||
|
||||
phoneme @ // Schwa, but always unstressed
|
||||
vowel starttype #@ endtype #@
|
||||
unstressed
|
||||
length 100
|
||||
IF nextPh(i:) THEN
|
||||
Length 50
|
||||
FMT(vwl_af/r@)
|
||||
ENDIF
|
||||
IF nextPh(e:) THEN
|
||||
Length 50
|
||||
FMT(vwl_af/r@)
|
||||
ENDIF
|
||||
FMT(vwl_af/@)
|
||||
endphoneme
|
||||
|
||||
phoneme V
|
||||
vowel starttype #a endtype #@
|
||||
length 140
|
||||
ChangeIfDiminished(@)
|
||||
FMT(vowel/V_4)
|
||||
endphoneme
|
||||
|
||||
phoneme d[
|
||||
vcd dnt stop
|
||||
voicingswitch t[
|
||||
lengthmod 5
|
||||
Vowelin f1=2 f2=1500 -300 300 f3=-150 80
|
||||
Vowelout f1=2 f2=1500 -300 300 f3=-150 80
|
||||
|
||||
IF PreVoicing THEN
|
||||
FMT(d/xd)
|
||||
ENDIF
|
||||
|
||||
IF nextPh(isPause2) THEN
|
||||
FMT(d/d_) addWav(x/d_)
|
||||
ELIF nextPh(r) THEN
|
||||
FMT(d/dr) addWav(x/d_dnt, 100)
|
||||
ENDIF
|
||||
|
||||
FMT(d/d) addWav(x/d_dnt, 100)
|
||||
endphoneme
|
||||
|
||||
|
||||
|
||||
|
||||
phoneme t[ // dental variant of /t/
|
||||
vls dnt stop
|
||||
voicingswitch d[
|
||||
lengthmod 2
|
||||
Vowelin f1=1 f2=1500 -250 250 f3=-100 80 amp=16
|
||||
Vowelout f1=0 f2=1500 -300 250 f3=-100 80 rms=20
|
||||
|
||||
IF nextPh(isPause2) THEN
|
||||
WAV(ustop/t_dnt, 35)
|
||||
ENDIF
|
||||
WAV(ustop/t_hi, 70)
|
||||
endphoneme
|
||||
phoneme x
|
||||
vls vel frc
|
||||
voicingswitch Q
|
||||
lengthmod 1
|
||||
Vowelin f1=0 f2=2300 200 400 f3=-100 80
|
||||
Vowelout f1=0 f2=2300 300 400 f3=-100 80 rms=20
|
||||
|
||||
IF nextPh(isPause) THEN
|
||||
WAV(ufric/x, 120)
|
||||
ENDIF
|
||||
WAV(ufric/x_hr, 25)
|
||||
endphoneme
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -83,6 +83,11 @@ phoneme u
|
||||
endphoneme
|
||||
|
||||
|
||||
phoneme eI // for English words
|
||||
import_phoneme en/eI
|
||||
endphoneme
|
||||
|
||||
|
||||
// Consonants
|
||||
|
||||
phoneme v // Try English [v]
|
||||
|
||||
Reference in New Issue
Block a user