Commit 073c7ddb authored by Dominik Weckbecker's avatar Dominik Weckbecker 💬
Browse files

wrap changes into ifdef more cleanly

parent c1998fc7
Loading
Loading
Loading
Loading
Loading
+24 −1
Original line number Diff line number Diff line
@@ -1358,7 +1358,6 @@ void ivas_spar_dec_upmixer(
                    {
#ifdef SPAR_TUNING
                        if ( b_skip_mat[out_ch][in_ch] == 0 )
#endif
                        {
                            if ( cldfb_band < CLDFB_PAR_WEIGHT_START_BAND ) /* tuning parameter, depends on how much SPAR Filters overlap for the CLDFB bands */
                            {
@@ -1379,6 +1378,30 @@ void ivas_spar_dec_upmixer(
                            out_im[out_ch] += cldfb_in_ts_im[in_ch][ts][cldfb_band] * cldfb_par;
                        }
                    }
#else

                       if ( b_skip_mat[out_ch][in_ch] )
                        {
                            continue;
                        }
                        else if ( cldfb_band < CLDFB_PAR_WEIGHT_START_BAND ) /* tuning parameter, depends on how much SPAR Filters overlap for the CLDFB bands */
                        {
                            spar_band = bin2band->p_cldfb_map_to_spar_band[cldfb_band];
                            cldfb_par = mixer_mat[out_ch][in_ch][spar_band];
                        }
                        else
                        {
                            cldfb_par = 0.0f;
                            for ( spar_band = bin2band->p_spar_start_bands[cldfb_band]; spar_band < num_spar_bands; spar_band++ )
                            {
                                /* accumulate contributions from all SPAR bands */
                                cldfb_par += mixer_mat[out_ch][in_ch][spar_band] * bin2band->pp_cldfb_weights_per_spar_band[cldfb_band][spar_band];
                            }
                        }

                        out_re[out_ch] += cldfb_in_ts_re[in_ch][ts][cldfb_band] * cldfb_par;
                        out_im[out_ch] += cldfb_in_ts_im[in_ch][ts][cldfb_band] * cldfb_par;
#endif
                }

                /*update CLDFB data with the parameter-modified data*/