Commit d9a06fca authored by multrus's avatar multrus
Browse files

[cleanup] accept NONBE_FIX_1052_SBA_EXT_FIX

parent 44f25b9d
Loading
Loading
Loading
Loading
+0 −4
Original line number Diff line number Diff line
@@ -84,13 +84,9 @@ void ivas_write_format(
void ivas_write_format_sid(
    const IVAS_FORMAT ivas_format,                              /* i  : IVAS format                             */
    const int16_t element_mode,                                 /* i  : element bitrate                         */
#ifdef NONBE_FIX_1052_SBA_EXT_FIX
    BSTR_ENC_HANDLE hBstr,                                      /* i/o: encoder bitstream handle                */
    const int16_t sba_order,                                    /* i  : Ambisonic (SBA) order                   */
    const int16_t sba_planar                                    /* i  : SBA planar flag                         */
#else
    BSTR_ENC_HANDLE hBstr                                       /* i/o: encoder bitstream handle                */
#endif
);

ivas_error create_sce_enc(
+0 −1
Original line number Diff line number Diff line
@@ -158,7 +158,6 @@

#define FIX_1129_EXT_REND_OUTPUT_HIGH                   /* Philips: issue 1129: External renderer BINAURAL_ROOM_REVERB format output level too high compared to internal rendering output */
#define NONBE_1244_FIX_SWB_BWE_MEMORY                   /* VA: issue 1244: fix to SWB BWE memory in case of switching from FB coding - pending a review by Huawei */
#define NONBE_FIX_1052_SBA_EXT_FIX                      /* VA: SBA external output support fix - do not overwrite "output_config" parameter */
#define NONBE_1289_STEREO_SW_TO_MONO                    /* VA: issue 1289: Fix glitch when stereo signal is decoded to mono n TD->DFT switching */
#define NONBE_FIX_1196_TD_HEADTRACKING_INTERPOLATION    /* Ericsson: Issue 1196, Always apply filter interpolation for each subframe */
#define FIX_1113_CLDFB_REND_IN_ISAR                     /* issue 1113: fix the use of CLDFB renderer in split-rendering at the external renderer */
+0 −28
Original line number Diff line number Diff line
@@ -544,13 +544,6 @@ ivas_error ivas_dec_setup(
            st_ivas->sba_order = st_ivas->bit_stream[num_bits_read + 1];
            st_ivas->sba_order += 2 * st_ivas->bit_stream[num_bits_read];

#ifndef NONBE_FIX_1052_SBA_EXT_FIX
            if ( st_ivas->hDecoderConfig->output_config == IVAS_AUDIO_CONFIG_EXTERNAL )
            {
                st_ivas->hDecoderConfig->output_config = ivas_set_audio_config_from_sba_order( st_ivas->sba_order );
                st_ivas->hDecoderConfig->nchan_out = audioCfg2channels( st_ivas->hDecoderConfig->output_config );
            }
#endif
            num_bits_read += SBA_ORDER_BITS;
            if ( st_ivas->ini_frame > 0 && ivas_total_brate != st_ivas->last_active_ivas_total_brate && ivas_total_brate > IVAS_SID_5k2 )
            {
@@ -788,13 +781,6 @@ ivas_error ivas_dec_setup(
                break;
        }

#ifndef NONBE_FIX_1052_SBA_EXT_FIX
        if ( st_ivas->ivas_format == SBA_FORMAT && st_ivas->hDecoderConfig->output_config == IVAS_AUDIO_CONFIG_EXTERNAL )
        {
            st_ivas->hDecoderConfig->output_config = ivas_set_audio_config_from_sba_order( st_ivas->sba_order );
            st_ivas->hDecoderConfig->nchan_out = audioCfg2channels( st_ivas->hDecoderConfig->output_config );
        }
#endif
        if ( st_ivas->ini_frame > 0 && st_ivas->ivas_format == SBA_FORMAT )
        {
            int16_t nchan_transport_old, nchan_transport;
@@ -1167,9 +1153,7 @@ ivas_error ivas_init_decoder_front(

    st_ivas->nSCE = 0;
    st_ivas->nCPE = 0;
#ifdef NONBE_FIX_1052_SBA_EXT_FIX
    st_ivas->nchan_ism = 0;
#endif
    st_ivas->nchan_transport = -1;

    st_ivas->ism_mode = ISM_MODE_NONE;
@@ -1335,11 +1319,7 @@ ivas_error ivas_init_decoder(
        {
            hDecoderConfig->nchan_out = audioCfg2channels( st_ivas->transport_config );
        }
#ifdef NONBE_FIX_1052_SBA_EXT_FIX
        else if ( st_ivas->ivas_format == SBA_ISM_FORMAT || st_ivas->ivas_format == SBA_FORMAT )
#else
        else if ( st_ivas->ivas_format == SBA_ISM_FORMAT )
#endif
        {
            hDecoderConfig->nchan_out = audioCfg2channels( ivas_set_audio_config_from_sba_order( st_ivas->sba_order ) );
            hDecoderConfig->nchan_out += st_ivas->nchan_ism;
@@ -1367,11 +1347,7 @@ ivas_error ivas_init_decoder(
        ivas_output_init( &( st_ivas->hOutSetup ), st_ivas->transport_config );
        st_ivas->intern_config = st_ivas->transport_config;
    }
#ifdef NONBE_FIX_1052_SBA_EXT_FIX
    else if ( output_config == IVAS_AUDIO_CONFIG_EXTERNAL && ( st_ivas->ivas_format == SBA_ISM_FORMAT || st_ivas->ivas_format == SBA_FORMAT ) )
#else
    else if ( output_config == IVAS_AUDIO_CONFIG_EXTERNAL && st_ivas->ivas_format == SBA_ISM_FORMAT )
#endif
    {
        st_ivas->intern_config = ivas_set_audio_config_from_sba_order( st_ivas->sba_order );
        ivas_output_init( &( st_ivas->hOutSetup ), st_ivas->intern_config );
@@ -1575,11 +1551,7 @@ ivas_error ivas_init_decoder(
            return error;
        }

#ifdef NONBE_FIX_1052_SBA_EXT_FIX
        if ( hDecoderConfig->output_config != IVAS_AUDIO_CONFIG_FOA && st_ivas->hDecoderConfig->output_config != IVAS_AUDIO_CONFIG_STEREO && st_ivas->hDecoderConfig->output_config != IVAS_AUDIO_CONFIG_MONO && !( hDecoderConfig->output_config == IVAS_AUDIO_CONFIG_EXTERNAL && st_ivas->intern_config == IVAS_AUDIO_CONFIG_FOA ) )
#else
        if ( hDecoderConfig->output_config != IVAS_AUDIO_CONFIG_FOA && st_ivas->hDecoderConfig->output_config != IVAS_AUDIO_CONFIG_STEREO && st_ivas->hDecoderConfig->output_config != IVAS_AUDIO_CONFIG_MONO )
#endif
        {
            if ( ( error = ivas_dirac_dec_config( st_ivas, DIRAC_OPEN ) ) != IVAS_ERR_OK )
            {
+0 −4
Original line number Diff line number Diff line
@@ -322,15 +322,11 @@ void ivas_renderer_select(

        if ( ivas_format == SBA_FORMAT && ( output_config != IVAS_AUDIO_CONFIG_5_1 && output_config != IVAS_AUDIO_CONFIG_5_1_2 && output_config != IVAS_AUDIO_CONFIG_5_1_4 && output_config != IVAS_AUDIO_CONFIG_7_1 && output_config != IVAS_AUDIO_CONFIG_7_1_4 && output_config != IVAS_AUDIO_CONFIG_LS_CUSTOM && output_config != IVAS_AUDIO_CONFIG_MONO && output_config != IVAS_AUDIO_CONFIG_STEREO ) )
        {
#ifdef NONBE_FIX_1052_SBA_EXT_FIX
            if ( output_config == IVAS_AUDIO_CONFIG_EXTERNAL )
            {
                /* 'internal_config' was already set in ivas_set_audio_config_from_sba_order() */
            }
            else if ( output_config == IVAS_AUDIO_CONFIG_HOA2 || output_config == IVAS_AUDIO_CONFIG_FOA )
#else
            if ( output_config == IVAS_AUDIO_CONFIG_HOA2 || output_config == IVAS_AUDIO_CONFIG_FOA )
#endif
            {
                *internal_config = output_config;
            }
+0 −12
Original line number Diff line number Diff line
@@ -1557,11 +1557,7 @@ void ivas_spar_dec_upmixer_sf(
        }
    }

#ifdef NONBE_FIX_1052_SBA_EXT_FIX
    if ( hDecoderConfig->ivas_total_brate < IVAS_24k4 && ( st_ivas->intern_config == IVAS_AUDIO_CONFIG_HOA2 || st_ivas->intern_config == IVAS_AUDIO_CONFIG_HOA3 ) )
#else
    if ( ( hDecoderConfig->ivas_total_brate < IVAS_24k4 ) && ( ( hDecoderConfig->output_config == IVAS_AUDIO_CONFIG_HOA2 ) || ( hDecoderConfig->output_config == IVAS_AUDIO_CONFIG_HOA3 ) ) )
#endif
    {
        ivas_spar_calc_smooth_facs( cldfb_in_ts_re[0], cldfb_in_ts_im[0], num_spar_bands, hSpar->subframe_nbslots[hSpar->subframes_rendered], hSpar->subframes_rendered == 0, &hSpar->hFbMixer->pFb->fb_bin_to_band, hSpar->hMdDec->smooth_fac, hSpar->hMdDec->smooth_buf );
    }
@@ -1571,11 +1567,7 @@ void ivas_spar_dec_upmixer_sf(
        md_idx = hSpar->render_to_md_map[ts + slot_idx_start];
        ivas_spar_get_parameters( hSpar, hDecoderConfig, md_idx, numch_out, numch_in, num_spar_bands, mixer_mat );

#ifdef NONBE_FIX_1052_SBA_EXT_FIX
        if ( hDecoderConfig->ivas_total_brate < IVAS_24k4 && ( st_ivas->intern_config == IVAS_AUDIO_CONFIG_HOA2 || st_ivas->intern_config == IVAS_AUDIO_CONFIG_HOA3 ) )
#else
        if ( ( hDecoderConfig->ivas_total_brate < IVAS_24k4 ) && ( ( hDecoderConfig->output_config == IVAS_AUDIO_CONFIG_HOA2 ) || ( hDecoderConfig->output_config == IVAS_AUDIO_CONFIG_HOA3 ) ) )
#endif
        {
            for ( spar_band = 0; spar_band < num_spar_bands; spar_band++ )
            {
@@ -1664,11 +1656,7 @@ void ivas_spar_dec_upmixer_sf(
        }
    }

#ifdef NONBE_FIX_1052_SBA_EXT_FIX
    if ( hDecoderConfig->output_config != IVAS_AUDIO_CONFIG_FOA && hDecoderConfig->output_config != IVAS_AUDIO_CONFIG_STEREO && hDecoderConfig->output_config != IVAS_AUDIO_CONFIG_MONO && !( hDecoderConfig->output_config == IVAS_AUDIO_CONFIG_EXTERNAL && st_ivas->intern_config == IVAS_AUDIO_CONFIG_FOA ) )
#else
    if ( hDecoderConfig->output_config != IVAS_AUDIO_CONFIG_FOA && hDecoderConfig->output_config != IVAS_AUDIO_CONFIG_STEREO && hDecoderConfig->output_config != IVAS_AUDIO_CONFIG_MONO )
#endif
    {
        ivas_dirac_dec_render_sf( st_ivas, output, nchan_internal, cldfb_in_ts_re, cldfb_in_ts_im );
    }
Loading