LCOV - code coverage report
Current view: top level - lib_com - syn_12k8_fx.c (source / functions) Hit Total Coverage
Test: Coverage on main enc/dec/rend @ 3b2f07138c61dcf997bbf4165d0882f794b2995f Lines: 9 9 100.0 %
Date: 2025-05-03 01:55:50 Functions: 1 1 100.0 %

          Line data    Source code
       1             : /*====================================================================================
       2             :     EVS Codec 3GPP TS26.452 Aug 12, 2021. Version 16.3.0
       3             :   ====================================================================================*/
       4             : #include <stdint.h>
       5             : #include "options.h" /* Compilation switches                   */
       6             : #include "cnst.h"    /* Common constants                       */
       7             : #include "prot_fx.h" /* Function prototypes                    */
       8             : 
       9             : 
      10             : /*===========================================================================*/
      11             : /* FUNCTION : syn_12k8_fx()                                                                                                      */
      12             : /*---------------------------------------------------------------------------*/
      13             : /* PURPOSE : perform the synthesis filtering 1/A(z).                                             */
      14             : /*---------------------------------------------------------------------------*/
      15             : /* INPUT ARGUMENTS :                                                                                                             */
      16             : /* _ (Word16) st_fx->L_frame :length of the frame                                     */
      17             : /* _ (Word16[]) Aq              : LP filter coefficients                       Q12   */
      18             : /* _ (Word16) exc               : input signal                                                         Q_exc */
      19             : /* _ (Word16) update_m          : update memory flag: 0-->no memory update       */
      20             : /*                                                                                                1 --> update of memory     */
      21             : /* _ (Word16) Q_exc             : Excitation scaling                                     */
      22             : /* _ (Word16) Q_syn             : Synthesis scaling                                      */
      23             : /*---------------------------------------------------------------------------*/
      24             : /* INPUT OUTPUT ARGUMENTS :                                                                                                      */
      25             : /*---------------------------------------------------------------------------*/
      26             : /* OUTPUT ARGUMENTS :                                                                                                        */
      27             : /* _ (Word16[]) synth           : initial filter states                    Q_syn */
      28             : /*---------------------------------------------------------------------------*/
      29             : 
      30             : /* _ (Word16[]) st_fx->mem_syn2_fx: initial filter states              Q_syn */
      31             : /*---------------------------------------------------------------------------*/
      32             : /* RETURN ARGUMENTS :                                                                                                            */
      33             : /* _ None                                                                                                                                        */
      34             : /*===========================================================================*/
      35      344566 : void syn_12k8_fx(
      36             :     Word16 L_frame,
      37             :     const Word16 *Aq,      /* i  : LP filter coefficients                       Q12   */
      38             :     const Word16 *exc,     /* i  : input signal                                 Q_exc */
      39             :     Word16 *synth,         /* o  : output signal                                Q_syn */
      40             :     Word16 *mem,           /* i/o: initial filter states                        Q_syn */
      41             :     const Word16 update_m, /* i  : update memory flag: 0 --> no memory update   Q0    */
      42             :     /*                          1 --> update of memory         */
      43             :     const Word16 Q_exc, /* i  : Excitation scaling                           Q0    */
      44             :     const Word16 Q_syn  /* i  : Synthesis scaling                            Q0    */
      45             : )
      46             : {
      47             :     const Word16 *p_Aq;
      48             :     Word16 i_subfr;
      49             :     Word16 shift;
      50             : 
      51      344566 :     shift = sub( Q_exc, Q_syn );
      52      344566 :     p_Aq = Aq;
      53      344566 :     move16();
      54     1896164 :     FOR( i_subfr = 0; i_subfr < L_frame; i_subfr += L_SUBFR )
      55             :     {
      56     1551598 :         Syn_filt_s( shift, p_Aq, M, &exc[i_subfr], &synth[i_subfr], L_SUBFR, mem, update_m );
      57     1551598 :         p_Aq += ( M + 1 );
      58     1551598 :         move16(); /* interpolated LPC parameters for next subframe */
      59             :     }
      60      344566 :     return;
      61             : }

Generated by: LCOV version 1.14