summaryrefslogtreecommitdiffstats
path: root/uisimulator/x11/sound.c
diff options
context:
space:
mode:
Diffstat (limited to 'uisimulator/x11/sound.c')
-rw-r--r--uisimulator/x11/sound.c45
1 files changed, 45 insertions, 0 deletions
diff --git a/uisimulator/x11/sound.c b/uisimulator/x11/sound.c
index dd875e41f5..06d9c014ff 100644
--- a/uisimulator/x11/sound.c
+++ b/uisimulator/x11/sound.c
@@ -21,6 +21,7 @@
#ifdef ROCKBOX_HAS_SIMSOUND /* play sound in sim enabled */
+#include <stdbool.h>
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
@@ -31,6 +32,8 @@
#include "sound.h"
+static bool playing = false;
+
int sim_sound_init(void)
{
int fd;
@@ -92,4 +95,46 @@ void sound_playback_thread(void)
}
+/* Stubs for PCM audio playback. */
+bool pcm_is_playing(void)
+{
+ return playing;
+}
+
+void pcm_mute(bool state)
+{
+ (void)state;
+}
+
+void pcm_play_pause(bool state)
+{
+ (void)state;
+}
+
+bool pcm_is_paused(void)
+{
+ return false;
+}
+
+void pcm_play_stop(void)
+{
+ playing = false;
+}
+
+void pcm_init(void)
+{
+}
+
+void (*sound_get_pcm)(unsigned char** start, long* size);
+void pcm_play_data(void (*get_more)(unsigned char** start, long* size))
+{
+ sound_get_pcm = get_more;
+ playing = true;
+}
+
+long pcm_get_bytes_waiting(void)
+{
+ return 0;
+}
+
#endif /* ROCKBOX_HAS_SIMSOUND */