diff options
author | William Wilgus <me.theuser@yahoo.com> | 2019-01-04 02:01:18 -0600 |
---|---|---|
committer | Solomon Peachy <pizza@shaftnet.org> | 2021-04-23 14:23:04 +0000 |
commit | 14c6bb798d6bebc80f07e863236adbaf8d156a9c (patch) | |
tree | 551a4b641906c2626af844fa3239c1b2b1ff0ad3 /lib/rbcodec/codecs/libopus/silk/resampler.c | |
parent | 75d93937965ec4df70d37df6d4feea04577c996b (diff) | |
download | rockbox-14c6bb798d6bebc80f07e863236adbaf8d156a9c.tar.gz rockbox-14c6bb798d6bebc80f07e863236adbaf8d156a9c.zip |
Sync opus codec to upstream git
Change-Id: I0cfcc0005c4ad7bfbb1aaf454188ce70fb043dc1
Diffstat (limited to 'lib/rbcodec/codecs/libopus/silk/resampler.c')
-rw-r--r-- | lib/rbcodec/codecs/libopus/silk/resampler.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/rbcodec/codecs/libopus/silk/resampler.c b/lib/rbcodec/codecs/libopus/silk/resampler.c index 374fbb3722..1f11e50891 100644 --- a/lib/rbcodec/codecs/libopus/silk/resampler.c +++ b/lib/rbcodec/codecs/libopus/silk/resampler.c | |||
@@ -91,14 +91,14 @@ opus_int silk_resampler_init( | |||
91 | if( forEnc ) { | 91 | if( forEnc ) { |
92 | if( ( Fs_Hz_in != 8000 && Fs_Hz_in != 12000 && Fs_Hz_in != 16000 && Fs_Hz_in != 24000 && Fs_Hz_in != 48000 ) || | 92 | if( ( Fs_Hz_in != 8000 && Fs_Hz_in != 12000 && Fs_Hz_in != 16000 && Fs_Hz_in != 24000 && Fs_Hz_in != 48000 ) || |
93 | ( Fs_Hz_out != 8000 && Fs_Hz_out != 12000 && Fs_Hz_out != 16000 ) ) { | 93 | ( Fs_Hz_out != 8000 && Fs_Hz_out != 12000 && Fs_Hz_out != 16000 ) ) { |
94 | silk_assert( 0 ); | 94 | celt_assert( 0 ); |
95 | return -1; | 95 | return -1; |
96 | } | 96 | } |
97 | S->inputDelay = delay_matrix_enc[ rateID( Fs_Hz_in ) ][ rateID( Fs_Hz_out ) ]; | 97 | S->inputDelay = delay_matrix_enc[ rateID( Fs_Hz_in ) ][ rateID( Fs_Hz_out ) ]; |
98 | } else { | 98 | } else { |
99 | if( ( Fs_Hz_in != 8000 && Fs_Hz_in != 12000 && Fs_Hz_in != 16000 ) || | 99 | if( ( Fs_Hz_in != 8000 && Fs_Hz_in != 12000 && Fs_Hz_in != 16000 ) || |
100 | ( Fs_Hz_out != 8000 && Fs_Hz_out != 12000 && Fs_Hz_out != 16000 && Fs_Hz_out != 24000 && Fs_Hz_out != 48000 ) ) { | 100 | ( Fs_Hz_out != 8000 && Fs_Hz_out != 12000 && Fs_Hz_out != 16000 && Fs_Hz_out != 24000 && Fs_Hz_out != 48000 ) ) { |
101 | silk_assert( 0 ); | 101 | celt_assert( 0 ); |
102 | return -1; | 102 | return -1; |
103 | } | 103 | } |
104 | S->inputDelay = delay_matrix_dec[ rateID( Fs_Hz_in ) ][ rateID( Fs_Hz_out ) ]; | 104 | S->inputDelay = delay_matrix_dec[ rateID( Fs_Hz_in ) ][ rateID( Fs_Hz_out ) ]; |
@@ -151,7 +151,7 @@ opus_int silk_resampler_init( | |||
151 | S->Coefs = silk_Resampler_1_6_COEFS; | 151 | S->Coefs = silk_Resampler_1_6_COEFS; |
152 | } else { | 152 | } else { |
153 | /* None available */ | 153 | /* None available */ |
154 | silk_assert( 0 ); | 154 | celt_assert( 0 ); |
155 | return -1; | 155 | return -1; |
156 | } | 156 | } |
157 | } else { | 157 | } else { |
@@ -181,9 +181,9 @@ opus_int silk_resampler( | |||
181 | opus_int nSamples; | 181 | opus_int nSamples; |
182 | 182 | ||
183 | /* Need at least 1 ms of input data */ | 183 | /* Need at least 1 ms of input data */ |
184 | silk_assert( inLen >= S->Fs_in_kHz ); | 184 | celt_assert( inLen >= S->Fs_in_kHz ); |
185 | /* Delay can't exceed the 1 ms of buffering */ | 185 | /* Delay can't exceed the 1 ms of buffering */ |
186 | silk_assert( S->inputDelay <= S->Fs_in_kHz ); | 186 | celt_assert( S->inputDelay <= S->Fs_in_kHz ); |
187 | 187 | ||
188 | nSamples = S->Fs_in_kHz - S->inputDelay; | 188 | nSamples = S->Fs_in_kHz - S->inputDelay; |
189 | 189 | ||