Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(21)

Side by Side Diff: third_party/opus/src/silk/fixed/warped_autocorrelation_FIX.c

Issue 2962373002: [Opus] Update to v1.2.1 (Closed)
Patch Set: Pre-increment instead of post-increment Created 3 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /*********************************************************************** 1 /***********************************************************************
2 Copyright (c) 2006-2011, Skype Limited. All rights reserved. 2 Copyright (c) 2006-2011, Skype Limited. All rights reserved.
3 Redistribution and use in source and binary forms, with or without 3 Redistribution and use in source and binary forms, with or without
4 modification, are permitted provided that the following conditions 4 modification, are permitted provided that the following conditions
5 are met: 5 are met:
6 - Redistributions of source code must retain the above copyright notice, 6 - Redistributions of source code must retain the above copyright notice,
7 this list of conditions and the following disclaimer. 7 this list of conditions and the following disclaimer.
8 - Redistributions in binary form must reproduce the above copyright 8 - Redistributions in binary form must reproduce the above copyright
9 notice, this list of conditions and the following disclaimer in the 9 notice, this list of conditions and the following disclaimer in the
10 documentation and/or other materials provided with the distribution. 10 documentation and/or other materials provided with the distribution.
(...skipping 13 matching lines...) Expand all
24 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 24 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
25 POSSIBILITY OF SUCH DAMAGE. 25 POSSIBILITY OF SUCH DAMAGE.
26 ***********************************************************************/ 26 ***********************************************************************/
27 27
28 #ifdef HAVE_CONFIG_H 28 #ifdef HAVE_CONFIG_H
29 #include "config.h" 29 #include "config.h"
30 #endif 30 #endif
31 31
32 #include "main_FIX.h" 32 #include "main_FIX.h"
33 33
34 #define QC 10
35 #define QS 14
36
37 #if defined(MIPSr1_ASM) 34 #if defined(MIPSr1_ASM)
38 #include "mips/warped_autocorrelation_FIX_mipsr1.h" 35 #include "mips/warped_autocorrelation_FIX_mipsr1.h"
39 #endif 36 #endif
40 37
41 38
42 #ifndef OVERRIDE_silk_warped_autocorrelation_FIX
43 /* Autocorrelations for a warped frequency axis */ 39 /* Autocorrelations for a warped frequency axis */
44 void silk_warped_autocorrelation_FIX( 40 void silk_warped_autocorrelation_FIX_c(
45 opus_int32 *corr, /* O Result [order + 1] */ 41 opus_int32 *corr, /* O Result [order + 1] */
46 opus_int *scale, /* O Scaling of the correlation vector */ 42 opus_int *scale, /* O Scaling of the correlation vector */
47 const opus_int16 *input, /* I Input data to correlate */ 43 const opus_int16 *input, /* I Input data to correlate */
48 const opus_int warping_Q16, /* I Warping coefficient */ 44 const opus_int warping_Q16, /* I Warping coefficient */
49 const opus_int length, /* I Length of input */ 45 const opus_int length, /* I Length of input */
50 const opus_int order /* I Correlation order (even) */ 46 const opus_int order /* I Correlation order (even) */
51 ) 47 )
52 { 48 {
53 opus_int n, i, lsh; 49 opus_int n, i, lsh;
54 opus_int32 tmp1_QS, tmp2_QS; 50 opus_int32 tmp1_QS, tmp2_QS;
(...skipping 30 matching lines...) Expand all
85 for( i = 0; i < order + 1; i++ ) { 81 for( i = 0; i < order + 1; i++ ) {
86 corr[ i ] = (opus_int32)silk_CHECK_FIT32( silk_LSHIFT64( corr_QC[ i ], lsh ) ); 82 corr[ i ] = (opus_int32)silk_CHECK_FIT32( silk_LSHIFT64( corr_QC[ i ], lsh ) );
87 } 83 }
88 } else { 84 } else {
89 for( i = 0; i < order + 1; i++ ) { 85 for( i = 0; i < order + 1; i++ ) {
90 corr[ i ] = (opus_int32)silk_CHECK_FIT32( silk_RSHIFT64( corr_QC[ i ], -lsh ) ); 86 corr[ i ] = (opus_int32)silk_CHECK_FIT32( silk_RSHIFT64( corr_QC[ i ], -lsh ) );
91 } 87 }
92 } 88 }
93 silk_assert( corr_QC[ 0 ] >= 0 ); /* If breaking, decrease QC*/ 89 silk_assert( corr_QC[ 0 ] >= 0 ); /* If breaking, decrease QC*/
94 } 90 }
95 #endif /* OVERRIDE_silk_warped_autocorrelation_FIX */
OLDNEW
« no previous file with comments | « third_party/opus/src/silk/fixed/structs_FIX.h ('k') | third_party/opus/src/silk/fixed/x86/prefilter_FIX_sse.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698