From ed9408e53799cefd527bd3079bf1940d5c35bfc9 Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Thu, 18 Aug 2022 20:37:19 -0700 Subject: Inline and precompute some CalcDirectionCoeffs calls --- alc/effects/pshifter.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'alc/effects/pshifter.cpp') diff --git a/alc/effects/pshifter.cpp b/alc/effects/pshifter.cpp index fe116222..b1f6d859 100644 --- a/alc/effects/pshifter.cpp +++ b/alc/effects/pshifter.cpp @@ -140,7 +140,7 @@ void PshifterState::update(const ContextBase*, const EffectSlot *slot, mPitchShiftI = fastf2u(pitch*MixerFracOne); mPitchShift = mPitchShiftI * double{1.0/MixerFracOne}; - const auto coeffs = CalcDirectionCoeffs({0.0f, 0.0f, -1.0f}, 0.0f); + static constexpr auto coeffs = CalcDirectionCoeffs({0.0f, 0.0f, -1.0f}); mOutTarget = target.Main->Buffer; ComputePanGains(target.Main, coeffs.data(), slot->Gain, mTargetGains); -- cgit v1.2.3