diff options
author | Thomas Martitz <kugel@rockbox.org> | 2010-05-17 21:43:06 +0000 |
---|---|---|
committer | Thomas Martitz <kugel@rockbox.org> | 2010-05-17 21:43:06 +0000 |
commit | 86e19dd65d18c921effa762de74d671f333dcfce (patch) | |
tree | 852c50714fe70721eb18d72f8495e762eed1f52a /firmware/target/hosted/sdl | |
parent | 36e52604b061f281863737ca78ef6c3b1fab11b9 (diff) |
Restore changes of r25809 that got lost in the target tree movement and fix simulator build on cygwin.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26120 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/target/hosted/sdl')
-rw-r--r-- | firmware/target/hosted/sdl/pcm-sdl.c | 10 | ||||
-rw-r--r-- | firmware/target/hosted/sdl/system-sdl.c | 1 |
2 files changed, 8 insertions, 3 deletions
diff --git a/firmware/target/hosted/sdl/pcm-sdl.c b/firmware/target/hosted/sdl/pcm-sdl.c index 1772db94f4..ee92fa208d 100644 --- a/firmware/target/hosted/sdl/pcm-sdl.c +++ b/firmware/target/hosted/sdl/pcm-sdl.c @@ -34,6 +34,9 @@ #include "pcm.h" #include "pcm_sampr.h" +/*#define LOGF_ENABLE*/ +#include "logf.h" + #ifdef DEBUG #include <stdio.h> extern bool debug_audio; @@ -49,7 +52,7 @@ static size_t pcm_data_size; static size_t pcm_sample_bytes; static size_t pcm_channel_bytes; -struct pcm_udata +static struct pcm_udata { Uint8 *stream; Uint32 num_in; @@ -124,7 +127,7 @@ size_t pcm_get_bytes_waiting(void) return pcm_data_size; } -void write_to_soundcard(struct pcm_udata *udata) +static void write_to_soundcard(struct pcm_udata *udata) { #ifdef DEBUG if (debug_audio && (udata->debug == NULL)) { @@ -214,8 +217,9 @@ void write_to_soundcard(struct pcm_udata *udata) } } -void sdl_audio_callback(struct pcm_udata *udata, Uint8 *stream, int len) +static void sdl_audio_callback(struct pcm_udata *udata, Uint8 *stream, int len) { + logf("sdl_audio_callback: len %d, pcm %d\n", len, pcm_data_size); udata->stream = stream; /* Write what we have in the PCM buffer */ diff --git a/firmware/target/hosted/sdl/system-sdl.c b/firmware/target/hosted/sdl/system-sdl.c index 3d67de425b..95bfa5984a 100644 --- a/firmware/target/hosted/sdl/system-sdl.c +++ b/firmware/target/hosted/sdl/system-sdl.c @@ -23,6 +23,7 @@ #include <stdlib.h> #include <string.h> #include <setjmp.h> +#include <inttypes.h> #include "system-sdl.h" #include "thread-sdl.h" #include "sim-ui-defines.h" |