Commit 790cf019 authored by Archit Tamarapu's avatar Archit Tamarapu
Browse files
Merge branch 'main' of ssh://forge.3gpp.org:29419/ivas-codec-pc/ivas-codec into float-1466-mono-stereo-upmix-fixes-rend-dec-tests
parents b415d48c 867217ee
Loading
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -172,7 +172,7 @@
#define FIX_1435_MOVE_STEREO_PANNING                    /* VA: issue 1435: do the EVS stereo panning in the renderer */
#define FIX_1454_FIX_STEREO_TO_FOA_JBM                  /* VA: issue 1454: fix buggy stereo to FOA in JBM */
#define FIX_1461_CNG_BW_SWITCHING                       /* Eri: issue 1461: Stereo parameters are not updated when SID/NODATA forces BW to stay the same */

#define FIX_2252_LP_CNG_STARTS_SID                      /* VA: issues 2251 and 2252: fix LP CNG uninitialized value in bitstream that starts with an SID */

/* ##################### End NON-BE switches ########################### */

+18 −4
Original line number Diff line number Diff line
@@ -818,7 +818,6 @@ static void *mem_alloc_block( size_t size, const char *size_str );

void reset_mem( Counting_Size cnt_size )
{
    int16_t something;
    size_t tmp_size;

    /* initialize list of stack records */
@@ -838,7 +837,13 @@ void reset_mem( Counting_Size cnt_size )
    max_num_calls = MAX_NUM_RECORDS;

    /* initialize stack pointers */
#if defined( __GNUC__ ) || defined( __clang__ )
    /* GCC/Clang: use builtin (works for many targets) */
    ptr_base_stack = __builtin_frame_address( 0 );
#else
    int16_t something;
    ptr_base_stack = &something;
#endif	
    ptr_max_stack = ptr_base_stack;
    ptr_current_stack = ptr_base_stack;

@@ -943,10 +948,14 @@ void reset_mem( Counting_Size cnt_size )

void reset_stack( void )
{
    int16_t something;

    /* initialize/reset stack pointers */
#if defined( __GNUC__ ) || defined( __clang__ )
    /* GCC/Clang: use builtin (works for many targets) */
    ptr_base_stack = __builtin_frame_address( 0 );
#else
    int16_t something;
    ptr_base_stack = &something;
#endif	
    ptr_max_stack = ptr_base_stack;
    ptr_current_stack = ptr_base_stack;

@@ -961,10 +970,15 @@ void reset_stack( void )

int push_stack( const char *filename, const char *fctname )
{
    int16_t something;
    int32_t current_stack_size;

#if defined( __GNUC__ ) || defined( __clang__ )
    /* GCC/Clang: use builtin (works for many targets) */
    ptr_current_stack = __builtin_frame_address( 0 );
#else
    int16_t something;
    ptr_current_stack = &something;
#endif

    (void) *filename; /* to avoid compilation warning */

+4 −0
Original line number Diff line number Diff line
@@ -101,6 +101,10 @@ void decision_matrix_dec(
                    if ( get_next_indice( st, 1 ) == 1 )
                    {
                        st->L_frame = L_FRAME16k;
#ifdef FIX_2252_LP_CNG_STARTS_SID
                        st->nb_subfr = NB_SUBFR16k;
                        st->bwidth = max( st->bwidth, WB );
#endif
                    }
                }
                else
+18 −0
Original line number Diff line number Diff line
@@ -79,8 +79,26 @@ ivas_error init_decoder(
    st->last_total_brate_ber = -1;
    st->core_brate = ACELP_8k00;
    st->ini_frame = 0;
#ifdef FIX_2252_LP_CNG_STARTS_SID
    if ( st->element_mode == EVS_MONO )
    {
        st->bwidth = NB;
        st->last_bwidth = NB;
    }
    else
    {
#if 0 // keep deactivated for the moment to keep BE
        st->bwidth = WB;
        st->last_bwidth = WB;
#else
        st->bwidth = NB;
        st->last_bwidth = NB;
#endif
    }
#else
    st->bwidth = NB;
    st->last_bwidth = NB;
#endif
    st->extl_brate = 0;

    st->coder_type = GENERIC;
+4 −0
Original line number Diff line number Diff line
@@ -95,6 +95,10 @@ void ivas_decision_matrix_dec(
            if ( get_next_indice( st, 1 ) )
            {
                st->L_frame = L_FRAME16k;
#ifdef FIX_2252_LP_CNG_STARTS_SID
                st->nb_subfr = NB_SUBFR16k;
                st->bwidth = max( st->bwidth, WB );
#endif
            }
            else
            {