LCOV - code coverage report
Current view: top level - lib_lc3plus - tns_decoder.c (source / functions) Hit Total Coverage
Test: Coverage on main -- short test vectors @ 6c9ddc4024a9c0e1ecb8f643f114a84a0e26ec6b Lines: 0 24 0.0 %
Date: 2025-05-23 08:37:30 Functions: 0 1 0.0 %

          Line data    Source code
       1             : /******************************************************************************
       2             : *                        ETSI TS 103 634 V1.5.1                               *
       3             : *              Low Complexity Communication Codec Plus (LC3plus)              *
       4             : *                                                                             *
       5             : * Copyright licence is solely granted through ETSI Intellectual Property      *
       6             : * Rights Policy, 3rd April 2019. No patent licence is granted by implication, *
       7             : * estoppel or otherwise.                                                      *
       8             : ******************************************************************************/
       9             : 
      10             : #include "options.h"
      11             : #include "wmc_auto.h"
      12             : #include "functions.h"
      13             : 
      14           0 : void processTnsDecoder_fl(LC3_FLOAT* x, LC3_INT* rc_idx, LC3_INT* order, LC3_INT numfilters, LC3_INT bw_fcbin, LC3_INT N, LC3_INT fs)
      15             : {
      16             :     LC3_INT   startfreq[2], stopfreq[2], f, i, j, m, l;
      17           0 :     LC3_FLOAT rc[9], s, st[9] = {0};
      18             :         LC3_INT order_tmp;
      19             : 
      20           0 :     if (numfilters == 2) {
      21           0 :         startfreq[0] = floor(600 * N * 2 / fs) + 1;
      22           0 :         stopfreq[0]  = bw_fcbin / 2;
      23           0 :         startfreq[1] = bw_fcbin / 2 + 1;
      24           0 :         stopfreq[1]  = bw_fcbin;
      25             :     } else {
      26           0 :         startfreq[0] = floor(600 * N * 2 / fs) + 1;
      27           0 :         stopfreq[0]  = bw_fcbin;
      28             :     }
      29             : 
      30           0 :     for (f = 0; f < numfilters; f++) {
      31           0 :         order_tmp = order[f];
      32             :         
      33           0 :         if (order_tmp > 0) {
      34           0 :             j = 0;
      35             : 
      36           0 :             for (i = f * 8; i < f * 8 + order_tmp; i++) {
      37           0 :                 rc[j] = quants_pts_tns[rc_idx[i]];
      38           0 :                 j++;
      39             :             }
      40             : 
      41           0 :             for (m = startfreq[f]; m <= stopfreq[f]; m++) {
      42           0 :                 s = x[m - 1] - rc[order_tmp - 1] * st[order_tmp - 1];
      43             : 
      44           0 :                 for (l = order_tmp - 2; l >= 0; l--) {
      45           0 :                     s         = s - rc[l] * st[l];
      46           0 :                     st[l + 1] = rc[l] * s + st[l];
      47             :                 }
      48             : 
      49           0 :                 st[0]    = s;
      50           0 :                 x[m - 1] = s;
      51             :             }
      52             :         }
      53             :     }
      54           0 : }

Generated by: LCOV version 1.14