Line data Source code
1 : /******************************************************************************************************
2 :
3 : (C) 2022-2025 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB,
4 : Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD.,
5 : Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange,
6 : Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other
7 : contributors to this repository. All Rights Reserved.
8 :
9 : This software is protected by copyright law and by international treaties.
10 : The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB,
11 : Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD.,
12 : Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange,
13 : Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other
14 : contributors to this repository retain full ownership rights in their respective contributions in
15 : the software. This notice grants no license of any kind, including but not limited to patent
16 : license, nor is any license granted by implication, estoppel or otherwise.
17 :
18 : Contributors are required to enter into the IVAS codec Public Collaboration agreement before making
19 : contributions.
20 :
21 : This software is provided "AS IS", without any express or implied warranties. The software is in the
22 : development stage. It is intended exclusively for experts who have experience with such software and
23 : solely for the purpose of inspection. All implied warranties of non-infringement, merchantability
24 : and fitness for a particular purpose are hereby disclaimed and excluded.
25 :
26 : Any dispute, controversy or claim arising under or in relation to providing this software shall be
27 : submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in
28 : accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and
29 : the United Nations Convention on Contracts on the International Sales of Goods.
30 :
31 : *******************************************************************************************************/
32 :
33 : /*====================================================================================
34 : EVS Codec 3GPP TS26.443 Nov 04, 2021. Version 12.14.0 / 13.10.0 / 14.6.0 / 15.4.0 / 16.3.0
35 : ====================================================================================*/
36 :
37 : #include <assert.h>
38 : #include <stdint.h>
39 : #include "options.h"
40 : #include <math.h>
41 : #include "cnst.h"
42 : #include "rom_enc.h"
43 : #include "stl.h"
44 : #include "basop_util.h"
45 : #include "prot.h"
46 : #include "rom_com.h"
47 : #include "wmc_auto.h"
48 :
49 : /*-------------------------------------------------------------------*
50 : * EncodeIndex()
51 : *
52 : *
53 : *-------------------------------------------------------------------*/
54 :
55 292037 : int16_t EncodeIndex(
56 : const int16_t Bandwidth,
57 : int16_t PeriodicityIndex,
58 : BSTR_ENC_HANDLE hBstr )
59 : {
60 292037 : if ( PeriodicityIndex & kLtpHmFlag )
61 : {
62 189385 : int16_t LtpPitchIndex = PeriodicityIndex >> 9;
63 189385 : assert( 0 <= LtpPitchIndex && LtpPitchIndex <= 16 );
64 189385 : --PeriodicityIndex;
65 189385 : assert( ( PeriodicityIndex & 0xff ) < ( 1 << NumRatioBits[Bandwidth][LtpPitchIndex] ) );
66 :
67 189385 : push_next_indice( hBstr, PeriodicityIndex & 0xff, NumRatioBits[Bandwidth][LtpPitchIndex] );
68 189385 : return NumRatioBits[Bandwidth][LtpPitchIndex];
69 : }
70 : else
71 : {
72 102652 : push_next_indice( hBstr, PeriodicityIndex, 8 );
73 102652 : return 8;
74 : }
75 : }
76 :
77 :
78 : /*-------------------------------------------------------------------*
79 : * GetWeight()
80 : *
81 : *
82 : *-------------------------------------------------------------------*/
83 :
84 8709722856 : static float GetWeight( int16_t i )
85 : {
86 8709722856 : i = 3 * i - 2;
87 :
88 8709722856 : return (float) ( pow( i, 0.3 ) / pow( 256 - 1, 0.3 ) );
89 : }
90 :
91 :
92 : /*-------------------------------------------------------------------*
93 : * SearchPeriodicityIndex_Single()
94 : *
95 : *
96 : *-------------------------------------------------------------------*/
97 :
98 215634091 : static float SearchPeriodicityIndex_Single(
99 : const float AbsMdct3[],
100 : const int16_t NumToConsider,
101 : const int32_t Lag,
102 : const int16_t FractionalResolution )
103 : {
104 : int16_t HighestMultiplier;
105 : float AbsMeanCurrent3; /* Mean for BucketWidth == 3 */
106 : int32_t Limit, OldIndex, i;
107 :
108 215634091 : Limit = ( NumToConsider - 1 ) << FractionalResolution;
109 215634091 : AbsMeanCurrent3 = 0;
110 215634091 : HighestMultiplier = 1;
111 :
112 8925356947 : for ( i = Lag; i < Limit; i += Lag )
113 : {
114 8709722856 : OldIndex = i >> FractionalResolution;
115 8709722856 : AbsMeanCurrent3 += AbsMdct3[OldIndex] * GetWeight( HighestMultiplier );
116 8709722856 : ++HighestMultiplier;
117 : }
118 :
119 215634091 : return AbsMeanCurrent3 / ( HighestMultiplier - 1 + 0.00001f );
120 : }
121 :
122 :
123 : /*-------------------------------------------------------------------*
124 : * SearchPeriodicityIndex_Range()
125 : *
126 : *
127 : *-------------------------------------------------------------------*/
128 :
129 9127133 : static void SearchPeriodicityIndex_Range(
130 : const float AbsMdct3[],
131 : const int16_t NumToConsider,
132 : const int16_t Lo,
133 : const int16_t Hi,
134 : const int16_t FractionalResolution,
135 : const int16_t Adj,
136 : const int16_t Spacing,
137 : int16_t *PeriodicityIndex,
138 : float *Score )
139 : {
140 : int16_t Index, BestIndex, B;
141 : float CurrentScore, BestScore;
142 :
143 9127133 : BestScore = -1e30f;
144 9127133 : BestIndex = 0;
145 :
146 192541965 : for ( Index = Lo; Index < Hi; Index += Spacing )
147 : {
148 183414832 : CurrentScore = SearchPeriodicityIndex_Single( AbsMdct3, NumToConsider, Index + Adj, FractionalResolution );
149 :
150 183414832 : if ( CurrentScore > BestScore )
151 : {
152 27741294 : BestScore = CurrentScore;
153 27741294 : BestIndex = Index;
154 : }
155 : }
156 :
157 9127133 : if ( BestScore > *Score )
158 : {
159 2616293 : *Score = BestScore;
160 2616293 : *PeriodicityIndex = BestIndex;
161 : }
162 :
163 :
164 9127133 : B = BestIndex - ( Spacing >> 1 );
165 9127133 : B = max( Lo, B );
166 :
167 16911065 : for ( Index = B; Index < BestIndex; ++Index )
168 : {
169 7783932 : CurrentScore = SearchPeriodicityIndex_Single( AbsMdct3, NumToConsider, Index + Adj, FractionalResolution );
170 :
171 7783932 : if ( CurrentScore > *Score )
172 : {
173 528705 : *Score = CurrentScore;
174 528705 : *PeriodicityIndex = Index;
175 : }
176 : }
177 :
178 9127133 : B = BestIndex + ( Spacing >> 1 );
179 :
180 20137829 : for ( Index = BestIndex + 1; Index <= B; ++Index )
181 : {
182 11010696 : CurrentScore = SearchPeriodicityIndex_Single( AbsMdct3, NumToConsider, Index + Adj, FractionalResolution );
183 :
184 11010696 : if ( CurrentScore > *Score )
185 : {
186 1105204 : *Score = CurrentScore;
187 1105204 : *PeriodicityIndex = Index;
188 : }
189 : }
190 :
191 9127133 : return;
192 : }
193 :
194 :
195 : /*-------------------------------------------------------------------*
196 : * SearchPeriodicityIndex()
197 : *
198 : *
199 : *-------------------------------------------------------------------*/
200 :
201 : /*! r: PeriodicityIndex */
202 2480894 : int16_t SearchPeriodicityIndex(
203 : const float Mdct[], /* i : Coefficients, Mdct[0..NumCoeffs-1] */
204 : const float UnfilteredMdct[], /* i : Unfiltered coefficients, UnfilteredMdct[0..NumCoeffs-1] */
205 : const int16_t NumCoeffs, /* i : Number of coefficients */
206 : const int16_t TargetBits, /* i : Target bit budget (excl. Done flag) */
207 : const int16_t LtpPitchLag, /* i : TCX-LTP pitch */
208 : const float LtpGain, /* i : LTP gain */
209 : float *RelativeScore /* o : Energy concentration factor */
210 : )
211 : {
212 2480894 : float AbsMdct3[MAX_LENGTH], A, B, C = 0.f;
213 : int16_t i;
214 : int16_t MaxAt;
215 : float Score;
216 : int16_t PeriodicityIndex;
217 : int16_t NumToConsider;
218 : float AbsTotal;
219 :
220 2480894 : PeriodicityIndex = 0;
221 2480894 : NumToConsider = NumCoeffs;
222 2480894 : Score = -1e30f;
223 :
224 2480894 : A = (float) fabs( Mdct[0] );
225 2480894 : B = (float) fabs( Mdct[1] );
226 :
227 649041833 : for ( i = 1; i < NumToConsider - 3; i += 3 )
228 : {
229 646560939 : C = (float) fabs( Mdct[i + 1] );
230 646560939 : AbsMdct3[i] = A + B + C;
231 :
232 646560939 : A = (float) fabs( Mdct[i + 2] );
233 646560939 : AbsMdct3[i + 1] = A + B + C;
234 :
235 646560939 : B = (float) fabs( Mdct[i + 3] );
236 646560939 : AbsMdct3[i + 2] = A + B + C;
237 : }
238 :
239 2480894 : if ( i < NumToConsider - 1 )
240 : {
241 2230338 : C = (float) fabs( Mdct[i + 1] );
242 2230338 : AbsMdct3[i] = A + B + C;
243 : }
244 :
245 :
246 2480894 : if ( i + 1 < NumToConsider - 1 )
247 : {
248 828097 : A = (float) fabs( Mdct[i + 2] );
249 828097 : AbsMdct3[i + 1] = A + B + C;
250 : }
251 :
252 2480894 : AbsTotal = 0.0f;
253 :
254 2480894 : if ( UnfilteredMdct != NULL )
255 : {
256 127170215 : for ( i = 0; i < NumToConsider; ++i )
257 : {
258 126953280 : AbsTotal += (float) fabs( UnfilteredMdct[i] );
259 : }
260 : }
261 : else
262 : {
263 608822079 : for ( i = 1; i < NumToConsider - 1; i += 3 )
264 : {
265 606558120 : AbsTotal += AbsMdct3[i];
266 : }
267 : }
268 :
269 :
270 2480894 : if ( ( LtpPitchLag > 0 ) && ( LtpGain > kLtpHmGainThr ) )
271 645778 : {
272 645778 : int16_t FractionalResolution = kLtpHmFractionalResolution;
273 : int16_t Multiplier, LtpPitchIndex, Bandwidth;
274 :
275 645778 : Bandwidth = NumCoeffs >= 256;
276 645778 : LtpPitchIndex = ( ( LtpPitchLag + ( 1 << ( kLtpHmFractionalResolution - 1 ) ) ) >> kLtpHmFractionalResolution ) - 2;
277 645778 : assert( 0 <= LtpPitchIndex && LtpPitchIndex <= 16 );
278 :
279 14148422 : for ( Multiplier = 1; Multiplier <= ( 1 << NumRatioBits[Bandwidth][LtpPitchIndex] ); ++Multiplier )
280 : {
281 : float CurrentScore;
282 : int32_t Lag;
283 :
284 13502644 : Lag = ( LtpPitchLag * (int16_t) ( 4 * Ratios[Bandwidth][LtpPitchIndex][Multiplier - 1] ) ) >> 2;
285 :
286 13502644 : if ( Lag >= ( 4 << FractionalResolution ) && ( Lag <= ( ( NumToConsider - 2 ) << FractionalResolution ) ) )
287 : {
288 13424631 : CurrentScore = SearchPeriodicityIndex_Single( AbsMdct3, NumToConsider, Lag, FractionalResolution );
289 :
290 13424631 : if ( CurrentScore > Score )
291 : {
292 1184865 : Score = CurrentScore;
293 1184865 : PeriodicityIndex = Multiplier | kLtpHmFlag;
294 : }
295 : }
296 : }
297 645778 : PeriodicityIndex |= LtpPitchIndex << 9;
298 : }
299 : else
300 : {
301 1835116 : if ( UnfilteredMdct != NULL )
302 : {
303 105402 : MaxAt = 1;
304 105402 : A = AbsMdct3[1];
305 :
306 20892816 : for ( i = 4; i < NumToConsider - 1; i += 3 )
307 : {
308 :
309 20787414 : if ( AbsMdct3[i] > AbsMdct3[MaxAt] )
310 : {
311 131110 : MaxAt = i;
312 : }
313 20787414 : A += AbsMdct3[i];
314 : }
315 :
316 105402 : if ( AbsMdct3[MaxAt] > A * 0.7f )
317 : {
318 2016 : NumToConsider = min( NumToConsider, MaxAt + 4 );
319 : }
320 : }
321 :
322 1835116 : SearchPeriodicityIndex_Range( AbsMdct3, NumToConsider, 0, 16, 3, GET_ADJ2( 0, 6, 3 ), 4, &PeriodicityIndex, &Score );
323 :
324 1835116 : SearchPeriodicityIndex_Range( AbsMdct3, NumToConsider, 16, 80, 4, GET_ADJ2( 16, 8, 4 ), 4, &PeriodicityIndex, &Score );
325 :
326 1835116 : SearchPeriodicityIndex_Range( AbsMdct3, NumToConsider, 80, 208, 3, GET_ADJ2( 80, 12, 3 ), 4, &PeriodicityIndex, &Score );
327 :
328 1835116 : if ( NumToConsider <= 128 )
329 : {
330 : /* no long lags for band-limited MDCTs */
331 :
332 2016 : SearchPeriodicityIndex_Range( AbsMdct3, NumToConsider, 208, 88 + NumToConsider, 0, GET_ADJ2( 224, 188, 0 ), 1, &PeriodicityIndex, &Score );
333 : }
334 : else
335 : {
336 :
337 1833100 : if ( TargetBits > kSmallerLagsTargetBitsThreshold && NumCoeffs >= 256 )
338 : {
339 1786669 : SearchPeriodicityIndex_Range( AbsMdct3, NumToConsider, 208, 224, 1, GET_ADJ2( 208, 28, 1 ), 1, &PeriodicityIndex, &Score );
340 :
341 1786669 : SearchPeriodicityIndex_Range( AbsMdct3, NumToConsider, 224, 256, 0, GET_ADJ2( 224, 188, 0 ), 1, &PeriodicityIndex, &Score );
342 : }
343 : else
344 : {
345 46431 : SearchPeriodicityIndex_Range( AbsMdct3, NumToConsider, 208, 256, 1, GET_ADJ2( 208, 28, 1 ), 1, &PeriodicityIndex, &Score );
346 : }
347 : }
348 : }
349 :
350 2480894 : if ( AbsTotal > 0 )
351 : {
352 2373081 : *RelativeScore = Score / AbsTotal * (float) NumCoeffs;
353 : }
354 : else
355 : {
356 107813 : *RelativeScore = 0;
357 : }
358 :
359 2480894 : return PeriodicityIndex;
360 : }
361 :
362 :
363 : /*-------------------------------------------------------------------*
364 : * PeakFilter()
365 : *
366 : *
367 : *-------------------------------------------------------------------*/
368 :
369 : #define kPeakElevationThreshold 1.0f
370 :
371 216935 : static void PeakFilter(
372 : const float x[], /* (I) absolute spectrum */
373 : float y[], /* (O) filtered absolute spectrum, must not alias x[] */
374 : const int16_t L_frame /* (I) number of spectral lines */
375 : )
376 : {
377 : int16_t flen, i;
378 : float a, m;
379 :
380 216935 : flen = ( L_frame >> 4 );
381 216935 : m = kPeakElevationThreshold / (float) ( 2 * flen + 1 );
382 :
383 216935 : a = 0.0f;
384 8151515 : for ( i = 0; i < flen; ++i )
385 : {
386 7934580 : a += x[i];
387 : }
388 :
389 8151515 : for ( i = 0; i < flen; ++i )
390 : {
391 7934580 : y[i] = max( 0.0f, x[i] - a * m );
392 7934580 : a += x[i + flen];
393 : }
394 111301055 : for ( ; i < L_frame - flen; ++i )
395 : {
396 111084120 : y[i] = max( 0.0f, x[i] - a * m );
397 111084120 : a -= x[i - flen];
398 111084120 : a += x[i + flen];
399 : }
400 :
401 8151515 : for ( ; i < L_frame; ++i )
402 : {
403 7934580 : y[i] = max( 0.0f, x[i] - a * m );
404 7934580 : a -= x[i - flen];
405 : }
406 :
407 216935 : return;
408 : }
409 :
410 :
411 : /*-------------------------------------------------------------------*
412 : * tcx_hm_get_re()
413 : *
414 : *
415 : *-------------------------------------------------------------------*/
416 :
417 : /*! r: RE error */
418 614270 : static float tcx_hm_get_re(
419 : const float x[], /* i : absolute spectrum */
420 : const Word16 gain, /* i : HM gain (Q11) */
421 : const int32_t lag,
422 : const int16_t fract_res,
423 : const Word16 p[], /* i : harmonic model (Q13) */
424 : const Word32 env[], /* i : envelope (Q16) */
425 : const int16_t L_frame /* i : number of spectral lines */
426 : )
427 : {
428 : Word32 ne[N_MAX_ARI];
429 : float G, e;
430 : int16_t i;
431 :
432 : /* Calculate new envelope with "gain" harmonic gain */
433 356596190 : for ( i = 0; i < L_frame; ++i )
434 : {
435 355981920 : ne[i] = env[i];
436 : }
437 :
438 614270 : tcx_hm_modify_envelope( gain, lag, fract_res, p, ne, L_frame );
439 :
440 : /* Normalize */
441 614270 : G = 0;
442 :
443 356596190 : for ( i = 0; i < L_frame; ++i )
444 : {
445 355981920 : G += x[i] * ne[i];
446 : }
447 614270 : G = 1.0f / G;
448 :
449 : /* Calculate error */
450 614270 : e = 0;
451 :
452 356596190 : for ( i = 0; i < L_frame; ++i )
453 : {
454 355981920 : e += (float) pow( x[i] * ( ne[i] * G ), 4 );
455 : }
456 :
457 614270 : return e;
458 : }
459 :
460 :
461 : /*-------------------------------------------------------------------*
462 : * tcx_hm_quantize_gain()
463 : *
464 : *
465 : *-------------------------------------------------------------------*/
466 :
467 216935 : static void tcx_hm_quantize_gain(
468 : const float x[], /* i : absolute spectrum */
469 : const Word32 env[], /* i : envelope (Q16) */
470 : const int32_t lag,
471 : const int16_t fract_res,
472 : Word16 p[], /* i : harmonic model (Q13) */
473 : const int16_t L_frame, /* i : number of spectral lines */
474 : const int16_t coder_type, /* i : GC/VC coder type */
475 : float relative_score, /* i : periodicity score */
476 : int16_t *gain_idx, /* o : quantization index */
477 : Word16 *gain /* o : quantized harmonic model gain (Q11) */
478 : )
479 : {
480 : int16_t g, s;
481 : float be, e, pe;
482 216935 : const float kLowPeriodicityThr[2] = { 0.5f, 0.2f };
483 :
484 216935 : assert( coder_type == VOICED || coder_type == GENERIC );
485 :
486 216935 : s = 0;
487 216935 : if ( coder_type == VOICED )
488 : {
489 77256 : s = 1;
490 : }
491 :
492 216935 : *gain = 0;
493 :
494 : /* Disable the harmonic model if periodicity is very low */
495 216935 : if ( relative_score < kLowPeriodicityThr[s] )
496 : {
497 25414 : return;
498 : }
499 :
500 191521 : be = tcx_hm_get_re( x, *gain, lag, fract_res, p, env, L_frame );
501 :
502 191521 : if ( coder_type == GENERIC )
503 : {
504 114445 : e = tcx_hm_get_re( x, qGains[s][0], lag, fract_res, p, env, L_frame );
505 114445 : pe = 1.05f;
506 :
507 114445 : if ( e * pe < be )
508 : {
509 64969 : *gain_idx = 0;
510 64969 : *gain = qGains[s][0];
511 : }
512 : }
513 : else
514 : {
515 : /* Iterate over all possible gain values */
516 385380 : for ( g = 0; g < ( 1 << kTcxHmNumGainBits ); ++g )
517 : {
518 :
519 308304 : e = tcx_hm_get_re( x, qGains[s][g], lag, fract_res, p, env, L_frame );
520 :
521 : /* Add bit penalty */
522 308304 : pe = 1.0f;
523 308304 : if ( *gain == 0.0f )
524 : {
525 105933 : pe = 1.05f;
526 : }
527 :
528 : /* Minimum selection */
529 308304 : if ( e * pe < be )
530 : {
531 176407 : be = e;
532 176407 : *gain_idx = g;
533 176407 : *gain = qGains[s][g];
534 : }
535 : }
536 : }
537 :
538 191521 : return;
539 : }
540 :
541 :
542 : /*-------------------------------------------------------------------*
543 : * tcx_hm_analyse()
544 : *
545 : *
546 : *-------------------------------------------------------------------*/
547 :
548 281298 : void tcx_hm_analyse(
549 : const float abs_spectrum[], /* i : absolute spectrum */
550 : const int16_t L_frame, /* i : number of spectral lines */
551 : Word32 env[], /* i/o: envelope shape (Q16) */
552 : const int16_t targetBits, /* i : target bit budget */
553 : const int16_t coder_type, /* i : GC/VC coder type */
554 : int16_t prm_hm[], /* o : HM parameters */
555 : int16_t LtpPitchLag, /* i : LTP pitch lag or -1 if none */
556 : const float LtpGain, /* i : LTP gain */
557 : int16_t *hm_bits /* o : bit consumption */
558 : )
559 : {
560 : int32_t lag;
561 : int32_t tmpL;
562 : int16_t fract_res;
563 : float fspec[N_MAX_ARI], RelativeScore;
564 : Word16 p[2 * kTcxHmParabolaHalfWidth + 1], gain;
565 :
566 : /* Disable HM for non-GC,VC coder types */
567 281298 : if ( ( coder_type != VOICED ) && ( coder_type != GENERIC ) )
568 : {
569 64363 : *hm_bits = 0;
570 64363 : prm_hm[0] = 0;
571 :
572 64363 : return;
573 : }
574 :
575 : /* Bit consumption for the HM off case: 1 bit flag */
576 216935 : *hm_bits = 1;
577 :
578 : /* Filter out noise and keep the peaks */
579 216935 : PeakFilter( abs_spectrum, fspec, L_frame );
580 :
581 : /* Get the best lag index */
582 216935 : prm_hm[1] = SearchPeriodicityIndex( fspec, abs_spectrum, L_frame, targetBits - *hm_bits, LtpPitchLag, LtpGain, &RelativeScore );
583 :
584 : /* Convert the index to lag */
585 216935 : UnmapIndex( prm_hm[1], L_frame >= 256, LtpPitchLag, ( targetBits - *hm_bits <= kSmallerLagsTargetBitsThreshold ) || ( L_frame < 256 ), &fract_res, &tmpL );
586 216935 : lag = tmpL;
587 :
588 : /* Render harmonic model */
589 216935 : tcx_hm_render( lag, fract_res, p );
590 :
591 : /* Calculate and quantize gain */
592 216935 : gain = 0;
593 :
594 216935 : tcx_hm_quantize_gain( abs_spectrum, env, lag, fract_res, p, L_frame, coder_type, RelativeScore, &prm_hm[2], &gain );
595 :
596 : /* Decision */
597 216935 : if ( gain > 0 )
598 : {
599 132865 : prm_hm[0] = 1; /* flag: on */
600 :
601 132865 : *hm_bits += CountIndexBits( L_frame >= 256, prm_hm[1] );
602 :
603 132865 : if ( coder_type == VOICED )
604 : {
605 67896 : *hm_bits += kTcxHmNumGainBits;
606 : }
607 :
608 132865 : tcx_hm_modify_envelope( gain, lag, fract_res, p, env, L_frame );
609 : }
610 : else
611 : {
612 84070 : prm_hm[0] = 0; /* flag: off */
613 84070 : prm_hm[1] = -1; /* pitch index */
614 84070 : prm_hm[2] = 0; /* gain index */
615 : }
616 :
617 216935 : return;
618 : }
|