Commit 2ae03116 authored by reutelhuber's avatar reutelhuber
Browse files

update to main

parents 4c8efefb 0af4db22
Loading
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -385,7 +385,11 @@ void ivas_get_dirac_sba_max_md_bits(
        *bits_frame_nominal = (int16_t) ( sba_total_brate / FRAMES_PER_SEC );
        *metadata_max_bits = MAX16B; /* no limit */
    }
#ifdef FIX_629_UBSAN_MD_MAX_BITS
    *metadata_max_bits = (int16_t) min( (float) MAX16B, ceilf( (float) *metadata_max_bits * nbands / 5 ) );
#else
    *metadata_max_bits = (int16_t) ceilf( (float) *metadata_max_bits * nbands / 5 );
#endif
    *qmetadata_max_bit_req = QMETADATA_MAXBIT_REQ_SBA >> 1;

    return;
+8 −12
Original line number Diff line number Diff line
@@ -159,10 +159,6 @@
#define FIX_571_REVERB_NOT_ACTIVATED_ISM                /* Philips: Issue 571: Reverb not activated for discrete and parametric ISM */
#define FIX_QMETA_SID_5k2                               /* Nokia: Issue 137: enable using full 5.2k bitrate in MASA SID */

#define FIX_578_PARAMMC_ILD_BS                          /* FhG: Issue 578: transmitt also center ILD in band 0 when LFE is active in 3TC ParamMC */
#define FIX_UNCLR_ISSUE                                 /* VoiceAge: issue 574: Fix UNCLR mis-classifications in noisy speech stereo */
#define FIX_TCX_LOWRATE_LIMITATION                      /* VA: issue 577: TCX bitrate limitation only when DEBUGGING is active */
#define FIX_575_LOW_OVERLAP_PLC_RECOVERY                /* FhG: Issue 575 fix for PLC and transistion to TCX5*/

#define FIX_488_SYNC_DELAY                             /* Eri: Issue 488: Waveform and MD desynchronized in external renderer */

@@ -170,14 +166,6 @@
#define FIX_550_FIRST_FRAME_ACCESS_ALT                  /* Eri: Issue 550: Should be merged with FIX_550_FIRST_FRAME_ACCESS above, or accepted at the same time */
#define FIX_569_TD_FILTER_LENGTH                        /* Eri: Issue 569: If an HRTF binary file exceeds the SFX_SPAT_BIN_MAX_FILTER_LENGTH the decoder crashes. This truncates the filter when generated from the model.  */

#define ISM_FB_16k4                                     /* VA: Issue: 579: change BW from SWB to FB in NxISM conditions to match the EVS codec */

#define FIX_580_PARAMMC_ENER_BURSTS                     /* FhG: issue 580: energy bursts due to ILD holding when energy relations change too much */

#define FIX_550_FIRST_FRAME_ACCESS                      /* Eri: Issue 550: TD Object renderer: first frame accesses wrong transport channel offsets */
#define FIX_550_FIRST_FRAME_ACCESS_ALT                  /* Eri: Issue 550: Should be merged with FIX_550_FIRST_FRAME_ACCESS above, or accepted at the same time */
#define FIX_569_TD_FILTER_LENGTH                        /* Eri: Issue 569: If an HRTF binary file exceeds the SFX_SPAT_BIN_MAX_FILTER_LENGTH the decoder crashes. This truncates the filter when generated from the model.  */

#define FIX_595_SHL_NOGLOB                              /* FhG: Issue 595: compilation with BASOP_NOGLOB disabled */
#define UPDATE_FASTCONV_SBA_FILTER                      /* Dlb: Issue 584: Update SBA CLDFB-Domain HRTFs */
#define FIX_570_SF_EXT_ORIENTATION
@@ -207,8 +195,16 @@
#define FIX_622_SILENCE_USAN_WARNING                    /* FhG: silenceusan warning in ifft code */

#define FIX_615_UBSAN_SPAR_TO_DIRAC                     /*Dlb : Fix for UBSAN issue 615*/

#define FIX_624_PLANAR_SBA_WB                           /*Dlb : Fix for unintialised value issue 624 */
#define FIX_629_UBSAN_MD_MAX_BITS                       /*Dlb : Fix for UBSAN issue 629 for MD MAX bits calculation*/

