Commit 0c2a4ffa authored by vaclav's avatar vaclav
Browse files

fix merge issue

parent d6c978f1
Loading
Loading
Loading
Loading
Loading
+25 −21
Original line number Diff line number Diff line
@@ -200,11 +200,7 @@ ivas_error ivas_omasa_dec_config(
    void *data                           /* o  : output synthesis signal     */
)
{
#ifdef NONBE_FIX_1065_ISM_MD_HANDLE
    int16_t k, sce_id, nSCE_old, nchan_hp20_old, numCldfbAnalyses_old, numCldfbSyntheses_old;
#else
    int16_t k, sce_id, nSCE_old, nchan_hp20_old, numCldfbAnalyses_old, numCldfbSyntheses_old, n_MD;
#endif
    int32_t ivas_total_brate, ism_total_brate, cpe_brate;
    ISM_MODE ism_mode_old;
    IVAS_FORMAT ivas_format_orig;
@@ -296,6 +292,11 @@ ivas_error ivas_omasa_dec_config(
    if ( ism_mode_old != st_ivas->ism_mode )
    {
        /* ISM MD reconfig. */
        n_MD = 0;
#ifdef NONBE_FIX_984_OMASA_EXT_OUTPUT
        if ( st_ivas->hDecoderConfig->output_config == IVAS_AUDIO_CONFIG_EXTERNAL )
        {
            /* the full number of hIsmMetaData are needed for EXT output */
#ifdef NONBE_FIX_1065_ISM_MD_HANDLE
            if ( st_ivas->hIsmMetaData[0] == NULL )
            {
@@ -312,11 +313,6 @@ ivas_error ivas_omasa_dec_config(
                }
            }
#else
        n_MD = 0;
#ifdef NONBE_FIX_984_OMASA_EXT_OUTPUT
        if ( st_ivas->hDecoderConfig->output_config == IVAS_AUDIO_CONFIG_EXTERNAL )
        {
            /* the full number of hIsmMetaData are needed for EXT output */
            n_MD = st_ivas->nchan_ism;
            ivas_ism_metadata_close( st_ivas->hIsmMetaData, 0 );
            if ( ( error = ivas_ism_metadata_dec_create( st_ivas, st_ivas->nchan_ism, NULL ) ) != IVAS_ERR_OK )
@@ -325,6 +321,7 @@ ivas_error ivas_omasa_dec_config(
            }

            ivas_ism_metadata_close( st_ivas->hIsmMetaData, n_MD );
#endif
        }
        else
        {
@@ -339,13 +336,21 @@ ivas_error ivas_omasa_dec_config(
                        return error;
                    }
                }
#ifdef NONBE_FIX_1065_ISM_MD_HANDLE
                else
                {
                    ivas_ism_reset_metadata_handle_dec( st_ivas->hIsmMetaData[0] );
                }
#endif
            }
            else if ( st_ivas->ism_mode == ISM_MASA_MODE_DISC )
            {
                n_MD = st_ivas->nchan_ism;

                ivas_ism_metadata_close( st_ivas->hIsmMetaData, 0 );
#ifndef NONBE_FIX_1065_ISM_MD_HANDLE

                ivas_ism_metadata_close( st_ivas->hIsmMetaData, 0 );
#endif
                if ( ( error = ivas_ism_metadata_dec_create( st_ivas, st_ivas->nchan_ism, NULL ) ) != IVAS_ERR_OK )
                {
                    return error;
@@ -380,7 +385,6 @@ ivas_error ivas_omasa_dec_config(
        }

        ivas_ism_metadata_close( st_ivas->hIsmMetaData, n_MD );
#endif
#endif

        st_ivas->hCPE[0]->element_brate = ivas_total_brate - ism_total_brate;