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

Side by Side Diff: third_party/opus/src/silk/fixed/k2a_Q16_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
« no previous file with comments | « third_party/opus/src/silk/fixed/k2a_FIX.c ('k') | third_party/opus/src/silk/fixed/main_FIX.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 21 matching lines...) Expand all
32 #include "SigProc_FIX.h" 32 #include "SigProc_FIX.h"
33 33
34 /* Step up function, converts reflection coefficients to prediction coefficients */ 34 /* Step up function, converts reflection coefficients to prediction coefficients */
35 void silk_k2a_Q16( 35 void silk_k2a_Q16(
36 opus_int32 *A_Q24, /* O Prediction coefficie nts [order] Q24 */ 36 opus_int32 *A_Q24, /* O Prediction coefficie nts [order] Q24 */
37 const opus_int32 *rc_Q16, /* I Reflection coefficie nts [order] Q16 */ 37 const opus_int32 *rc_Q16, /* I Reflection coefficie nts [order] Q16 */
38 const opus_int32 order /* I Prediction order */ 38 const opus_int32 order /* I Prediction order */
39 ) 39 )
40 { 40 {
41 opus_int k, n; 41 opus_int k, n;
42 opus_int32 Atmp[ SILK_MAX_ORDER_LPC ]; 42 opus_int32 rc, tmp1, tmp2;
43 43
44 for( k = 0; k < order; k++ ) { 44 for( k = 0; k < order; k++ ) {
45 for( n = 0; n < k; n++ ) { 45 rc = rc_Q16[ k ];
46 Atmp[ n ] = A_Q24[ n ]; 46 for( n = 0; n < (k + 1) >> 1; n++ ) {
47 tmp1 = A_Q24[ n ];
48 tmp2 = A_Q24[ k - n - 1 ];
49 A_Q24[ n ] = silk_SMLAWW( tmp1, tmp2, rc );
50 A_Q24[ k - n - 1 ] = silk_SMLAWW( tmp2, tmp1, rc );
47 } 51 }
48 for( n = 0; n < k; n++ ) { 52 A_Q24[ k ] = -silk_LSHIFT( rc, 8 );
49 A_Q24[ n ] = silk_SMLAWW( A_Q24[ n ], Atmp[ k - n - 1 ], rc_Q16[ k ] );
50 }
51 A_Q24[ k ] = -silk_LSHIFT( rc_Q16[ k ], 8 );
52 } 53 }
53 } 54 }
OLDNEW
« no previous file with comments | « third_party/opus/src/silk/fixed/k2a_FIX.c ('k') | third_party/opus/src/silk/fixed/main_FIX.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698