mirror of
https://gitlab.com/GaryOderNichts/re3-wiiu.git
synced 2024-11-29 12:34:14 +01:00
wiiu: don't link against openal functions directly
This commit is contained in:
parent
0eb992450e
commit
27674eb532
@ -3,7 +3,6 @@
|
|||||||
|
|
||||||
#ifdef AUDIO_OAL
|
#ifdef AUDIO_OAL
|
||||||
|
|
||||||
#ifndef __WIIU__
|
|
||||||
/*
|
/*
|
||||||
* When linking to a static openal-soft library,
|
* When linking to a static openal-soft library,
|
||||||
* the extension function inside the openal library conflict with the variables here.
|
* the extension function inside the openal library conflict with the variables here.
|
||||||
@ -50,11 +49,9 @@ LPALGETFILTERFV alGetFilterfv;
|
|||||||
|
|
||||||
using namespace re3_openal;
|
using namespace re3_openal;
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
void EFXInit()
|
void EFXInit()
|
||||||
{
|
{
|
||||||
#ifndef __WIIU__
|
|
||||||
/* Define a macro to help load the function pointers. */
|
/* Define a macro to help load the function pointers. */
|
||||||
/* Prefix all the function pointers with re* to avoid linking issue with the library functions */
|
/* Prefix all the function pointers with re* to avoid linking issue with the library functions */
|
||||||
#define LOAD_PROC(T, x) ((x) = (T)alGetProcAddress(#x))
|
#define LOAD_PROC(T, x) ((x) = (T)alGetProcAddress(#x))
|
||||||
@ -94,7 +91,6 @@ LOAD_PROC(LPALGENEFFECTS, alGenEffects);
|
|||||||
LOAD_PROC(LPALGETAUXILIARYEFFECTSLOTF, alGetAuxiliaryEffectSlotf);
|
LOAD_PROC(LPALGETAUXILIARYEFFECTSLOTF, alGetAuxiliaryEffectSlotf);
|
||||||
LOAD_PROC(LPALGETAUXILIARYEFFECTSLOTFV, alGetAuxiliaryEffectSlotfv);
|
LOAD_PROC(LPALGETAUXILIARYEFFECTSLOTFV, alGetAuxiliaryEffectSlotfv);
|
||||||
#undef LOAD_PROC
|
#undef LOAD_PROC
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void SetEffectsLevel(ALuint uiFilter, float level)
|
void SetEffectsLevel(ALuint uiFilter, float level)
|
||||||
|
@ -11,9 +11,7 @@ void EFX_Set(ALuint effect, const EAXLISTENERPROPERTIES *props);
|
|||||||
void EAX3_SetReverbMix(ALuint filter, float mix);
|
void EAX3_SetReverbMix(ALuint filter, float mix);
|
||||||
void SetEffectsLevel(ALuint uiFilter, float level);
|
void SetEffectsLevel(ALuint uiFilter, float level);
|
||||||
|
|
||||||
#ifndef __WIIU__
|
|
||||||
namespace re3_openal {
|
namespace re3_openal {
|
||||||
#endif
|
|
||||||
|
|
||||||
extern LPALGENEFFECTS alGenEffects;
|
extern LPALGENEFFECTS alGenEffects;
|
||||||
extern LPALDELETEEFFECTS alDeleteEffects;
|
extern LPALDELETEEFFECTS alDeleteEffects;
|
||||||
@ -49,10 +47,8 @@ extern LPALGETFILTERIV alGetFilteriv;
|
|||||||
extern LPALGETFILTERF alGetFilterf;
|
extern LPALGETFILTERF alGetFilterf;
|
||||||
extern LPALGETFILTERFV alGetFilterfv;
|
extern LPALGETFILTERFV alGetFilterfv;
|
||||||
|
|
||||||
#ifndef __WIIU__
|
|
||||||
}
|
}
|
||||||
|
|
||||||
using namespace re3_openal;
|
using namespace re3_openal;
|
||||||
#endif
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
@ -330,13 +330,11 @@ set_new_provider(int index)
|
|||||||
|
|
||||||
alDistanceModel(AL_INVERSE_DISTANCE_CLAMPED);
|
alDistanceModel(AL_INVERSE_DISTANCE_CLAMPED);
|
||||||
|
|
||||||
#ifndef __WIIU__
|
|
||||||
if ( alcIsExtensionPresent(ALDevice, (ALCchar*)ALC_EXT_EFX_NAME) )
|
if ( alcIsExtensionPresent(ALDevice, (ALCchar*)ALC_EXT_EFX_NAME) )
|
||||||
{
|
{
|
||||||
alGenAuxiliaryEffectSlots(1, &ALEffectSlot);
|
alGenAuxiliaryEffectSlots(1, &ALEffectSlot);
|
||||||
alGenEffects(1, &ALEffect);
|
alGenEffects(1, &ALEffect);
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
alGenSources(MAX_STREAMS*2, ALStreamSources[0]);
|
alGenSources(MAX_STREAMS*2, ALStreamSources[0]);
|
||||||
for ( int32 i = 0; i < MAX_STREAMS; i++ )
|
for ( int32 i = 0; i < MAX_STREAMS; i++ )
|
||||||
@ -358,7 +356,6 @@ set_new_provider(int index)
|
|||||||
usingEAX3 = 0;
|
usingEAX3 = 0;
|
||||||
_usingEFX = false;
|
_usingEFX = false;
|
||||||
|
|
||||||
#ifndef __WIIU__
|
|
||||||
if ( !strcmp(&providers[index].name[strlen(providers[index].name) - strlen(" EAX3")], " EAX3")
|
if ( !strcmp(&providers[index].name[strlen(providers[index].name) - strlen(" EAX3")], " EAX3")
|
||||||
&& alcIsExtensionPresent(ALDevice, (ALCchar*)ALC_EXT_EFX_NAME) )
|
&& alcIsExtensionPresent(ALDevice, (ALCchar*)ALC_EXT_EFX_NAME) )
|
||||||
{
|
{
|
||||||
@ -384,7 +381,6 @@ set_new_provider(int index)
|
|||||||
DEV("EFX\n");
|
DEV("EFX\n");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
//SampleManager.SetSpeakerConfig(speaker_type);
|
//SampleManager.SetSpeakerConfig(speaker_type);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user