diff options
author | Chris Robinson <[email protected]> | 2018-02-17 18:16:39 -0800 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2018-02-18 23:56:51 -0800 |
commit | b5aa0c07599ce8e8fd17e4ec1a686f3cf0576458 (patch) | |
tree | 3015c6dc50ebc7e9e48dc2b4d18af84eaabdf038 /Alc/effects/distortion.c | |
parent | 79604c3c0e0f3f71832a09348cc273a38882cc3e (diff) |
Remove the unnecessary ComputeAmbientGains
Diffstat (limited to 'Alc/effects/distortion.c')
-rw-r--r-- | Alc/effects/distortion.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Alc/effects/distortion.c b/Alc/effects/distortion.c index dcb2bfe4..6ee89594 100644 --- a/Alc/effects/distortion.c +++ b/Alc/effects/distortion.c @@ -77,6 +77,7 @@ static ALvoid ALdistortionState_update(ALdistortionState *state, const ALCcontex { const ALCdevice *device = context->Device; ALfloat frequency = (ALfloat)device->Frequency; + ALfloat coeffs[MAX_AMBI_COEFFS]; ALfloat bandwidth; ALfloat cutoff; ALfloat edge; @@ -103,7 +104,9 @@ static ALvoid ALdistortionState_update(ALdistortionState *state, const ALCcontex cutoff / (frequency*4.0f), calc_rcpQ_from_bandwidth(cutoff / (frequency*4.0f), bandwidth) ); - ComputeAmbientGains(&device->Dry, slot->Params.Gain * props->Distortion.Gain, state->Gain); + CalcAngleCoeffs(0.0f, 0.0f, 0.0f, coeffs); + ComputeDryPanGains(&device->Dry, coeffs, slot->Params.Gain * props->Distortion.Gain, + state->Gain); } static ALvoid ALdistortionState_process(ALdistortionState *state, ALsizei SamplesToDo, const ALfloat (*restrict SamplesIn)[BUFFERSIZE], ALfloat (*restrict SamplesOut)[BUFFERSIZE], ALsizei NumChannels) |