diff options
author | Chris Robinson <[email protected]> | 2011-05-20 09:36:36 -0700 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2011-05-20 09:36:36 -0700 |
commit | 35a0430c8134c6a13768cd6bf7b252d24ac9e2aa (patch) | |
tree | ddc1e3d248e7a257c4534bfc12943766e2d5d38c /Alc/alcEcho.c | |
parent | 1b5caa4112bf76d6b046d33a65d29d94daf03f43 (diff) |
Store the separate effect parameters in a union
Diffstat (limited to 'Alc/alcEcho.c')
-rw-r--r-- | Alc/alcEcho.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/Alc/alcEcho.c b/Alc/alcEcho.c index 35b94a90..aea2b00a 100644 --- a/Alc/alcEcho.c +++ b/Alc/alcEcho.c @@ -107,18 +107,18 @@ static ALvoid EchoUpdate(ALeffectState *effect, ALCcontext *Context, const ALeff ALuint frequency = Context->Device->Frequency; ALfloat lrpan, cw, g; - state->Tap[0].delay = (ALuint)(Effect->Echo.Delay * frequency) + 1; - state->Tap[1].delay = (ALuint)(Effect->Echo.LRDelay * frequency); + state->Tap[0].delay = (ALuint)(Effect->Params.Echo.Delay * frequency) + 1; + state->Tap[1].delay = (ALuint)(Effect->Params.Echo.LRDelay * frequency); state->Tap[1].delay += state->Tap[0].delay; - lrpan = Effect->Echo.Spread*0.5f + 0.5f; + lrpan = Effect->Params.Echo.Spread*0.5f + 0.5f; state->GainL = aluSqrt( lrpan); state->GainR = aluSqrt(1.0f-lrpan); - state->FeedGain = Effect->Echo.Feedback; + state->FeedGain = Effect->Params.Echo.Feedback; cw = cos(2.0*M_PI * LOWPASSFREQCUTOFF / frequency); - g = 1.0f - Effect->Echo.Damping; + g = 1.0f - Effect->Params.Echo.Damping; state->iirFilter.coeff = lpCoeffCalc(g, cw); } |