Commit 89dedadd authored by bayers's avatar bayers
Browse files

Merge branch...

Merge branch '416-ism-bitrate-switching-broken-missing-cldfbs-when-not-starting-with-a-paramism-bitrate' into 'main'

[Non-BE] Resolve "ISM Bitrate Switching broken (missing CLDFBs when not starting with a ParamISM bitrate)"

See merge request !587
parents a83d4c06 cd2912bd
Loading
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -56,7 +56,7 @@ static ivas_error ivas_ism_bitrate_switching(
    int32_t element_brate_tmp[MAX_NUM_OBJECTS];
    int16_t nSCE_old, nCPE_old;
#ifdef FIX_416_ISM_BR_SWITCHING
    int16_t numCldfbAnalyses_old, numCldfbSyntheses_old;
    int16_t numCldfbAnalyses_old, numCldfbSyntheses_old, ism_mode;
#endif

    error = IVAS_ERR_OK;
@@ -65,7 +65,11 @@ static ivas_error ivas_ism_bitrate_switching(
    nSCE_old = st_ivas->nSCE;

#ifdef FIX_416_ISM_BR_SWITCHING
    /* we have to temporarily set the ism mode back to the old one, otherwise this can give wrong results*/
    ism_mode = st_ivas->ism_mode;
    st_ivas->ism_mode = last_ism_mode;
    ivas_init_dec_get_num_cldfb_instances( st_ivas, &numCldfbAnalyses_old, &numCldfbSyntheses_old );
    st_ivas->ism_mode = ism_mode;
#endif

    if ( ( error = ivas_ism_config( st_ivas->hDecoderConfig->ivas_total_brate, st_ivas->nchan_transport, st_ivas->nchan_ism, NULL, NULL, NULL, element_brate_tmp, NULL, NULL ) ) != IVAS_ERR_OK )