From 6e19a9644087b4755a93dcbca84b2ce77fad592a Mon Sep 17 00:00:00 2001 From: Sandesh Venkatesh Date: Sat, 10 Aug 2024 20:39:24 +0530 Subject: [PATCH] MLD improvements --- lib_dec/igf_dec_fx.c | 10 ++++++---- lib_rend/ivas_objectRenderer.c | 12 ++++++------ 2 files changed, 12 insertions(+), 10 deletions(-) diff --git a/lib_dec/igf_dec_fx.c b/lib_dec/igf_dec_fx.c index 09a885719..eca6ee3aa 100644 --- a/lib_dec/igf_dec_fx.c +++ b/lib_dec/igf_dec_fx.c @@ -2727,11 +2727,12 @@ static void IGF_appl_ivas( IGF_DEC_PRIVATE_DATA_HANDLE hPrivateData, /**< in } Word16 max_e; - max_e = MIN16B; + max_e = *spectrum_e; move16(); FOR( i = 0; i < hGrid->stopLine; i++ ) { - max_e = s_max( max_e, spec_e_arr[i] ); + if ( spectrum[i] != 0 ) + max_e = s_max( max_e, sub( spec_e_arr[i], norm_l( spectrum[i] ) ) ); } FOR( i = 0; i < hGrid->stopLine; i++ ) { @@ -2741,11 +2742,12 @@ static void IGF_appl_ivas( IGF_DEC_PRIVATE_DATA_HANDLE hPrivateData, /**< in *spectrum_e = max_e; move16(); - max_e = MIN16B; + max_e = *virtualSpec_e; move16(); FOR( i = hGrid->startLine - IGF_START_MN; i < hGrid->stopLine - IGF_START_MN; i++ ) { - max_e = s_max( max_e, vspec_e_arr[i] ); + if ( virtualSpec[i] ) + max_e = s_max( max_e, sub( vspec_e_arr[i], norm_l( virtualSpec[i] ) ) ); } FOR( i = hGrid->startLine - IGF_START_MN; i < hGrid->stopLine - IGF_START_MN; i++ ) { diff --git a/lib_rend/ivas_objectRenderer.c b/lib_rend/ivas_objectRenderer.c index 59db41f7d..fca18ac05 100644 --- a/lib_rend/ivas_objectRenderer.c +++ b/lib_rend/ivas_objectRenderer.c @@ -1003,12 +1003,12 @@ ivas_error TDREND_Update_object_positions_fx( angles_to_vec_fx( hIsmMetaData[nS]->radius_fx /*Q9*/, hIsmMetaData[nS]->azimuth_fx, hIsmMetaData[nS]->elevation_fx, Pos_fx ); angles_to_vec_fx( ONE_IN_Q14, hIsmMetaData[nS]->yaw_fx, hIsmMetaData[nS]->pitch_fx, Dir_fx ); - DirAtten_p->ConeInnerAngle_fx = DEG_360_IN_Q22; - move32(); - DirAtten_p->ConeOuterAngle_fx = DEG_360_IN_Q22; - move32(); - DirAtten_p->ConeOuterGain_fx = ONE_IN_Q30; - move32(); + // DirAtten_p->ConeInnerAngle_fx = DEG_360_IN_Q22; + // move32(); + // DirAtten_p->ConeOuterAngle_fx = DEG_360_IN_Q22; + // move32(); + // DirAtten_p->ConeOuterGain_fx = ONE_IN_Q30; + // move32(); IF( NE_32( ( error = TDREND_MIX_SRC_SetPos_fx( hBinRendererTd, nS, Pos_fx ) ), IVAS_ERR_OK ) ) { -- GitLab