speechd-discuss
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH 7/7] use module_tts_output instead of spd_audio_play in sound ico


From: Andrei Kholodnyi
Subject: [PATCH 7/7] use module_tts_output instead of spd_audio_play in sound icons.
Date: Sun, 28 Nov 2010 19:51:28 +0100

---
 src/modules/espeak.c |    4 +---
 src/modules/ibmtts.c |    4 +---
 2 files changed, 2 insertions(+), 6 deletions(-)

diff --git a/src/modules/espeak.c b/src/modules/espeak.c
index 781d5af..380aab3 100644
--- a/src/modules/espeak.c
+++ b/src/modules/espeak.c
@@ -1146,9 +1146,7 @@ espeak_play_file(char *filename)
        if (readcount > 0) {
                track.num_samples = readcount / sfinfo.channels;
                DBG("Espeak: Sending %i samples to audio.", track.num_samples);
-               /* Volume is controlled by the synthesizer.  Always play at 
normal on audio device. */
-               spd_audio_set_volume(module_audio_id, EspeakSoundIconVolume);
-               int ret = spd_audio_play(module_audio_id, track, SPD_AUDIO_LE);
+               int ret = module_tts_output(track, SPD_AUDIO_LE);
                if (ret < 0) {
                        DBG("ERROR: Can't play track for unknown reason.");
                        result = FALSE;
diff --git a/src/modules/ibmtts.c b/src/modules/ibmtts.c
index 1885bf4..333618f 100644
--- a/src/modules/ibmtts.c
+++ b/src/modules/ibmtts.c
@@ -1627,9 +1627,7 @@ ibmtts_play_file(char *filename)
     if (readcount > 0) {
         track.num_samples = readcount / sfinfo.channels;
         DBG("Ibmtts: Sending %i samples to audio.", track.num_samples);
-        /* Volume is controlled by the synthesizer.  Always play at normal on 
audio device. */
-        spd_audio_set_volume(module_audio_id, 0);
-        int ret = spd_audio_play(module_audio_id, track, SPD_AUDIO_LE);
+        int ret = module_tts_output(track, SPD_AUDIO_LE);
         if (ret < 0) {
             DBG("ERROR: Can't play track for unknown reason.");
             result = IBMTTS_FALSE;
-- 
1.6.0.4




reply via email to

[Prev in Thread] Current Thread [Next in Thread]