From cbbaec7694e6ddd9a85fd6dc8d35dbd88fe2f0d3 Mon Sep 17 00:00:00 2001 From: terminx Date: Sat, 2 Jun 2012 00:01:36 +0000 Subject: [PATCH] Replace a few "#ifdef GEKKO" statements added for the Wii port with "#ifdef HAVE_VORBIS" like they should have been in the first place. Allows jaudiolib to build without Ogg support on platforms other than the Wii if desired. git-svn-id: https://svn.eduke32.com/eduke32@2719 1a8010ca-5511-0410-912e-c29ae57300e0 --- polymer/eduke32/source/jaudiolib/src/fx_man.c | 12 ++++++------ polymer/eduke32/source/jaudiolib/src/multivoc.c | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/polymer/eduke32/source/jaudiolib/src/fx_man.c b/polymer/eduke32/source/jaudiolib/src/fx_man.c index 4e84c3f29..f75cf0002 100644 --- a/polymer/eduke32/source/jaudiolib/src/fx_man.c +++ b/polymer/eduke32/source/jaudiolib/src/fx_man.c @@ -938,11 +938,11 @@ int32_t FX_PlayAuto(char *ptr, uint32_t length, int32_t pitchoffset, int32_t vol case 'R'+('I'<<8)+('F'<<16)+('F'<<24): handle = MV_PlayWAV(ptr, length, pitchoffset, vol, left, right, priority, callbackval); break; +#ifdef HAVE_VORBIS case 'O'+('g'<<8)+('g'<<16)+('S'<<24): -#ifndef GEKKO handle = MV_PlayVorbis(ptr, length, pitchoffset, vol, left, right, priority, callbackval); -#endif break; +#endif default: switch (LITTLE32(*(int32_t *)(ptr + 8))) { @@ -995,11 +995,11 @@ int32_t FX_PlayLoopedAuto(char *ptr, uint32_t length, int32_t loopstart, int32_t case 'R'+('I'<<8)+('F'<<16)+('F'<<24): handle = MV_PlayLoopedWAV(ptr, length, loopstart, loopend, pitchoffset, vol, left, right, priority, callbackval); break; +#ifdef HAVE_VORBIS case 'O'+('g'<<8)+('g'<<16)+('S'<<24): -#ifndef GEKKO handle = MV_PlayLoopedVorbis(ptr, length, loopstart, loopend, pitchoffset, vol, left, right, priority, callbackval); -#endif break; +#endif default: switch (LITTLE32(*(int32_t *)(ptr + 8))) { @@ -1038,11 +1038,11 @@ int32_t FX_PlayAuto3D(char *ptr, uint32_t length, int32_t pitchoffset, int32_t a case 'R'+('I'<<8)+('F'<<16)+('F'<<24): // RIFF handle = MV_PlayWAV3D(ptr, length, pitchoffset, angle, distance, priority, callbackval); break; +#ifdef HAVE_VORBIS case 'O'+('g'<<8)+('g'<<16)+('S'<<24): // OggS -#ifndef GEKKO handle = MV_PlayVorbis3D(ptr, length, pitchoffset, angle, distance, priority, callbackval); -#endif break; +#endif default: switch (LITTLE32(*(int32_t *)(ptr + 8))) { diff --git a/polymer/eduke32/source/jaudiolib/src/multivoc.c b/polymer/eduke32/source/jaudiolib/src/multivoc.c index 75658f6d5..96135405b 100644 --- a/polymer/eduke32/source/jaudiolib/src/multivoc.c +++ b/polymer/eduke32/source/jaudiolib/src/multivoc.c @@ -334,7 +334,7 @@ static void MV_StopVoice(VoiceNode *voice) RestoreInterrupts(); -#ifndef GEKKO +#ifdef HAVE_VORBIS if (voice->wavetype == Vorbis) MV_ReleaseVorbisVoice(voice); #endif @@ -458,7 +458,7 @@ static void MV_ServiceVoc(void) //MV_StopVoice( voice ); LL_Remove(voice, next, prev); LL_Add((VoiceNode*) &VoicePool, voice, next, prev); -#ifndef GEKKO +#ifdef HAVE_VORBIS if (voice->wavetype == Vorbis) MV_ReleaseVorbisVoice(voice); #endif