diff options
author | Chris Robinson <[email protected]> | 2009-05-29 13:30:50 -0700 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2009-05-29 13:30:50 -0700 |
commit | 74dc7090fdf4084fae1824986e382fde4535ae7c (patch) | |
tree | 7aa7485bba3a17a9449c65432af7a360cb879d8d /OpenAL32/Include | |
parent | e12ac95d6926c0b576775d2817f2e829c153947b (diff) |
Don't expose effect-specific structures
Diffstat (limited to 'OpenAL32/Include')
-rw-r--r-- | OpenAL32/Include/alAuxEffectSlot.h | 23 | ||||
-rw-r--r-- | OpenAL32/Include/alEcho.h | 24 | ||||
-rw-r--r-- | OpenAL32/Include/alReverb.h | 28 |
3 files changed, 19 insertions, 56 deletions
diff --git a/OpenAL32/Include/alAuxEffectSlot.h b/OpenAL32/Include/alAuxEffectSlot.h index 8dfa9418..e4c46d70 100644 --- a/OpenAL32/Include/alAuxEffectSlot.h +++ b/OpenAL32/Include/alAuxEffectSlot.h @@ -4,8 +4,6 @@ #include "AL/al.h" #include "alEffect.h" #include "alFilter.h" -#include "alReverb.h" -#include "alEcho.h" #ifdef __cplusplus extern "C" { @@ -17,6 +15,8 @@ extern "C" { #define AL_EFFECTSLOT_NULL 0x0000 +typedef struct ALeffectState ALeffectState; + typedef struct ALeffectslot { ALeffect effect; @@ -24,8 +24,7 @@ typedef struct ALeffectslot ALfloat Gain; ALboolean AuxSendAuto; - ALverbState *ReverbState; - ALechoState *EchoState; + ALeffectState *EffectState; ALfloat WetBuffer[BUFFERSIZE]; @@ -53,6 +52,22 @@ ALvoid AL_APIENTRY alGetAuxiliaryEffectSlotfv(ALuint effectslot, ALenum param, A ALvoid ReleaseALAuxiliaryEffectSlots(ALCcontext *Context); + +struct ALeffectState { + ALvoid (*Destroy)(ALeffectState *State); + ALvoid (*Update)(ALeffectState *State, ALCcontext *Context, ALeffectslot *Slot, ALeffect *Effect); + ALvoid (*Process)(ALeffectState *State, ALuint SamplesToDo, const ALfloat *SamplesIn, ALfloat (*SamplesOut)[OUTPUTCHANNELS]); +}; + +ALeffectState *EAXVerbCreate(ALCcontext *Context); +ALeffectState *VerbCreate(ALCcontext *Context); +ALeffectState *EchoCreate(ALCcontext *Context); + +#define ALEffect_Destroy(a) ((a)->Destroy((a))) +#define ALEffect_Update(a,b,c,d) ((a)->Update((a),(b),(c),(d))) +#define ALEffect_Process(a,b,c,d) ((a)->Process((a),(b),(c),(d))) + + #ifdef __cplusplus } #endif diff --git a/OpenAL32/Include/alEcho.h b/OpenAL32/Include/alEcho.h deleted file mode 100644 index 34896ea7..00000000 --- a/OpenAL32/Include/alEcho.h +++ /dev/null @@ -1,24 +0,0 @@ -#ifndef AL_ECHO_H -#define AL_ECHO_H - -#include "AL/al.h" -#include "AL/alc.h" -#include "alMain.h" -#include "alEffect.h" - -#ifdef __cplusplus -extern "C" { -#endif - -typedef struct ALechoState ALechoState; - -ALechoState *EchoCreate(ALCcontext *Context); -ALvoid EchoDestroy(ALechoState *State); -ALvoid EchoUpdate(ALCcontext *Context, struct ALeffectslot *Slot, ALeffect *Effect); -ALvoid EchoProcess(ALechoState *State, ALuint SamplesToDo, const ALfloat *SamplesIn, ALfloat (*SamplesOut)[OUTPUTCHANNELS]); - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/OpenAL32/Include/alReverb.h b/OpenAL32/Include/alReverb.h deleted file mode 100644 index 95b5adb0..00000000 --- a/OpenAL32/Include/alReverb.h +++ /dev/null @@ -1,28 +0,0 @@ -#ifndef _AL_REVERB_H_ -#define _AL_REVERB_H_ - -#include "AL/al.h" -#include "AL/alc.h" -#include "alMain.h" -#include "alAuxEffectSlot.h" -#include "alEffect.h" - -#ifdef __cplusplus -extern "C" { -#endif - -typedef struct ALverbState ALverbState; - -ALverbState *VerbCreate(ALCcontext *Context); -ALverbState *EAXVerbCreate(ALCcontext *Context); -ALvoid VerbDestroy(ALverbState *State); -ALvoid VerbUpdate(ALCcontext *Context, struct ALeffectslot *Slot, ALeffect *Effect); -ALvoid VerbProcess(ALverbState *State, ALuint SamplesToDo, const ALfloat *SamplesIn, ALfloat (*SamplesOut)[OUTPUTCHANNELS]); -ALvoid EAXVerbProcess(ALverbState *State, ALuint SamplesToDo, const ALfloat *SamplesIn, ALfloat (*SamplesOut)[OUTPUTCHANNELS]); - -#ifdef __cplusplus -} -#endif - -#endif - |