From de8c5b18248ee5d121cbd4b34b9af94f5e16df35 Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Tue, 9 Jan 2018 23:21:16 -0800 Subject: Combine the chorus and flanger processing functions Given that they're nearly identical, it should be relatively simple to use the same effect state to process either of them, similar to the reverbs. The big differences seem to be the delay range (much shorter with flanger) and the defaults. --- OpenAL32/alEffect.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'OpenAL32/alEffect.c') diff --git a/OpenAL32/alEffect.c b/OpenAL32/alEffect.c index 6761e661..0dac429a 100644 --- a/OpenAL32/alEffect.c +++ b/OpenAL32/alEffect.c @@ -493,12 +493,12 @@ static void InitEffectParams(ALeffect *effect, ALenum type) SET_VTABLE1(ALequalizer, effect); break; case AL_EFFECT_FLANGER: - effect->Props.Flanger.Waveform = AL_FLANGER_DEFAULT_WAVEFORM; - effect->Props.Flanger.Phase = AL_FLANGER_DEFAULT_PHASE; - effect->Props.Flanger.Rate = AL_FLANGER_DEFAULT_RATE; - effect->Props.Flanger.Depth = AL_FLANGER_DEFAULT_DEPTH; - effect->Props.Flanger.Feedback = AL_FLANGER_DEFAULT_FEEDBACK; - effect->Props.Flanger.Delay = AL_FLANGER_DEFAULT_DELAY; + effect->Props.Chorus.Waveform = AL_FLANGER_DEFAULT_WAVEFORM; + effect->Props.Chorus.Phase = AL_FLANGER_DEFAULT_PHASE; + effect->Props.Chorus.Rate = AL_FLANGER_DEFAULT_RATE; + effect->Props.Chorus.Depth = AL_FLANGER_DEFAULT_DEPTH; + effect->Props.Chorus.Feedback = AL_FLANGER_DEFAULT_FEEDBACK; + effect->Props.Chorus.Delay = AL_FLANGER_DEFAULT_DELAY; SET_VTABLE1(ALflanger, effect); break; case AL_EFFECT_RING_MODULATOR: -- cgit v1.2.3