aboutsummaryrefslogtreecommitdiffstats
path: root/Alc/effects/autowah.c
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2016-05-13 18:28:01 -0700
committerChris Robinson <[email protected]>2016-05-13 18:28:01 -0700
commit93a94d177c4bb0b9c8feb85420a388d32df4cc8f (patch)
tree9a395a1ce06ed8e6057c6b74ae520f8140fa977e /Alc/effects/autowah.c
parent59cd6230a661d5cee69c0a44c4dde152eed9f865 (diff)
Get rid of an unnecessary copy of ALeffectProps
Diffstat (limited to 'Alc/effects/autowah.c')
-rw-r--r--Alc/effects/autowah.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/Alc/effects/autowah.c b/Alc/effects/autowah.c
index 1e7a8e29..648afc83 100644
--- a/Alc/effects/autowah.c
+++ b/Alc/effects/autowah.c
@@ -64,17 +64,17 @@ static ALboolean ALautowahState_deviceUpdate(ALautowahState *state, ALCdevice *d
return AL_TRUE;
}
-static ALvoid ALautowahState_update(ALautowahState *state, const ALCdevice *device, const ALeffectslot *slot)
+static ALvoid ALautowahState_update(ALautowahState *state, const ALCdevice *device, const ALeffectslot *slot, const ALeffectProps *props)
{
ALfloat attackTime, releaseTime;
- attackTime = slot->Params.EffectProps.Autowah.AttackTime * state->Frequency;
- releaseTime = slot->Params.EffectProps.Autowah.ReleaseTime * state->Frequency;
+ attackTime = props->Autowah.AttackTime * state->Frequency;
+ releaseTime = props->Autowah.ReleaseTime * state->Frequency;
state->AttackRate = powf(1.0f/GAIN_SILENCE_THRESHOLD, 1.0f/attackTime);
state->ReleaseRate = powf(GAIN_SILENCE_THRESHOLD/1.0f, 1.0f/releaseTime);
- state->PeakGain = slot->Params.EffectProps.Autowah.PeakGain;
- state->Resonance = slot->Params.EffectProps.Autowah.Resonance;
+ state->PeakGain = props->Autowah.PeakGain;
+ state->Resonance = props->Autowah.Resonance;
ComputeAmbientGains(device->Dry, slot->Params.Gain, state->Gain);
}