From 17525e530320582fb163eb1fdbe417698d82dfcf Mon Sep 17 00:00:00 2001 From: Markus Multrus Date: Sat, 4 Oct 2025 15:58:10 +0200 Subject: [PATCH] port remaining changes from float MR1655 --- lib_com/options.h | 1 + lib_rend/ivas_rotation_fx.c | 6 ++++++ lib_rend/lib_rend.h | 8 ++++++++ lib_rend/lib_rend_fx.c | 12 ++++++++++++ 4 files changed, 27 insertions(+) diff --git a/lib_com/options.h b/lib_com/options.h index 3271222de..e2cdcd2f8 100644 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -135,6 +135,7 @@ #define FIX_1999_TEMPORARY_DISABLE_DIST_ATT_CHECK /* Eri: Issue 1999: Range check on float values of distance attenuation, while the float values are not propagated to this function. The test is not correct, but configurable distance attenuation is not used in Characterization.*/ #define ADJUST_MCT_CHANNELS_MAX /* FhG: set correct max mct channels constant*/ #define FIX_1053_REVERB_RECONFIGURATION +#define FIX_1113_EXTREND_ISAR /* FhG: issue 1113: fix external renderer asserts for FOA/HOA2 and CLDFB config */ /* #################### End BASOP porting switches ############################ */ diff --git a/lib_rend/ivas_rotation_fx.c b/lib_rend/ivas_rotation_fx.c index d8e18f8a6..0524155c8 100644 --- a/lib_rend/ivas_rotation_fx.c +++ b/lib_rend/ivas_rotation_fx.c @@ -1022,7 +1022,13 @@ void rotateFrame_shd_cldfb( move16(); move16(); move16(); + +#ifdef FIX_1113_EXTREND_ISAR + assert( ( nInChannels == HOA3_CHANNELS || nInChannels == HOA2_CHANNELS || nInChannels == FOA_CHANNELS ) && + "Number of channels must correspond to an ambisonics order!" ); +#else assert( nInChannels == HEADROT_SHMAT_DIM && "Number of channels must be 16!" ); +#endif /* initialize rotation matrices with zeros */ FOR( i = 0; i < HEADROT_SHMAT_DIM; i++ ) diff --git a/lib_rend/lib_rend.h b/lib_rend/lib_rend.h index 7289ced5c..1f46ca932 100644 --- a/lib_rend/lib_rend.h +++ b/lib_rend/lib_rend.h @@ -255,12 +255,20 @@ ivas_error IVAS_REND_InitConfig( const IVAS_AUDIO_CONFIG outAudioConfig /* i : output audioConfig */ ); +#ifdef FIX_1113_EXTREND_ISAR +ivas_error IVAS_REND_GetRenderConfig( +#else Word16 IVAS_REND_GetRenderConfig( +#endif IVAS_REND_HANDLE hIvasRend, /* i/o: IVAS renderer handle */ const IVAS_RENDER_CONFIG_HANDLE hRCout /* o : Render configuration handle */ ); +#ifdef FIX_1113_EXTREND_ISAR +ivas_error IVAS_REND_FeedRenderConfig( +#else Word16 IVAS_REND_FeedRenderConfig( +#endif IVAS_REND_HANDLE hIvasRend, /* i/o: IVAS renderer handle */ const IVAS_RENDER_CONFIG_DATA renderConfig /* i : Render configuration struct */ ); diff --git a/lib_rend/lib_rend_fx.c b/lib_rend/lib_rend_fx.c index fc72052b7..dc53538bb 100644 --- a/lib_rend/lib_rend_fx.c +++ b/lib_rend/lib_rend_fx.c @@ -3107,7 +3107,11 @@ static ivas_error updateSbaPanGains( IF( EQ_32( hRendCfg->split_rend_config.rendererSelection, ISAR_SPLIT_REND_RENDERER_SELECTION_FASTCONV ) ) #endif { +#ifdef FIX_1113_EXTREND_ISAR + assert( *rendCtx.pOutSampleRate == 48000 && "split binaural fast conv mode is currently supported with 48k sampling rate only" ); +#else assert( inConfig == IVAS_AUDIO_CONFIG_HOA3 && ( *rendCtx.pOutSampleRate == 48000 ) && "split binaural fast conv mode is currently supported with HOA3 input and 48k sampling rate only" ); +#endif IF( ( error = ivas_rend_openCldfbRend( &inputSba->cldfbRendWrapper, inConfig, outConfig, &rendCtx.pSplitRendWrapper->multiBinPoseData, *rendCtx.pOutSampleRate ) ) != IVAS_ERR_OK ) { return error; @@ -4982,7 +4986,11 @@ ivas_error IVAS_REND_InitConfig( * *-------------------------------------------------------------------*/ +#ifdef FIX_1113_EXTREND_ISAR +ivas_error IVAS_REND_GetRenderConfig( +#else Word16 IVAS_REND_GetRenderConfig( +#endif IVAS_REND_HANDLE hIvasRend, /* i/o: IVAS renderer handle */ const IVAS_RENDER_CONFIG_HANDLE hRCout /* o : Render configuration handle */ ) @@ -5039,7 +5047,11 @@ Word16 IVAS_REND_GetRenderConfig( * *-------------------------------------------------------------------*/ +#ifdef FIX_1113_EXTREND_ISAR +ivas_error IVAS_REND_FeedRenderConfig( +#else Word16 IVAS_REND_FeedRenderConfig( +#endif IVAS_REND_HANDLE hIvasRend, /* i/o: IVAS renderer handle */ const IVAS_RENDER_CONFIG_DATA renderConfig /* i : Render configuration struct */ ) -- GitLab