diff options
author | Chris Robinson <[email protected]> | 2018-01-11 09:25:17 -0800 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2018-01-11 09:25:17 -0800 |
commit | 88545ccae5bbae0a95c5b347b8e17a0debe7b1f0 (patch) | |
tree | 4ddef94b0e3e1c3ddc64be9150a662af57093857 | |
parent | 3832b25f308279539a3748bafdc5056d16e4b291 (diff) |
Move the EffectList array to alEffect.c/h
-rw-r--r-- | OpenAL32/Include/alEffect.h | 9 | ||||
-rw-r--r-- | OpenAL32/Include/alMain.h | 8 | ||||
-rw-r--r-- | OpenAL32/alEffect.c | 15 | ||||
-rw-r--r-- | OpenAL32/alExtension.c | 16 |
4 files changed, 24 insertions, 24 deletions
diff --git a/OpenAL32/Include/alEffect.h b/OpenAL32/Include/alEffect.h index bec50f7d..394500e0 100644 --- a/OpenAL32/Include/alEffect.h +++ b/OpenAL32/Include/alEffect.h @@ -27,6 +27,15 @@ extern ALboolean DisabledEffects[MAX_EFFECTS]; extern ALfloat ReverbBoost; +struct EffectList { + const char *name; + int type; + const char *ename; + ALenum val; +}; +extern const struct EffectList EffectList[]; + + struct ALeffectVtable { void (*const setParami)(struct ALeffect *effect, ALCcontext *context, ALenum param, ALint val); void (*const setParamiv)(struct ALeffect *effect, ALCcontext *context, ALenum param, const ALint *vals); diff --git a/OpenAL32/Include/alMain.h b/OpenAL32/Include/alMain.h index c11eb6d1..a6a6471b 100644 --- a/OpenAL32/Include/alMain.h +++ b/OpenAL32/Include/alMain.h @@ -471,14 +471,6 @@ enum AmbiNorm { }; -extern const struct EffectList { - const char *name; - int type; - const char *ename; - ALenum val; -} EffectList[]; - - enum DeviceType { Playback, Capture, diff --git a/OpenAL32/alEffect.c b/OpenAL32/alEffect.c index 0dac429a..6fa748b3 100644 --- a/OpenAL32/alEffect.c +++ b/OpenAL32/alEffect.c @@ -32,6 +32,21 @@ #include "alError.h" +const struct EffectList EffectList[] = { + { "eaxreverb", AL__EAXREVERB, "AL_EFFECT_EAXREVERB", AL_EFFECT_EAXREVERB }, + { "reverb", AL__REVERB, "AL_EFFECT_REVERB", AL_EFFECT_REVERB }, + { "chorus", AL__CHORUS, "AL_EFFECT_CHORUS", AL_EFFECT_CHORUS }, + { "compressor", AL__COMPRESSOR, "AL_EFFECT_COMPRESSOR", AL_EFFECT_COMPRESSOR }, + { "distortion", AL__DISTORTION, "AL_EFFECT_DISTORTION", AL_EFFECT_DISTORTION }, + { "echo", AL__ECHO, "AL_EFFECT_ECHO", AL_EFFECT_ECHO }, + { "equalizer", AL__EQUALIZER, "AL_EFFECT_EQUALIZER", AL_EFFECT_EQUALIZER }, + { "flanger", AL__FLANGER, "AL_EFFECT_FLANGER", AL_EFFECT_FLANGER }, + { "modulator", AL__MODULATOR, "AL_EFFECT_RING_MODULATOR", AL_EFFECT_RING_MODULATOR }, + { "dedicated", AL__DEDICATED, "AL_EFFECT_DEDICATED_LOW_FREQUENCY_EFFECT", AL_EFFECT_DEDICATED_LOW_FREQUENCY_EFFECT }, + { "dedicated", AL__DEDICATED, "AL_EFFECT_DEDICATED_DIALOGUE", AL_EFFECT_DEDICATED_DIALOGUE }, + { NULL, 0, NULL, (ALenum)0 } +}; + ALboolean DisabledEffects[MAX_EFFECTS]; extern inline void LockEffectsRead(ALCdevice *device); diff --git a/OpenAL32/alExtension.c b/OpenAL32/alExtension.c index c85e9007..7db326a2 100644 --- a/OpenAL32/alExtension.c +++ b/OpenAL32/alExtension.c @@ -35,22 +35,6 @@ #include "AL/alc.h" -const struct EffectList EffectList[] = { - { "eaxreverb", AL__EAXREVERB, "AL_EFFECT_EAXREVERB", AL_EFFECT_EAXREVERB }, - { "reverb", AL__REVERB, "AL_EFFECT_REVERB", AL_EFFECT_REVERB }, - { "chorus", AL__CHORUS, "AL_EFFECT_CHORUS", AL_EFFECT_CHORUS }, - { "compressor", AL__COMPRESSOR, "AL_EFFECT_COMPRESSOR", AL_EFFECT_COMPRESSOR }, - { "distortion", AL__DISTORTION, "AL_EFFECT_DISTORTION", AL_EFFECT_DISTORTION }, - { "echo", AL__ECHO, "AL_EFFECT_ECHO", AL_EFFECT_ECHO }, - { "equalizer", AL__EQUALIZER, "AL_EFFECT_EQUALIZER", AL_EFFECT_EQUALIZER }, - { "flanger", AL__FLANGER, "AL_EFFECT_FLANGER", AL_EFFECT_FLANGER }, - { "modulator", AL__MODULATOR, "AL_EFFECT_RING_MODULATOR", AL_EFFECT_RING_MODULATOR }, - { "dedicated", AL__DEDICATED, "AL_EFFECT_DEDICATED_LOW_FREQUENCY_EFFECT", AL_EFFECT_DEDICATED_LOW_FREQUENCY_EFFECT }, - { "dedicated", AL__DEDICATED, "AL_EFFECT_DEDICATED_DIALOGUE", AL_EFFECT_DEDICATED_DIALOGUE }, - { NULL, 0, NULL, (ALenum)0 } -}; - - AL_API ALboolean AL_APIENTRY alIsExtensionPresent(const ALchar *extName) { ALboolean ret = AL_FALSE; |