Commit c64f3b64 authored by Sandesh Venkatesh's avatar Sandesh Venkatesh
Browse files

Fix for 3GPP issue 1794: High MLD for MC 5.1 Decoder at 192kbps JBM decoding...

Fix for 3GPP issue 1794: High MLD for MC 5.1 Decoder at 192kbps JBM decoding to BINAURAL_ROOM_REVERB

Link #1794
parent a31b7341
Loading
Loading
Loading
Loading
Loading
+13 −2
Original line number Diff line number Diff line
@@ -2264,10 +2264,10 @@ ivas_error ivas_jbm_dec_render_fx(

                FOR( i = 0; i < nchan_in; i++ )
                {
                    scale_sig32( p_output_fx[i], *nSamplesRendered, negate( sub( Q11, *st_ivas->hCrendWrapper->p_io_qfactor ) ) ); // Q11
                    scale_sig32( p_output_fx[i], *nSamplesRendered, negate( sub( Q11, *st_ivas->hCrendWrapper->p_io_qfactor ) ) ); // Q = *st_ivas->hCrendWrapper->p_io_qfactor
                    IF( st_ivas->hDecoderConfig->Opt_tsm )
                    {
                        scale_sig32( p_tc_fx[i], *nSamplesRendered, negate( sub( Q11, *st_ivas->hCrendWrapper->p_io_qfactor ) ) ); // Q11
                        scale_sig32( p_tc_fx[i], *nSamplesRendered, negate( sub( Q11, *st_ivas->hCrendWrapper->p_io_qfactor ) ) ); // Q = *st_ivas->hCrendWrapper->p_io_qfactor
                    }
                }
                IF( NE_32( ( error = ivas_rend_crendProcessSubframe( st_ivas->hCrendWrapper, st_ivas->intern_config, st_ivas->hOutSetup.output_config, st_ivas->hDecoderConfig, st_ivas->hCombinedOrientationData,
@@ -2277,6 +2277,17 @@ ivas_error ivas_jbm_dec_render_fx(
                    return error;
                }

                IF( st_ivas->hDecoderConfig->Opt_tsm )
                {
                    IF ( NE_16(exp , *st_ivas->hCrendWrapper->p_io_qfactor) )
                    {
                        FOR( i = 0; i < nchan_in; i++ )
                        {
                            scale_sig32( p_tc_fx[i], *nSamplesRendered, sub( *st_ivas->hCrendWrapper->p_io_qfactor, exp ) );
                        }
                    }
                }
               
                ivas_binaural_add_LFE_fx( st_ivas, *nSamplesRendered, p_tc_fx, p_output_fx );

                FOR( i = 0; i < nchan_in; i++ )