aboutsummaryrefslogtreecommitdiffstats
path: root/OpenAL32/Include
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2013-03-13 23:31:12 -0700
committerChris Robinson <[email protected]>2013-03-13 23:31:12 -0700
commit3fd0f23e48fc71718f438e035ffb09d4ba9a47a3 (patch)
treedc33a1a36aa51489f513cb68c1ed4c07b7334d47 /OpenAL32/Include
parent991aba286f32e8760811bc061b15c5102c66b3e1 (diff)
Add Chorus and Flanger effects
Code provided by Mike Gorchak
Diffstat (limited to 'OpenAL32/Include')
-rw-r--r--OpenAL32/Include/alAuxEffectSlot.h2
-rw-r--r--OpenAL32/Include/alEffect.h38
2 files changed, 40 insertions, 0 deletions
diff --git a/OpenAL32/Include/alAuxEffectSlot.h b/OpenAL32/Include/alAuxEffectSlot.h
index 4c14b1f7..e39a3d91 100644
--- a/OpenAL32/Include/alAuxEffectSlot.h
+++ b/OpenAL32/Include/alAuxEffectSlot.h
@@ -46,6 +46,8 @@ ALeffectState *ReverbCreate(void);
ALeffectState *EchoCreate(void);
ALeffectState *ModulatorCreate(void);
ALeffectState *DedicatedCreate(void);
+ALeffectState *ChorusCreate(void);
+ALeffectState *FlangerCreate(void);
#define ALeffectState_Destroy(a) ((a)->Destroy((a)))
#define ALeffectState_DeviceUpdate(a,b) ((a)->DeviceUpdate((a),(b)))
diff --git a/OpenAL32/Include/alEffect.h b/OpenAL32/Include/alEffect.h
index 77ff97a8..87dc717d 100644
--- a/OpenAL32/Include/alEffect.h
+++ b/OpenAL32/Include/alEffect.h
@@ -13,6 +13,8 @@ enum {
ECHO,
MODULATOR,
DEDICATED,
+ CHORUS,
+ FLANGER,
MAX_EFFECTS
};
@@ -75,6 +77,24 @@ typedef struct ALeffect
ALfloat Gain;
} Dedicated;
+ struct {
+ ALint Waveform;
+ ALint Phase;
+ ALfloat Rate;
+ ALfloat Depth;
+ ALfloat Feedback;
+ ALfloat Delay;
+ } Chorus;
+
+ struct {
+ ALint Waveform;
+ ALint Phase;
+ ALfloat Rate;
+ ALfloat Depth;
+ ALfloat Feedback;
+ ALfloat Delay;
+ } Flanger;
+
void (*SetParami)(struct ALeffect *effect, ALCcontext *context, ALenum param, ALint val);
void (*SetParamiv)(struct ALeffect *effect, ALCcontext *context, ALenum param, const ALint *vals);
void (*SetParamf)(struct ALeffect *effect, ALCcontext *context, ALenum param, ALfloat val);
@@ -120,6 +140,15 @@ void reverb_GetParamiv(ALeffect *effect, ALCcontext *context, ALenum param, ALin
void reverb_GetParamf(ALeffect *effect, ALCcontext *context, ALenum param, ALfloat *val);
void reverb_GetParamfv(ALeffect *effect, ALCcontext *context, ALenum param, ALfloat *vals);
+void chorus_SetParami(ALeffect *effect, ALCcontext *context, ALenum param, ALint val);
+void chorus_SetParamiv(ALeffect *effect, ALCcontext *context, ALenum param, const ALint *vals);
+void chorus_SetParamf(ALeffect *effect, ALCcontext *context, ALenum param, ALfloat val);
+void chorus_SetParamfv(ALeffect *effect, ALCcontext *context, ALenum param, const ALfloat *vals);
+void chorus_GetParami(ALeffect *effect, ALCcontext *context, ALenum param, ALint *val);
+void chorus_GetParamiv(ALeffect *effect, ALCcontext *context, ALenum param, ALint *vals);
+void chorus_GetParamf(ALeffect *effect, ALCcontext *context, ALenum param, ALfloat *val);
+void chorus_GetParamfv(ALeffect *effect, ALCcontext *context, ALenum param, ALfloat *vals);
+
void echo_SetParami(ALeffect *effect, ALCcontext *context, ALenum param, ALint val);
void echo_SetParamiv(ALeffect *effect, ALCcontext *context, ALenum param, const ALint *vals);
void echo_SetParamf(ALeffect *effect, ALCcontext *context, ALenum param, ALfloat val);
@@ -129,6 +158,15 @@ void echo_GetParamiv(ALeffect *effect, ALCcontext *context, ALenum param, ALint
void echo_GetParamf(ALeffect *effect, ALCcontext *context, ALenum param, ALfloat *val);
void echo_GetParamfv(ALeffect *effect, ALCcontext *context, ALenum param, ALfloat *vals);
+void flanger_SetParami(ALeffect *effect, ALCcontext *context, ALenum param, ALint val);
+void flanger_SetParamiv(ALeffect *effect, ALCcontext *context, ALenum param, const ALint *vals);
+void flanger_SetParamf(ALeffect *effect, ALCcontext *context, ALenum param, ALfloat val);
+void flanger_SetParamfv(ALeffect *effect, ALCcontext *context, ALenum param, const ALfloat *vals);
+void flanger_GetParami(ALeffect *effect, ALCcontext *context, ALenum param, ALint *val);
+void flanger_GetParamiv(ALeffect *effect, ALCcontext *context, ALenum param, ALint *vals);
+void flanger_GetParamf(ALeffect *effect, ALCcontext *context, ALenum param, ALfloat *val);
+void flanger_GetParamfv(ALeffect *effect, ALCcontext *context, ALenum param, ALfloat *vals);
+
void mod_SetParamf(ALeffect *effect, ALCcontext *context, ALenum param, ALfloat val);
void mod_SetParamfv(ALeffect *effect, ALCcontext *context, ALenum param, const ALfloat *vals);
void mod_SetParami(ALeffect *effect, ALCcontext *context, ALenum param, ALint val);