Commit 25303da4 authored by TYAGIRIS's avatar TYAGIRIS
Browse files

24.4 to 256 kbps bitrate switching failure fix

parent db83650b
Loading
Loading
Loading
Loading
Loading
+7 −5
Original line number Diff line number Diff line
@@ -271,9 +271,9 @@ ivas_error ivas_dirac_dec_config(
    }

#ifdef HODIRAC
    if ( st_ivas->ivas_format == SBA_FORMAT && flag_config == DIRAC_RECONFIGURE && ( ( ivas_total_brate >= IVAS_256k && st_ivas->hDecoderConfig->last_ivas_total_brate < IVAS_256k ) || ( ivas_total_brate < IVAS_256k && st_ivas->hDecoderConfig->last_ivas_total_brate >= IVAS_256k ) ) )
    if ( st_ivas->ivas_format == SBA_FORMAT && flag_config == DIRAC_RECONFIGURE && ( ( ivas_total_brate > IVAS_256k && st_ivas->hDecoderConfig->last_ivas_total_brate <= IVAS_256k ) || ( ivas_total_brate <= IVAS_256k && st_ivas->hDecoderConfig->last_ivas_total_brate > IVAS_256k ) ) )
    {
        if ( st_ivas->hDecoderConfig->ivas_total_brate >= IVAS_256k && hDirAC->azimuth2 == NULL )
        if ( st_ivas->hDecoderConfig->ivas_total_brate > IVAS_256k && hDirAC->azimuth2 == NULL )
        {
            hDirAC->azimuth2 = (int16_t **) malloc( hDirAC->dirac_md_buffer_length * sizeof( int16_t * ) );
            hDirAC->elevation2 = (int16_t **) malloc( hDirAC->dirac_md_buffer_length * sizeof( int16_t * ) );
@@ -291,7 +291,7 @@ ivas_error ivas_dirac_dec_config(
                set_f( hDirAC->spreadCoherence2[i], 0.0f, hDirAC->num_freq_bands );
            }
        }
        else if ( st_ivas->hDecoderConfig->ivas_total_brate < IVAS_256k && hDirAC->azimuth2 != NULL )
        else if ( st_ivas->hDecoderConfig->ivas_total_brate <= IVAS_256k && hDirAC->azimuth2 != NULL )
        {
            for ( i = 0; i < hDirAC->dirac_md_buffer_length; i++ )
            {
@@ -317,6 +317,7 @@ ivas_error ivas_dirac_dec_config(
    /* band config needed only for SPAR with FOA output */
    if ( st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_FOA && st_ivas->sba_mode == SBA_MODE_SPAR
#ifdef HODIRAC
         /*DLB : why is this needed ?*/
         && ivas_total_brate < IVAS_256k
#endif
    )
@@ -1028,7 +1029,7 @@ ivas_error ivas_dirac_dec_config(

        if ( st_ivas->ivas_format == MASA_FORMAT
#ifdef HODIRAC
             || ( st_ivas->ivas_format == SBA_FORMAT && st_ivas->hDecoderConfig->ivas_total_brate >= IVAS_256k )
             || ( st_ivas->ivas_format == SBA_FORMAT && st_ivas->hDecoderConfig->ivas_total_brate > IVAS_256k )
#endif
        )
        {
@@ -2988,7 +2989,8 @@ void ivas_dirac_dec(
                                                              index_slot
#endif
#ifdef HODIRAC
                                                                  st_ivas->sba_analysis_order > 1 && st_ivas->hDecoderConfig->ivas_total_brate > IVAS_256k
                                                                          st_ivas->sba_analysis_order > 1 &&
                                                                  st_ivas->hDecoderConfig->ivas_total_brate > IVAS_256k
#endif
                );
            }
+1 −1
Original line number Diff line number Diff line
@@ -249,7 +249,7 @@ ivas_error ivas_sba_dec_reconfigure(

    if ( ( ( st_ivas->renderer_type != RENDERER_DISABLE ) && ( st_ivas->renderer_type != RENDERER_SBA_LINEAR_DEC ) ) || ( ( hDecoderConfig->output_config != AUDIO_CONFIG_FOA ) && ( st_ivas->hDecoderConfig->output_config != AUDIO_CONFIG_STEREO ) && ( st_ivas->hDecoderConfig->output_config != AUDIO_CONFIG_MONO ) )
#ifdef HODIRAC
         || ( last_ivas_total_brate >= IVAS_256k && ivas_total_brate < IVAS_256k ) || ( last_ivas_total_brate < IVAS_256k && ivas_total_brate >= IVAS_256k )
         || ( last_ivas_total_brate > IVAS_256k && ivas_total_brate <= IVAS_256k ) || ( last_ivas_total_brate <= IVAS_256k && ivas_total_brate > IVAS_256k )
#endif
    )
    {
+0 −1
Original line number Diff line number Diff line
@@ -128,7 +128,6 @@ ivas_error ivas_enc(

    n = getNumChanAnalysis( st_ivas );

    /*tyagiri: TODO: looks like HP20 is disabled for high bitrates in SBA. Also, getNumChanAnalysis() is returning (order+1)*(order+1) channels always. is this expected ?*/
#ifndef DEBUG_SPAR_BYPASS_EVS_CODEC
    /* bypass EVS coding in float precision, emulating EVS encoder/decoder delay */
    for ( i = 0; i < n; i++ )
+2 −2

File changed.

Contains only whitespace changes.