#define FIX_626_VARIABLE_TYPE_MDCT_CONC                 /* FhG: trivial fix to fix USAN error */

#define FIX_616_DIV_ZERO_MCT                            /*FhG : Fix UBSAN division by zero error of issue 616*/
#define FIX617_UBSAN_DIVBYZERO_STEREOCNG                /* Eri: Issue 617: Decoder UBSAN: division by zero in stereo cng when inut is 16kHz and output is 32kHz */
#define FIX_279_CODE_COVERAGE                           /* Dlb : issue 279 , clean up unused function */
#define FIX_549_PARAM_ISM_BIN_GAIN                      /* FhG: Issue 549 : fix too quiet binaural output in ParamISM */
#define FIX_625_IDX_OOB                                 /* FhG: Fix index out-of-bounds UBSAN error (issue 625) */

/* ################## End BE DEVELOPMENT switches ######################### */
+17 −0
Original line number Diff line number Diff line
@@ -737,9 +737,15 @@ static void shb_CNG_decod(
        ener = hTdCngDec->shb_cng_ener;
    }


    gain = (float) sqrt( pow( 10, 0.1f * ener ) * L_FRAME16k / ener_excSHB );

    st->hTdCngDec->shb_cng_gain = ener;
#ifdef FIX617_UBSAN_DIVBYZERO_STEREOCNG
#ifdef DEBUGGING
    /* note: state shb_cng_gain is actually an energy value in dB */
#endif
#endif

    for ( i = 0; i < L_FRAME16k; i++ )
    {
@@ -783,6 +789,15 @@ void td_cng_dec_init(
    mvr2r( st->lsp_old, st->lspCNG, M );
    hTdCngDec->last_allow_cn_step = 0;
    hTdCngDec->shb_cng_ener = -6.02f;
#ifdef FIX617_UBSAN_DIVBYZERO_STEREOCNG
    if ( st->element_mode != EVS_MONO )
    {
        set_f( hTdCngDec->shb_lpcCNG, 0.0f, LPC_SHB_ORDER + 1 );
        hTdCngDec->shb_lpcCNG[0] = 1.0f;
        hTdCngDec->shb_cng_gain = -82.0; /* a  dB value approximately corresponding to  shb  index 0(used as index -15)   */
    }
#endif

    hTdCngDec->wb_cng_ener = -6.02f;
    hTdCngDec->last_wb_cng_ener = -6.02f;
    hTdCngDec->last_shb_cng_ener = -6.02f;
@@ -825,8 +840,10 @@ void td_cng_dec_init(
    hTdCngDec->shb_dtx_count = 0;
    hTdCngDec->trans_cnt = 0;
    hTdCngDec->burst_cnt = 0;

    hTdCngDec->last_shb_ener = 0.001f;


    set_f( hTdCngDec->interpol_3_2_cng_dec, 0.0f, INTERP_3_2_MEM_LEN );

    return;
+5 −0
Original line number Diff line number Diff line
@@ -212,6 +212,11 @@ ivas_error ivas_dec(
        {
            if ( st_ivas->renderer_type == RENDERER_BINAURAL_PARAMETRIC || st_ivas->renderer_type == RENDERER_BINAURAL_PARAMETRIC_ROOM || st_ivas->renderer_type == RENDERER_STEREO_PARAMETRIC )
            {
#ifdef FIX_549_PARAM_ISM_BIN_GAIN
                /* loudness correction */
                ivas_dirac_dec_binaural_sba_gain( output, st_ivas->nchan_transport, output_frame );
#endif

                ivas_param_ism_params_to_masa_param_mapping( st_ivas );

                ivas_dirac_dec_binaural( st_ivas, st_ivas->hCombinedOrientationData, output, st_ivas->nchan_transport );
+1 −1
Original line number Diff line number Diff line
@@ -1455,7 +1455,7 @@ int16_t ivas_qmetadata_dec_sid_decode(
            }
        }
    }
    /* TODO: temporary hack to keep BE */

    if ( ivas_format != SBA_FORMAT )
    {
        metadata_sid_bits = ( IVAS_SID_5k2 - SID_2k40 ) / FRAMES_PER_SEC - SID_FORMAT_NBITS;
Loading