Browse Source

[1.25.15] Callback in AUDIO_OUTPUT_PLAYBACK mode gives a zero-terminated list of events.

espeak_SetSynthCallback() can be called either before or after espeak_Initialize().


git-svn-id: https://espeak.svn.sourceforge.net/svnroot/espeak/trunk@31 d46cf337-b52f-0410-862d-fd96e6ae7743
master
jonsd 18 years ago
parent
commit
97b217c26a

+ 8
- 3
dictsource/hu_list View File

_0M2 m'illio: _0M2 m'illio:
_1M2 m'illio: _1M2 m'illio:
_2M2 k'e:tm,illio: _2M2 k'e:tm,illio:
_0M3 m'illia:rd
_1M3 m'illia:rd
_1M3 k'e:tm,illia:rd
_0M3 m'illia:Rd
_1M3 m'illia:Rd
_1M3 k'e:tm,illia:Rd
_0M4 b'illio: _0M4 b'illio:
_1M4 b'illio: _1M4 b'illio:
_2M4 k'e:tb,illio: _2M4 k'e:tb,illio:
ször $u ször $u




// word pairs

(hogy az) hoJ,Az


// Verbs // Verbs


vagyok $u // to be, present vagyok $u // to be, present

+ 2
- 2
dictsource/hu_rules View File

r R r R
A) r (A * A) r (A *
C) r (A R C) r (A R
r (C r
rr R
r (C R
rr R*


.group s .group s
s S s S

+ 1
- 0
dictsource/is_rules View File

r (B r# r (B r#
r (_ r# r (_ r#
r R r R
rr R*
rl dl rl dl
rl (K rtl# rl (K rtl#
rn rdn# rn rdn#

+ 1
- 1
phsource/compile_report View File

1 w/wu base 1 w/wu base
5 w/xw base 5 w/xw base
20 x/b base hi ro is 20 x/b base hi ro is
2 x/b_ base is
1 x/b_ base
9 x/d base hi hr el is 9 x/d base hi hr el is
14 x/d_ base fi fr hi pl hr ru it ro el is sw 14 x/d_ base fi fr hi pl hr ru it ro el is sw
23 x/d_dnt base fi fr hi hu pl ru it ro sw 23 x/d_dnt base fi fr hi hu pl ru it ro sw

BIN
phsource/dzh/dz_pzd_ View File


BIN
phsource/dzh/xdz_pzd View File


+ 3
- 3
phsource/ph_icelandic View File



phoneme b phoneme b
vls blb stop vls blb stop
vowelout f1=2 f2=1000 -500 -300 f3=-300 80 brk
vowelin f1=2 f2=1000 -300 -200 f3=-200 80 rms=30
vowelin f1=1 f2=1000 -300 -200 f3=-200 80 rms=27
vowelout f1=2 f2=1000 -300 -300 f3=-300 80 brk
lengthmod 5 lengthmod 5
wave x/b wave x/b
before _ x/b_
// before _ x/b_
endphoneme endphoneme





BIN
phsource/vdiph/y#i_2 View File


+ 11
- 4
src/event.cpp View File



//> //>
//<event_init //<event_init
void event_init(t_espeak_callback* SynthCallback)
{
ENTER("event_init");


void event_set_callback(t_espeak_callback* SynthCallback)
{
my_callback = SynthCallback; my_callback = SynthCallback;
SHOW("event_init > my_callback=0x%x\n", my_callback);
}

void event_init(void)
{
ENTER("event_init");


my_event_is_running=0; my_event_is_running=0;




static unsigned int a_old_uid = 0; static unsigned int a_old_uid = 0;


espeak_EVENT events[2];
memcpy(&events[0],event,sizeof(espeak_EVENT)); // the event parameter in the callback function should be an array of eventd
events[1].type = espeakEVENT_LIST_TERMINATED; // ... terminated by an event type=0

if (event && my_callback) if (event && my_callback)
{ {
event_display(event); event_display(event);

+ 2
- 1
src/event.h View File

// First function to be called. // First function to be called.
// the callback will be called when the event actually occurs. // the callback will be called when the event actually occurs.
// The callback is detailled in speak_lib.h . // The callback is detailled in speak_lib.h .
void event_init(t_espeak_callback* cb);
void event_init(void);
void event_set_callback(t_espeak_callback* cb);


// Clear any pending event. // Clear any pending event.
// //

+ 4
- 1
src/speak_lib.cpp View File

wave_init(); wave_init();
wave_set_callback_is_output_enabled( fifo_is_command_enabled); wave_set_callback_is_output_enabled( fifo_is_command_enabled);
my_audio = wave_open("alsa"); my_audio = wave_open("alsa");
event_init(synth_callback);
event_init();
#endif #endif
break; break;


{//====================================================================== {//======================================================================
ENTER("espeak_SetSynthCallback"); ENTER("espeak_SetSynthCallback");
synth_callback = SynthCallback; synth_callback = SynthCallback;
#ifdef USE_ASYNC
event_set_callback(synth_callback);
#endif
} }


ESPEAK_API void espeak_SetUriCallback(int (* UriCallback)(int, const char*, const char *)) ESPEAK_API void espeak_SetUriCallback(int (* UriCallback)(int, const char*, const char *))

+ 1
- 1
src/synthdata.cpp View File

#include "translate.h" #include "translate.h"
#include "wave.h" #include "wave.h"


const char *version_string = "1.25.14 31.May.07";
const char *version_string = "1.25.15 01.Jun.07";
const int version_phdata = 0x012514; const int version_phdata = 0x012514;


int option_device_number = -1; int option_device_number = -1;

+ 1
- 1
src/tr_languages.cpp View File

case L('i','s'): // Icelandic case L('i','s'): // Icelandic
{ {
static int stress_amps_is[] = {16,16, 20,20, 20,24, 24,22 }; static int stress_amps_is[] = {16,16, 20,20, 20,24, 24,22 };
static int stress_lengths_is[8] = {180,155, 200,200, 0,0, 240,250};
static int stress_lengths_is[8] = {180,160, 200,200, 0,0, 240,250};
static const wchar_t is_lettergroup_B[] = {'c','f','h','k','p','t','x',0xfe,0}; // voiceless conants, including 'þ' ?? 's' static const wchar_t is_lettergroup_B[] = {'c','f','h','k','p','t','x',0xfe,0}; // voiceless conants, including 'þ' ?? 's'


tr = new Translator(); tr = new Translator();

Loading…
Cancel
Save