From 0488a2b6c86541f8864caa0a60f0a8abb54ecfaa Mon Sep 17 00:00:00 2001 From: "Malenovsky, Vladimir" Date: Wed, 7 Jan 2026 13:21:54 +0100 Subject: [PATCH 1/3] - add warning message when renderer frame size is modififed in ISAR - simplify logic around ivas_limiter_dec() --- apps/decoder.c | 8 ++++++++ lib_com/options.h | 1 + lib_dec/lib_dec.c | 10 ++++++++++ 3 files changed, 19 insertions(+) diff --git a/apps/decoder.c b/apps/decoder.c index f6b55ba00f..59bc2bd9d1 100644 --- a/apps/decoder.c +++ b/apps/decoder.c @@ -487,6 +487,14 @@ int main( fprintf( stderr, "\nConfigure failed: %s\n\n", IVAS_DEC_GetErrorMessage( error ) ); goto cleanup; } + +#ifdef FIX_1449_RENDERER_FRAME_SIZE_UNCLEAR_IN_ISAR + if ( !arg.renderConfigEnabled && ( arg.renderFramesize != asked_frame_size ) ) + { + fprintf( stderr, "\nChanged render framesize, only 20ms are allowed for non-0dof split rendering!\n" ); + } +#endif + } /*------------------------------------------------------------------------------------------* diff --git a/lib_com/options.h b/lib_com/options.h index de58cbabd7..fdc8f3ad6a 100644 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -173,6 +173,7 @@ #define FIX_2287_MCT_MDCT_STEREO_DATA_MALLOC_SIZE /* FhG: correct allocation size for STEREO_MDCT_DEC_DATA struct */ #define FIX_2271_OOB_INDEXING_IN_PIT_OL2 /* VA: Fix for issue 2271, to silence clang18 */ #define FIX_2273_OOB_INDEXING_IN_PIT_FR4 /* VA: Fix to silence clang on ptr init */ +#define FIX_1449_RENDERER_FRAME_SIZE_UNCLEAR_IN_ISAR /* Dolby: Fix for issue 1449: renderer frame size unclear in ISAR */ /* #################### End BE switches ################################## */ diff --git a/lib_dec/lib_dec.c b/lib_dec/lib_dec.c index 17342a454a..99e672f6e6 100644 --- a/lib_dec/lib_dec.c +++ b/lib_dec/lib_dec.c @@ -2183,6 +2183,11 @@ ivas_error IVAS_DEC_GetSplitBinauralBitstream( /* convert to int16 with limiting for BINAURAL_SPLIT_PCM */ if ( pcm_out_flag ) { +#ifdef FIX_1449_RENDERER_FRAME_SIZE_UNCLEAR_IN_ISAR +#ifndef DISABLE_LIMITER + ivas_limiter_dec( st_ivas->hLimiter, p_head_pose_buf, st_ivas->hDecoderConfig->nchan_out, numSamplesPerChannelToOutput, st_ivas->BER_detect ); +#endif +#else if ( st_ivas->hDecoderConfig->render_framesize == IVAS_RENDER_FRAMESIZE_5MS ) { #ifndef DISABLE_LIMITER @@ -2193,6 +2198,7 @@ ivas_error IVAS_DEC_GetSplitBinauralBitstream( { ivas_limiter_dec( st_ivas->hLimiter, p_head_pose_buf, st_ivas->hDecoderConfig->nchan_out, numSamplesPerChannelToOutput, st_ivas->BER_detect ); } +#endif #ifdef DEBUGGING st_ivas->noClipping += @@ -4118,6 +4124,9 @@ static ivas_error ivas_dec_voip_get_samples_common( /* Synthesise PCM output if split PCM */ if ( st_ivas->hDecoderConfig->output_config == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) { +#ifdef FIX_1449_RENDERER_FRAME_SIZE_UNCLEAR_IN_ISAR + ivas_limiter_dec( st_ivas->hLimiter, p_head_pose_buf, st_ivas->hDecoderConfig->nchan_out, *nSamplesRendered, st_ivas->BER_detect ); +#else if ( st_ivas->hDecoderConfig->render_framesize == IVAS_RENDER_FRAMESIZE_5MS ) { #ifndef DISABLE_LIMITER @@ -4128,6 +4137,7 @@ static ivas_error ivas_dec_voip_get_samples_common( { ivas_limiter_dec( st_ivas->hLimiter, p_head_pose_buf, st_ivas->hDecoderConfig->nchan_out, *nSamplesRendered, st_ivas->BER_detect ); } +#endif #ifdef DEBUGGING st_ivas->noClipping += -- GitLab From f69e581acdbca98ded500f0fe5061af47d2f39e3 Mon Sep 17 00:00:00 2001 From: "Malenovsky, Vladimir" Date: Wed, 7 Jan 2026 13:28:34 +0100 Subject: [PATCH 2/3] add #ifdef DISABLE_LIMITER --- lib_dec/lib_dec.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib_dec/lib_dec.c b/lib_dec/lib_dec.c index 99e672f6e6..64e025d47f 100644 --- a/lib_dec/lib_dec.c +++ b/lib_dec/lib_dec.c @@ -4125,7 +4125,9 @@ static ivas_error ivas_dec_voip_get_samples_common( if ( st_ivas->hDecoderConfig->output_config == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) { #ifdef FIX_1449_RENDERER_FRAME_SIZE_UNCLEAR_IN_ISAR +#ifndef DISABLE_LIMITER ivas_limiter_dec( st_ivas->hLimiter, p_head_pose_buf, st_ivas->hDecoderConfig->nchan_out, *nSamplesRendered, st_ivas->BER_detect ); +#endif #else if ( st_ivas->hDecoderConfig->render_framesize == IVAS_RENDER_FRAMESIZE_5MS ) { -- GitLab From 47eab9034fafe2266fdd996e4bc3e66ab013525e Mon Sep 17 00:00:00 2001 From: Vladimir Malenovsky Date: Wed, 7 Jan 2026 13:31:35 +0100 Subject: [PATCH 3/3] clang format --- apps/decoder.c | 1 - 1 file changed, 1 deletion(-) diff --git a/apps/decoder.c b/apps/decoder.c index 59bc2bd9d1..36c454de43 100644 --- a/apps/decoder.c +++ b/apps/decoder.c @@ -494,7 +494,6 @@ int main( fprintf( stderr, "\nChanged render framesize, only 20ms are allowed for non-0dof split rendering!\n" ); } #endif - } /*------------------------------------------------------------------------------------------* -- GitLab