From 80e7b82bad5eba1e2067e06405cf81e6d637adaf Mon Sep 17 00:00:00 2001 From: Billy Laws Date: Wed, 15 Jul 2020 15:19:15 +0100 Subject: [PATCH] Fix the LUT shift in the audio resampler We do not need to shift back as we use a struct to hold the LUT entries. --- app/src/main/cpp/skyline/audio/resampler.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/cpp/skyline/audio/resampler.cpp b/app/src/main/cpp/skyline/audio/resampler.cpp index c3ec7cdc..a2cdd24a 100644 --- a/app/src/main/cpp/skyline/audio/resampler.cpp +++ b/app/src/main/cpp/skyline/audio/resampler.cpp @@ -135,7 +135,7 @@ namespace skyline::audio { }(); for (size_t outIndex = 0, inIndex = 0; outIndex < outputSize; outIndex += channelCount) { - auto lutIndex = (fraction >> 8) << 2; + auto lutIndex = fraction >> 8; for (u8 channel = 0; channel < channelCount; channel++) { i32 data = inputBuffer[(inIndex + 0) * channelCount + channel] * lut[lutIndex].a +