From 5cf172555e4ba67065aa1a4c0afdb6f00c634edb Mon Sep 17 00:00:00 2001 From: vaclav Date: Mon, 17 Mar 2025 15:09:52 +0100 Subject: [PATCH 1/2] issue 1293: add support of external HRTFs in split rendering; unde NONBE_1293_SR_HRTF --- apps/decoder.c | 4 ++++ lib_com/options.h | 2 ++ 2 files changed, 6 insertions(+) diff --git a/apps/decoder.c b/apps/decoder.c index c6a8616449..fcf9b4f7f9 100644 --- a/apps/decoder.c +++ b/apps/decoder.c @@ -310,7 +310,11 @@ int main( if ( arg.hrtfReaderEnabled ) { /* sanity check */ +#ifdef NONBE_1293_SR_HRTF + if ( arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_ROOM_IR && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_ROOM_REVERB && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) +#else if ( arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_ROOM_IR && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_ROOM_REVERB ) +#endif { arg.hrtfReaderEnabled = false; fprintf( stderr, "\nError: HRTF binary file cannot be used in this output configuration.\n\n" ); diff --git a/lib_com/options.h b/lib_com/options.h index 6dea2ea9d7..de3e8adf36 100644 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -177,6 +177,8 @@ #define NONBE_FIX_1277_EVS_DTX_HIGH_RATE_THRESHOLD /* VA/Eri: issue 1277: Fix Mismatch in DTX high-rate threshold between EVS float and BASOP */ #define NONBE_1231_BASOP_819_THRESHOLD_MASA2TOTAL /* Nokia: add fix for precision limitation in comparison with masa2total energy ratio threshold to be aligned with BASOP*/ +#define NONBE_1293_SR_HRTF /* VA: issue 1293: add support of external HRTFs in split rendering */ + /* ##################### End NON-BE switches ########################### */ /* ################## End DEVELOPMENT switches ######################### */ -- GitLab From 753820b079e5610ae9659a4502c5fa6277108732 Mon Sep 17 00:00:00 2001 From: Erik Norvell Date: Tue, 6 May 2025 15:09:17 +0200 Subject: [PATCH 2/2] Ensure int16 in wav-diff write-out --- scripts/pyaudio3dtools/audioarray.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/pyaudio3dtools/audioarray.py b/scripts/pyaudio3dtools/audioarray.py index f548622242..7ebc12e2b0 100644 --- a/scripts/pyaudio3dtools/audioarray.py +++ b/scripts/pyaudio3dtools/audioarray.py @@ -379,8 +379,8 @@ def compare( wavfile.write(str(tmpfile_test), 48000, test_tmp) del test_tmp else: - wavfile.write(str(tmpfile_ref), 48000, ref) - wavfile.write(str(tmpfile_test), 48000, test) + wavfile.write(str(tmpfile_ref), 48000, ref.astype(np.int16)) + wavfile.write(str(tmpfile_test), 48000, test.astype(np.int16)) cmd = [ str(wdiff), -- GitLab