Commit 46c0e60b authored by vaclav's avatar vaclav
Browse files

fix MSVC Warning C4244 'function': conversion from 'float' to 'const int32_t',...

fix MSVC Warning	C4244	'function': conversion from 'float' to 'const int32_t', possible loss of data	lib_dec	..\lib_dec\ivas_mct_dec.c	1033
parent 4554d745
Loading
Loading
Loading
Loading
+22 −0
Original line number Diff line number Diff line
@@ -1030,7 +1030,29 @@ static ivas_error ivas_mc_dec_reconfig(

    if ( st_ivas->mc_mode == MC_MODE_MCT && st_ivas->hLFE == NULL )
    {
#ifdef FIX_I59_LFE_TD_DELAY
        int32_t binauralization_delay_ns = st_ivas->binaural_latency_ns;

        if ( st_ivas->hBinRenderer != NULL )
        {
#ifdef FIX_I59_LFE_CLDFB
            if ( st_ivas->hBinRenderer->render_lfe )
            {
                /* Account for filterbank delay */
                binauralization_delay_ns += IVAS_FB_DEC_DELAY_NS;
            }
            else
            {
                binauralization_delay_ns = 0;
            }
#else
            binauralization_delay_ns = 0;
#endif
        }
        if ( ( error = ivas_create_lfe_dec( &st_ivas->hLFE, st_ivas->hDecoderConfig->output_Fs, binauralization_delay_ns ) ) != IVAS_ERR_OK )
#else
        if ( ( error = ivas_create_lfe_dec( &st_ivas->hLFE, st_ivas->hDecoderConfig->output_Fs, st_ivas->hHrtf != NULL ? st_ivas->hHrtf->latency_s : 0 ) ) != IVAS_ERR_OK )
#endif
        {
            return error;
        }