From fdbb20fd59a57d3e1ab9ccc783ce50cc9e65ae35 Mon Sep 17 00:00:00 2001 From: Jeffrey Pfau Date: Mon, 31 Aug 2015 01:07:10 -0700 Subject: [PATCH] 3DS: Support using non-blip for audio --- src/platform/3ds/main.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/platform/3ds/main.c b/src/platform/3ds/main.c index 375215316..7d2928216 100644 --- a/src/platform/3ds/main.c +++ b/src/platform/3ds/main.c @@ -182,8 +182,12 @@ static void _postAudioBuffer(struct GBAAVStream* stream, struct GBAAudio* audio) UNUSED(stream); memset(audioLeft, 0, AUDIO_SAMPLES * sizeof(int16_t)); memset(audioRight, 0, AUDIO_SAMPLES * sizeof(int16_t)); +#if RESAMPLE_LIBRARY == RESAMPLE_BLIP_BUF blip_read_samples(audio->left, audioLeft, AUDIO_SAMPLES, false); blip_read_samples(audio->right, audioRight, AUDIO_SAMPLES, false); +#elif RESAMPLE_LIBRARY == RESAMPLE_NN + GBAAudioCopy(audio, audioLeft, audioRight, AUDIO_SAMPLES); +#endif GSPGPU_FlushDataCache(0, (void*) audioLeft, AUDIO_SAMPLES * sizeof(int16_t)); GSPGPU_FlushDataCache(0, (void*) audioRight, AUDIO_SAMPLES * sizeof(int16_t)); csndPlaySound(0x8, SOUND_ONE_SHOT | SOUND_FORMAT_16BIT, 0x8000, 1.0, -1.0, audioLeft, audioLeft, AUDIO_SAMPLES * sizeof(int16_t));