Commit 688c8e1e authored by Rivukanta Bhattacharya's avatar Rivukanta Bhattacharya
Browse files

Review comment changes

parent ca335175
Loading
Loading
Loading
Loading
Loading
+3 −7
Original line number Diff line number Diff line
@@ -3715,10 +3715,6 @@ ivas_error ivas_td_decorr_reconfig_dec(
    const int32_t output_Fs,                                    /* i  : output sampling rate                    */
    ivas_td_decorr_state_t **hTdDecorr,                         /* i/o: TD decorrelator handle                  */
    uint16_t *useTdDecorr                                       /* i/o: TD decorrelator flag                    */
#ifdef TD_DECORR_DIS
    , 
    int16_t td_decorr_flag                                        /* i  : Disable malloc for td_decorr structure flag */
#endif
);

/*! r: Configured reqularization factor value */
@@ -4317,7 +4313,7 @@ void ivas_spar_dec_close(
    SPAR_DEC_HANDLE *hSpar,                                     /* i/o: SPAR decoder handle                     */
    const int32_t output_Fs,                                    /* i  : output sampling rate                    */
    const int16_t spar_reconfig_flag                            /* i  : SPAR reconfiguration flag               */
#ifdef TD_DECORR_DIS
#ifdef FIX_163_SBA_TD_DECORR_OPT
    ,
    const int16_t td_decorr_flag                                  /* i  : Disable malloc for td_decorr structure flag */
#endif
@@ -5747,8 +5743,8 @@ int16_t ivas_get_num_bands_from_bw_idx(
    const int16_t bwidth                                        /* i  : audio bandwidth                             */
);

#ifdef TD_DECORR_DIS
void ivas_td_decorr_bitrate_check(
#ifdef FIX_163_SBA_TD_DECORR_OPT
void ivas_get_td_decorr_flag(
    const int32_t ivas_total_brate,                               /* i  : IVAS total bitrate                         */
    AUDIO_CONFIG output_config,                                   /* i  : output config.                             */
    Decoder_Struct *st_ivas                                       /* i/o  : IVAS decoder structure                  */
+8 −19
Original line number Diff line number Diff line
@@ -112,10 +112,6 @@ ivas_error ivas_td_decorr_reconfig_dec(
    const int32_t output_Fs,            /* i  : output sampling rate            */
    ivas_td_decorr_state_t **hTdDecorr, /* i/o: TD decorrelator handle          */
    uint16_t *useTdDecorr               /* i/o: TD decorrelator flag            */
#ifdef TD_DECORR_DIS
    ,
    int16_t td_decorr_flag /* i  : Disable malloc for td_decorr structure flag */
#endif
)
{
    uint16_t useTdDecorr_new;
@@ -152,10 +148,6 @@ ivas_error ivas_td_decorr_reconfig_dec(
        {
            if ( ivas_total_brate >= IVAS_13k2 && ivas_format == SBA_FORMAT )
            {
#ifdef TD_DECORR_DIS
                if ( !td_decorr_flag )
                {
#endif
                if ( *hTdDecorr == NULL )
                {
                    if ( ( error = ivas_td_decorr_dec_open( hTdDecorr, output_Fs, 3, 1 ) ) != IVAS_ERR_OK )
@@ -163,9 +155,6 @@ ivas_error ivas_td_decorr_reconfig_dec(
                        return error;
                    }
                }
#ifdef TD_DECORR_DIS
                }
#endif

                if ( ivas_total_brate < IVAS_24k4 )
                {
@@ -544,13 +533,13 @@ void ivas_td_decorr_process(
}

/*-----------------------------------------------------------------------------------------*
 * Function ivas_td_decorr_bitrate_check()
 * Function ivas_get_td_decorr_flag()
 *
 * TD decorr bitrate and outfit_config check call
 *-----------------------------------------------------------------------------------------*/

#ifdef TD_DECORR_DIS
void ivas_td_decorr_bitrate_check(
#ifdef FIX_163_SBA_TD_DECORR_OPT
void ivas_get_td_decorr_flag(
    const int32_t ivas_total_brate, /* i  : IVAS total bitrate                         */
    AUDIO_CONFIG output_config,     /* i  : output config.                             */
    Decoder_Struct *st_ivas         /* i/o  : IVAS decoder structure                  */
@@ -558,11 +547,11 @@ void ivas_td_decorr_bitrate_check(
{
    if ( ( st_ivas->ivas_format == SBA_FORMAT ) && ( ( output_config == AUDIO_CONFIG_MONO || output_config == AUDIO_CONFIG_STEREO ) || ( ivas_total_brate >= IVAS_256k && output_config == AUDIO_CONFIG_FOA ) ) )
    {
        st_ivas->td_decorr_flag = 1;
        st_ivas->hSpar->td_decorr_flag = 0;
    }
    else
    {
        st_ivas->td_decorr_flag = 0;
        st_ivas->hSpar->td_decorr_flag = 1;
    }
}
#endif
+1 −1
Original line number Diff line number Diff line
@@ -164,7 +164,7 @@
#define FIX_487_LOWRATE_SBA_TUNING_FIX                  /* Dlb: TUning fix for low bitrate cases to match theoretical longest SPAR MD bitstream */
#define FIX_490_MASA_2TC_LBR_DTX                        /* Nokia: Fixes issue 490 by correcting condition. */

#define TD_DECORR_DIS                                 /* Dlb : Issue 163 : Malloc of td_deccor structure at 512 kbps and output configuration FOA*/
#define FIX_163_SBA_TD_DECORR_OPT                       /* Dlb : Issue 163 : Malloc of td_deccor structure at 512 kbps and output configuration FOA*/

#define FIX_HBR_MASAMETA                                /* Nokia: Fixes to HBR MASA metadata at 384 and 512 kbps. Addresses issues 438 and 477 as well. */
#define FIX_482_DUMMYDEC_INIT                           /* Nokia: fix issue #428: missing inits for dummyDec in IVAS_rend */
+7 −7
Original line number Diff line number Diff line
@@ -691,8 +691,8 @@ ivas_error ivas_init_decoder(

    hDecoderConfig->last_ivas_total_brate = ivas_total_brate;
    st_ivas->last_active_ivas_total_brate = ivas_total_brate;
#ifdef TD_DECORR_DIS
    ivas_td_decorr_bitrate_check( ivas_total_brate, output_config, st_ivas );
#ifdef FIX_163_SBA_TD_DECORR_OPT
    ivas_get_td_decorr_flag( ivas_total_brate, output_config, st_ivas );
#endif

    if ( output_config == AUDIO_CONFIG_EXTERNAL )
@@ -1821,9 +1821,9 @@ void ivas_destroy_dec(

    /* SPAR handle */
    ivas_spar_dec_close( &( st_ivas->hSpar ), st_ivas->hDecoderConfig->output_Fs, 0
#ifdef TD_DECORR_DIS
#ifdef FIX_163_SBA_TD_DECORR_OPT
                         ,
                         st_ivas->td_decorr_flag
                         st_ivas->hSpar->td_decorr_flag
#endif
    );

@@ -1847,12 +1847,12 @@ void ivas_destroy_dec(
    ivas_lfe_dec_close( &( st_ivas->hLFE ) );

    /* Param-Upmix MC handle */
#ifdef TD_DECORR_DIS
    if ( !st_ivas->td_decorr_flag )
#ifdef FIX_163_SBA_TD_DECORR_OPT
    if ( st_ivas->hSpar->td_decorr_flag )
    {
#endif
        ivas_mc_paramupmix_dec_close( &( st_ivas->hMCParamUpmix ) );
#ifdef TD_DECORR_DIS
#ifdef FIX_163_SBA_TD_DECORR_OPT
    }
#endif

+2 −6
Original line number Diff line number Diff line
@@ -1266,14 +1266,10 @@ ivas_error ivas_masa_dec_reconfigure(
    /*-----------------------------------------------------------------*
     * TD Decorrelator
     *-----------------------------------------------------------------*/

    if ( st_ivas->hDiracDecBin != NULL )
    {
        if ( ( error = ivas_td_decorr_reconfig_dec( st_ivas->ivas_format, st_ivas->hDecoderConfig->ivas_total_brate, st_ivas->nchan_transport, st_ivas->hDecoderConfig->output_Fs, &( st_ivas->hDiracDecBin->hTdDecorr ), &( st_ivas->hDiracDecBin->useTdDecorr )
#ifdef TD_DECORR_DIS
                                                                                                                                                                                                                              ,
                                                    0
#endif
                                                    ) ) != IVAS_ERR_OK )
        if ( ( error = ivas_td_decorr_reconfig_dec( st_ivas->ivas_format, st_ivas->hDecoderConfig->ivas_total_brate, st_ivas->nchan_transport, st_ivas->hDecoderConfig->output_Fs, &( st_ivas->hDiracDecBin->hTdDecorr ), &( st_ivas->hDiracDecBin->useTdDecorr ) ) ) != IVAS_ERR_OK )
        {
            return error;
        }
Loading