From 60eb7d88b4eace91395e553cf70fc4578a950353 Mon Sep 17 00:00:00 2001 From: Linfeng Zhang Date: Thu, 1 Sep 2016 13:44:11 -0700 Subject: Update silk_biquad_alt() Split to silk_biquad_alt_stride1() and silk_biquad_alt_stride2(), so that it can be optimized more efficiently when stride is 2. This change in C code is bit exact with the origin. Change-Id: Idaefe670397016ace2a489e3435ac61b7dbe79d5 Signed-off-by: Jean-Marc Valin --- src/opus_encoder.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/opus_encoder.c b/src/opus_encoder.c index 10bb62d5..62dadcfb 100644 --- a/src/opus_encoder.c +++ b/src/opus_encoder.c @@ -364,9 +364,10 @@ static void hp_cutoff(const opus_val16 *in, opus_int32 cutoff_Hz, opus_val16 *ou A_Q28[ 1 ] = silk_SMULWW( r_Q22, r_Q22 ); #ifdef FIXED_POINT - silk_biquad_alt( in, B_Q28, A_Q28, hp_mem, out, len, channels ); - if( channels == 2 ) { - silk_biquad_alt( in+1, B_Q28, A_Q28, hp_mem+2, out+1, len, channels ); + if( channels == 1 ) { + silk_biquad_alt_stride1( in, B_Q28, A_Q28, hp_mem, out, len ); + } else { + silk_biquad_alt_stride2( in, B_Q28, A_Q28, hp_mem, out, len ); } #else silk_biquad_float( in, B_Q28, A_Q28, hp_mem, out, len, channels ); -- cgit v1.2.3