Commit c0d646c2 authored by multrus's avatar multrus
Browse files

[cleanup] accept VLBR_20MS_MD

parent a459093b
Loading
Loading
Loading
Loading
+0 −8
Original line number Diff line number Diff line
@@ -4317,10 +4317,8 @@ void ivas_sba_mix_matrix_determiner(
    const int16_t bfi,                                          /* i  : BFI flag                                */
    const int16_t nchan_remapped,                               /* i  : num channels after remapping of TCs     */
    const int16_t output_frame                                  /* i  : output frame length                     */
#ifdef VLBR_20MS_MD
    ,
    const int16_t num_md_sub_frames                             /* i : number of subframes in mixing matrix  */
#endif
);

/* AGC */
@@ -4656,12 +4654,9 @@ void ivas_get_spar_md_from_dirac(
int16_t ivas_get_spar_dec_md_num_subframes(
    const int16_t sba_order,                                    /* i  : Ambisonic (SBA) order                   */
    const int32_t ivas_total_brate                              /* i  : IVAS total bitrate                      */
#ifdef VLBR_20MS_MD
    ,
    const int32_t ivas_last_active_brate /* i  : IVAS last active bitrate           */
#endif
);
#ifdef VLBR_20MS_MD

ivas_error ivas_spar_md_dec_matrix_open(
    ivas_spar_md_dec_state_t *hMdDec, /* i/o: SPAR MD decoder handle       */
@@ -4672,7 +4667,6 @@ void ivas_spar_md_dec_matrix_close(
    ivas_spar_md_dec_state_t *hMdDecoder, /* i/o: SPAR MD decoder handle      */
    const int16_t num_channels );            /* i  : number of internal channels */
    
#endif

ivas_error ivas_spar_md_dec_open(
    ivas_spar_md_dec_state_t **hMdDec_out,                      /* i/o: SPAR MD decoder handle                  */
@@ -4680,10 +4674,8 @@ ivas_error ivas_spar_md_dec_open(
    const int16_t num_channels,                                 /* i  : number of internal channels             */
	const int16_t sba_order,                                    /* i  : SBA order                               */
    const int16_t sid_format                                    /* i  : SID format                              */
#ifdef VLBR_20MS_MD
    ,
    const int32_t last_active_ivas_total_brate /* i  : IVAS last active bitrate           */
#endif
);

void ivas_spar_md_dec_close(
+0 −1
Original line number Diff line number Diff line
@@ -149,7 +149,6 @@
/* only BE switches wrt operation points tested in selection */

/*#define FIX_I4_OL_PITCH*/                             /* fix open-loop pitch used for EVS core switching */
#define VLBR_20MS_MD                                    /* Dlb: SBA VLBR 20ms Optimization*/
#define SBA_MODE_CLEANUP_2                              /* Dlb : changes part of fix issue #523 for unused signaling bit in SBA SID*/
#define FIX_137_SID_MD_BITS                             /* Dlb: Fix issue #137 , SID bitrate mismatch correction */
#define FIX_470_MASA_JBM_EXT                            /* Nokia: Issue 470, fix MASA EXT output with JBM */
+0 −14
Original line number Diff line number Diff line
@@ -93,9 +93,7 @@ ivas_error ivas_dec(
#else
    float *p_output[MAX_OUTPUT_CHANNELS];
#endif
#ifdef VLBR_20MS_MD
    int16_t num_md_sub_frames;
#endif
#ifdef MASA_AND_OBJECTS
    int32_t ism_total_brate;
#endif
@@ -472,10 +470,8 @@ ivas_error ivas_dec(

                ivas_spar_dec_gen_umx_mat( st_ivas->hSpar->hMdDec, st_ivas->nchan_transport, IVAS_MAX_NUM_BANDS, st_ivas->bfi,
                                           ivas_get_spar_dec_md_num_subframes( st_ivas->sba_order, st_ivas->hDecoderConfig->ivas_total_brate
#ifdef VLBR_20MS_MD
                                                                               ,
                                                                               st_ivas->last_active_ivas_total_brate
#endif
                                                                               ) );
            }

@@ -499,13 +495,9 @@ ivas_error ivas_dec(

            if ( st_ivas->renderer_type == RENDERER_BINAURAL_PARAMETRIC || st_ivas->renderer_type == RENDERER_BINAURAL_PARAMETRIC_ROOM )
            {
#ifdef VLBR_20MS_MD
                num_md_sub_frames = ivas_get_spar_dec_md_num_subframes( st_ivas->sba_analysis_order, st_ivas->hDecoderConfig->ivas_total_brate,
                                                                        st_ivas->last_active_ivas_total_brate );
                ivas_sba_mix_matrix_determiner( st_ivas->hSpar, output, st_ivas->bfi, nchan_remapped, output_frame, num_md_sub_frames );
#else
                ivas_sba_mix_matrix_determiner( st_ivas->hSpar, output, st_ivas->bfi, nchan_remapped, output_frame );
#endif
            }
            else if ( st_ivas->renderer_type != RENDERER_DISABLE )
            {
@@ -767,10 +759,8 @@ ivas_error ivas_dec(

            ivas_spar_dec_gen_umx_mat( st_ivas->hSpar->hMdDec, st_ivas->nchan_transport, IVAS_MAX_NUM_BANDS, st_ivas->bfi,
                                       ivas_get_spar_dec_md_num_subframes( st_ivas->sba_order, st_ivas->hDecoderConfig->ivas_total_brate
#ifdef VLBR_20MS_MD
                                                                           ,
                                                                           st_ivas->last_active_ivas_total_brate
#endif
                                                                           ) );

            ivas_sba_dirac_stereo_dec( st_ivas, &output[sba_ch_idx], output_frame, 0 );
@@ -800,13 +790,9 @@ ivas_error ivas_dec(
#endif
        if ( st_ivas->renderer_type == RENDERER_BINAURAL_PARAMETRIC || st_ivas->renderer_type == RENDERER_BINAURAL_PARAMETRIC_ROOM )
        {
#ifdef VLBR_20MS_MD
            num_md_sub_frames = ivas_get_spar_dec_md_num_subframes( st_ivas->sba_analysis_order, st_ivas->hDecoderConfig->ivas_total_brate,
                                                                    st_ivas->last_active_ivas_total_brate );
            ivas_sba_mix_matrix_determiner( st_ivas->hSpar, &output[sba_ch_idx], st_ivas->bfi, nchan_remapped, output_frame, num_md_sub_frames );
#else
            ivas_sba_mix_matrix_determiner( st_ivas->hSpar, output, st_ivas->bfi, nchan_remapped, output_frame );
#endif
        }
        else if ( st_ivas->renderer_type != RENDERER_DISABLE )
        {
+0 −10
Original line number Diff line number Diff line
@@ -93,9 +93,7 @@ ivas_error ivas_jbm_dec_tc(
    AUDIO_CONFIG output_config;
    ivas_error error;
    float *p_output[MAX_TRANSPORT_CHANNELS];
#ifdef VLBR_20MS_MD
    int16_t num_md_sub_frames;
#endif
#ifdef MASA_AND_OBJECTS
    int32_t ism_total_brate;
#endif
@@ -290,10 +288,8 @@ ivas_error ivas_jbm_dec_tc(

                ivas_spar_dec_gen_umx_mat( st_ivas->hSpar->hMdDec, st_ivas->nchan_transport, IVAS_MAX_NUM_BANDS, st_ivas->bfi,
                                           ivas_get_spar_dec_md_num_subframes( st_ivas->sba_order, st_ivas->hDecoderConfig->ivas_total_brate
#ifdef VLBR_20MS_MD
                                                                               ,
                                                                               st_ivas->last_active_ivas_total_brate
#endif
                                                                               ) );
            }

@@ -317,17 +313,11 @@ ivas_error ivas_jbm_dec_tc(

            if ( st_ivas->renderer_type == RENDERER_BINAURAL_PARAMETRIC || st_ivas->renderer_type == RENDERER_BINAURAL_PARAMETRIC_ROOM )
            {
#ifdef VLBR_20MS_MD
                num_md_sub_frames = ivas_get_spar_dec_md_num_subframes( st_ivas->sba_analysis_order, st_ivas->hDecoderConfig->ivas_total_brate
#ifdef VLBR_20MS_MD
                                                                        ,
                                                                        st_ivas->last_active_ivas_total_brate
#endif
                );
                ivas_sba_mix_matrix_determiner( st_ivas->hSpar, output, st_ivas->bfi, nchan_remapped, output_frame, num_md_sub_frames );
#else
                ivas_sba_mix_matrix_determiner( st_ivas->hSpar, output, st_ivas->bfi, nchan_remapped, output_frame );
#endif
            }
            else
            {
+0 −7
Original line number Diff line number Diff line
@@ -1734,19 +1734,12 @@ void ivas_spar_param_to_masa_param_mapping(
        else
        {

#ifdef VLBR_20MS_MD
            mixer_mat_index = ( ivas_get_spar_dec_md_num_subframes( st_ivas->sba_analysis_order, st_ivas->hDecoderConfig->ivas_total_brate
#ifdef VLBR_20MS_MD
                                                                    ,
                                                                    st_ivas->last_active_ivas_total_brate
#endif
                                                                    ) == 1 )
                                  ? 0
                                  : ( sf - SPAR_META_DELAY_SUBFRAMES );
#else

            mixer_mat_index = sf - SPAR_META_DELAY_SUBFRAMES;
#endif
            for ( band = 0; band < SPAR_DIRAC_SPLIT_START_BAND; band++ )
            {
                for ( i = 0; i < FOA_CHANNELS; i++ )
Loading