summaryrefslogtreecommitdiffstats
path: root/services/audioflinger/AudioResamplerSinc.h
diff options
context:
space:
mode:
authorMathias Agopian <mathias@google.com>2012-11-04 02:03:49 -0800
committerMathias Agopian <mathias@google.com>2012-11-05 01:03:43 -0800
commite8299af5665bf9c396466c33b9b16a84fe78c7f6 (patch)
treef3356a4917a4ec9827d70bc9acf80feac7c1360c /services/audioflinger/AudioResamplerSinc.h
parent50ebdf2086b645b9b703a6d489238767a9afb34f (diff)
downloadframeworks_av-e8299af5665bf9c396466c33b9b16a84fe78c7f6.zip
frameworks_av-e8299af5665bf9c396466c33b9b16a84fe78c7f6.tar.gz
frameworks_av-e8299af5665bf9c396466c33b9b16a84fe78c7f6.tar.bz2
change how we store the FIR coefficients
The coefficient table is now transposed and shows much better its polyphase nature: we now have a FIR per line, each line corresponding to a phase. This doesn't change at all the results produced by the filter, but allows us to make slightly better use of the data cache and improves performance a bit (although not as much as I thought it would). The main benefit is that it is the first step before we can make much larger optimizations (like using NEON). Change-Id: Iebf7695825dcbd41f25861efcaefbaa3365ecb43
Diffstat (limited to 'services/audioflinger/AudioResamplerSinc.h')
-rw-r--r--services/audioflinger/AudioResamplerSinc.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/services/audioflinger/AudioResamplerSinc.h b/services/audioflinger/AudioResamplerSinc.h
index 3a6e356..1b14019 100644
--- a/services/audioflinger/AudioResamplerSinc.h
+++ b/services/audioflinger/AudioResamplerSinc.h
@@ -55,7 +55,8 @@ private:
template<int CHANNELS>
inline void interpolate(
int32_t& l, int32_t& r,
- const int32_t* coefs, int16_t lerp, const int16_t* samples);
+ const int32_t* coefs, size_t offset,
+ int32_t lerp, const int16_t* samples);
template<int CHANNELS>
inline void read(int16_t*& impulse, uint32_t& phaseFraction,