OLD | NEW |
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 147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
158 SAVE_STACK; | 158 SAVE_STACK; |
159 | 159 |
160 if (encControl->reducedDependency) | 160 if (encControl->reducedDependency) |
161 { | 161 { |
162 psEnc->state_Fxx[0].sCmn.first_frame_after_reset = 1; | 162 psEnc->state_Fxx[0].sCmn.first_frame_after_reset = 1; |
163 psEnc->state_Fxx[1].sCmn.first_frame_after_reset = 1; | 163 psEnc->state_Fxx[1].sCmn.first_frame_after_reset = 1; |
164 } | 164 } |
165 psEnc->state_Fxx[ 0 ].sCmn.nFramesEncoded = psEnc->state_Fxx[ 1 ].sCmn.nFram
esEncoded = 0; | 165 psEnc->state_Fxx[ 0 ].sCmn.nFramesEncoded = psEnc->state_Fxx[ 1 ].sCmn.nFram
esEncoded = 0; |
166 | 166 |
167 /* Check values in encoder control structure */ | 167 /* Check values in encoder control structure */ |
168 if( ( ret = check_control_input( encControl ) != 0 ) ) { | 168 if( ( ret = check_control_input( encControl ) ) != 0 ) { |
169 silk_assert( 0 ); | 169 silk_assert( 0 ); |
170 RESTORE_STACK; | 170 RESTORE_STACK; |
171 return ret; | 171 return ret; |
172 } | 172 } |
173 | 173 |
174 encControl->switchReady = 0; | 174 encControl->switchReady = 0; |
175 | 175 |
176 if( encControl->nChannelsInternal > psEnc->nChannelsInternal ) { | 176 if( encControl->nChannelsInternal > psEnc->nChannelsInternal ) { |
177 /* Mono -> Stereo transition: init state of second channel and stereo st
ate */ | 177 /* Mono -> Stereo transition: init state of second channel and stereo st
ate */ |
178 ret += silk_init_encoder( &psEnc->state_Fxx[ 1 ], psEnc->state_Fxx[ 0 ].
sCmn.arch ); | 178 ret += silk_init_encoder( &psEnc->state_Fxx[ 1 ], psEnc->state_Fxx[ 0 ].
sCmn.arch ); |
(...skipping 368 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
547 for( n = 0; n < encControl->nChannelsInternal; n++ ) { | 547 for( n = 0; n < encControl->nChannelsInternal; n++ ) { |
548 psEnc->state_Fxx[ n ].sCmn.controlled_since_last_payload = 0; | 548 psEnc->state_Fxx[ n ].sCmn.controlled_since_last_payload = 0; |
549 psEnc->state_Fxx[ n ].sCmn.prefillFlag = 0; | 549 psEnc->state_Fxx[ n ].sCmn.prefillFlag = 0; |
550 } | 550 } |
551 } | 551 } |
552 | 552 |
553 RESTORE_STACK; | 553 RESTORE_STACK; |
554 return ret; | 554 return ret; |
555 } | 555 } |
556 | 556 |
OLD | NEW |