From: Kaj-Michael Lang Date: Thu, 9 Aug 2007 16:22:19 +0000 (+0300) Subject: Use smaller buffer. Use UTF8 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=bb82a897cea3023b2f632d9d2d17e62fbef8d681;p=mapper Use smaller buffer. Use UTF8 --- diff --git a/src/speak.c b/src/speak.c index 007df04..f3c7d00 100644 --- a/src/speak.c +++ b/src/speak.c @@ -137,13 +137,13 @@ return 0; gboolean speak_init(void) { -erate=espeak_Initialize(AUDIO_OUTPUT_RETRIEVAL, 1000, NULL, 0); +erate=espeak_Initialize(AUDIO_OUTPUT_RETRIEVAL, 100, NULL, 0); if (erate==-1) return FALSE; espeak_SetSynthCallback(espeak_cb); espeak_SetVoiceByName("en"); -espeak_SetParameter(espeakRATE,140,0); +espeak_SetParameter(espeakRATE,125,0); espeak_SetParameter(espeakVOLUME,100,0); if (speak_create_pipeline()==FALSE) return FALSE; @@ -166,12 +166,11 @@ speaking=FALSE; gboolean speak_text(gchar *text) { -#if 0 if (speaking==TRUE) return FALSE; -#endif + g_printf("Speaking: %s (%d)\n", text, strlen(text)); -espeak_Synth(text, strlen(text)+1, 0, POS_CHARACTER, 0, espeakCHARS_8BIT, NULL, NULL); +espeak_Synth(text, strlen(text)+1, 0, POS_CHARACTER, 0, espeakCHARS_UTF8, NULL, NULL); if (gst_element_set_state (ge.pipeline, GST_STATE_PLAYING) == GST_STATE_CHANGE_FAILURE) { g_print("Failed to play\n");