aboutsummaryrefslogtreecommitdiffstats
path: root/src/jo_n_speak.c
diff options
context:
space:
mode:
authorJozanLeClerc <bousset.rudy@gmail.com>2020-04-27 01:02:18 +0200
committerJozanLeClerc <bousset.rudy@gmail.com>2020-04-27 01:02:18 +0200
commitea0eca4f717d7f4408273613a566f3550d27085b (patch)
treeb1c1fa062823bb36bbd8bb9dab6437c83c229eec /src/jo_n_speak.c
parentMakefile change (diff)
downloadlowbat-bsd-ea0eca4f717d7f4408273613a566f3550d27085b.tar.gz
lowbat-bsd-ea0eca4f717d7f4408273613a566f3550d27085b.tar.bz2
lowbat-bsd-ea0eca4f717d7f4408273613a566f3550d27085b.tar.xz
lowbat-bsd-ea0eca4f717d7f4408273613a566f3550d27085b.tar.zst
lowbat-bsd-ea0eca4f717d7f4408273613a566f3550d27085b.zip
Rewrite started
Diffstat (limited to 'src/jo_n_speak.c')
-rw-r--r--src/jo_n_speak.c45
1 files changed, 0 insertions, 45 deletions
diff --git a/src/jo_n_speak.c b/src/jo_n_speak.c
deleted file mode 100644
index 48fcbaa..0000000
--- a/src/jo_n_speak.c
+++ /dev/null
@@ -1,45 +0,0 @@
-/****************************************************************************************/
-/* */
-/* File : jo_n_speak.c /_________/ */
-/* Author : Joe | */
-/* Date : 04/2020 | */
-/* Info : Uses espeak lib to speak | */
-/* / | */
-/* \ / */
-/* \_____/ */
-/* */
-/****************************************************************************************/
-
-#include <jo_n_speak.h>
-
-void
-jo_n_speak(const char *msg)
-{
- espeak_ERROR err;
- int32_t samplerate;
-
- samplerate = espeak_Initialize
- (AUDIO_OUTPUT_PLAYBACK,
- 500,
- NULL,
- 0);
- if (samplerate == -1) {
- dprintf(2, "Failed to initialize espeak\n");
- exit(JO_RET_ESPEAK_FAILED);
- }
- espeak_SetVoiceByName(JO_ESPEAK_VOICE);
- err = espeak_Synth
- (msg,
- strlen(msg) + 1,
- 0,
- POS_CHARACTER,
- 0,
- espeakCHARS_AUTO | espeakENDPAUSE,
- NULL,
- NULL);
- if (err != EE_OK) {
- dprintf(STDERR_FILENO, "espeak synth error\n");
- }
- espeak_Synchronize();
- espeak_Terminate();
-}