From ffc879f5d20694f7fe32739e22d6b0e9303fed67 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Wed, 19 Mar 2025 15:51:56 +0100 Subject: [PATCH 1/3] Accept FIX_920_IGF_INIT_ERROR --- lib_com/options.h | 1 - lib_com/prot_fx.h | 2 -- lib_enc/core_enc_init_fx.c | 6 ------ lib_enc/core_enc_switch_fx.c | 4 ---- lib_enc/init_enc_fx.c | 4 ---- 5 files changed, 17 deletions(-) diff --git a/lib_com/options.h b/lib_com/options.h index 54afc5968..1aeadd746 100755 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -150,7 +150,6 @@ #define FIX_881_HILBERT_FILTER /* VA: improve the precision of the Hilbert filter to remove 2kHz unwanted tone */ #define FIX_ISSUE_1245 /* Ittiam: Fix for issue 1245: Basop Encoder: Audible noise for silent Stereo input DTX on @24.4 kbps, @32 kbps*/ #define FIX_ISSUE_1291 /* Ittiam: Wrong use of imult1616() in ACELP rescaling */ -#define FIX_920_IGF_INIT_ERROR /* FhG: issue 920: fix bitrate mismatch in initial IGF config to avoid error message in same cases */ #define FIX_MINOR_SVD_WMOPS_MR1010X /* FhG: Minor WMOPS tuning, bit-exact to previous version, saves about 8.2 WMOPS for MR1010 */ #define FIX_USAN_ISSUES /* Ittiam: Fix issues reported by USAN */ #define SVD_WMOPS_OPT /* Ittiam : SVD related optimizations */ diff --git a/lib_com/prot_fx.h b/lib_com/prot_fx.h index bb0ac1c90..b9a17f40b 100644 --- a/lib_com/prot_fx.h +++ b/lib_com/prot_fx.h @@ -11084,9 +11084,7 @@ void calculate_hangover_attenuation_gain_ivas_fx( void init_coder_ace_plus_ivas_fx( Encoder_State *st, /* i : Encoder state */ const Word32 last_total_brate, /* i : last total bitrate */ -#ifdef FIX_920_IGF_INIT_ERROR const Word32 igf_brate, /* i : IGF configuration bitrate */ -#endif const Word16 MCT_flag /* i : hMCT handle allocated (1) or not (0) */ ); diff --git a/lib_enc/core_enc_init_fx.c b/lib_enc/core_enc_init_fx.c index 1c60f2ecd..2048982a2 100644 --- a/lib_enc/core_enc_init_fx.c +++ b/lib_enc/core_enc_init_fx.c @@ -945,9 +945,7 @@ static void init_modes_fx( void init_coder_ace_plus_ivas_fx( Encoder_State *st, /* i : Encoder state */ const Word32 last_total_brate, /* i : last total bitrate */ -#ifdef FIX_920_IGF_INIT_ERROR const Word32 igf_brate, /* i : IGF configuration bitrate */ -#endif const Word16 MCT_flag /* i : hMCT handle allocated (1) or not (0) */ ) { @@ -1080,11 +1078,7 @@ void init_coder_ace_plus_ivas_fx( test(); IF( st->igf && st->hIGFEnc != NULL ) { -#ifdef FIX_920_IGF_INIT_ERROR IGFEncSetMode_ivas_fx( st->hIGFEnc, igf_brate, st->bwidth, st->element_mode, st->rf_mode ); -#else - IGFEncSetMode_ivas_fx( st->hIGFEnc, st->total_brate, st->bwidth, st->element_mode, st->rf_mode ); -#endif } ELSE IF( st->hIGFEnc != NULL ) { diff --git a/lib_enc/core_enc_switch_fx.c b/lib_enc/core_enc_switch_fx.c index f3b4aea6b..2f21f1015 100644 --- a/lib_enc/core_enc_switch_fx.c +++ b/lib_enc/core_enc_switch_fx.c @@ -408,11 +408,7 @@ void core_coder_mode_switch_ivas_fx( Scale_sig( st->old_inp_12k8_fx, L_INP_MEM, shift ); st->exp_old_inp_12k8 = sub( st->exp_old_inp_12k8, shift ); move16(); -#ifdef FIX_920_IGF_INIT_ERROR init_coder_ace_plus_ivas_fx( st, last_total_brate, st->total_brate, MCT_flag ); -#else - init_coder_ace_plus_ivas_fx( st, last_total_brate, MCT_flag ); -#endif if ( st->hLPDmem != NULL ) { st->hLPDmem->q_lpd_old_exc = st->prev_Q_new; diff --git a/lib_enc/init_enc_fx.c b/lib_enc/init_enc_fx.c index ebfd9c4a2..6744ca07a 100644 --- a/lib_enc/init_enc_fx.c +++ b/lib_enc/init_enc_fx.c @@ -2098,11 +2098,7 @@ ivas_error init_encoder_ivas_fx( move16(); /* Initialize ACELP */ #endif -#ifdef FIX_920_IGF_INIT_ERROR init_coder_ace_plus_ivas_fx( st, st->last_total_brate, igf_brate, 0 ); -#else - init_coder_ace_plus_ivas_fx( st, st->last_total_brate, 0 ); -#endif IF( st->hLPDmem != NULL ) { -- GitLab From 952104801b8f1c432f29dc275e70628f669d89a2 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Wed, 19 Mar 2025 15:52:08 +0100 Subject: [PATCH 2/3] Accept NONBE_FIX_855_JBM_FLUSH_OFFSET --- lib_com/options.h | 1 - lib_dec/ivas_jbm_dec_fx.c | 6 ------ 2 files changed, 7 deletions(-) diff --git a/lib_com/options.h b/lib_com/options.h index 1aeadd746..c74f0728a 100755 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -180,7 +180,6 @@ #define ISAR_BITSTREAM_UPDATE_LC3PLUS /* FhG: Multiple improvements to the ISAR bitstream when LC3plus is used. See MR 1456 for details. */ #define FIX_1372_ISAR_POST_REND #endif -#define NONBE_FIX_855_JBM_FLUSH_OFFSET /* FhG: issue #855: add missing switch here for the code in JBM flushing */ #define FIX_923_EXTERNAL_REND_COMMAND_LINE /* VA: issue 923: enable external renderer command-line options in UPPER case letters */ #define FIX_921_OMASA_DELAY_PRINTOUT /* VA: issue 921: correct OMASA decoder delay printout */ #define NONBE_FIX_926_OSBA_DECODER_CRASH_PLANAR_SBA /* FhG: issue 926: crash in OSBA decoding with planar FOA */ diff --git a/lib_dec/ivas_jbm_dec_fx.c b/lib_dec/ivas_jbm_dec_fx.c index 95d9fb03e..5b75f8e7e 100644 --- a/lib_dec/ivas_jbm_dec_fx.c +++ b/lib_dec/ivas_jbm_dec_fx.c @@ -2789,11 +2789,7 @@ ivas_error ivas_jbm_dec_flush_renderer_fx( hTcBuffer->n_samples_buffered = add( hTcBuffer->n_samples_granularity, n_samples_still_available ); hTcBuffer->n_samples_available = 0; hTcBuffer->n_samples_flushed = n_samples_to_render; -#ifdef NONBE_FIX_855_JBM_FLUSH_OFFSET hTcBuffer->n_samples_rendered = 0; -#else - hTcBuffer->n_samples_rendered = hTcBuffer->n_samples_granularity; -#endif move16(); move16(); move16(); @@ -2994,9 +2990,7 @@ ivas_error ivas_jbm_dec_flush_renderer_fx( { return IVAS_ERROR( IVAS_ERR_WRONG_MODE, "Wrong IVAS format in VoIP renderer flushing!" ); } -#ifdef NONBE_FIX_855_JBM_FLUSH_OFFSET hTcBuffer->n_samples_rendered = hTcBuffer->n_samples_granularity; -#endif } /* update global combined orientation start index */ -- GitLab From d633b4d4764dee041f84b50863af45d7bbce2c50 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Wed, 19 Mar 2025 16:02:40 +0100 Subject: [PATCH 3/3] run formatter --- lib_com/prot_fx.h | 4 ++-- lib_enc/core_enc_init_fx.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib_com/prot_fx.h b/lib_com/prot_fx.h index b9a17f40b..450de2dc9 100644 --- a/lib_com/prot_fx.h +++ b/lib_com/prot_fx.h @@ -11084,8 +11084,8 @@ void calculate_hangover_attenuation_gain_ivas_fx( void init_coder_ace_plus_ivas_fx( Encoder_State *st, /* i : Encoder state */ const Word32 last_total_brate, /* i : last total bitrate */ - const Word32 igf_brate, /* i : IGF configuration bitrate */ - const Word16 MCT_flag /* i : hMCT handle allocated (1) or not (0) */ + const Word32 igf_brate, /* i : IGF configuration bitrate */ + const Word16 MCT_flag /* i : hMCT handle allocated (1) or not (0) */ ); void core_coder_reconfig_ivas_fx( diff --git a/lib_enc/core_enc_init_fx.c b/lib_enc/core_enc_init_fx.c index 2048982a2..430ee0f26 100644 --- a/lib_enc/core_enc_init_fx.c +++ b/lib_enc/core_enc_init_fx.c @@ -945,8 +945,8 @@ static void init_modes_fx( void init_coder_ace_plus_ivas_fx( Encoder_State *st, /* i : Encoder state */ const Word32 last_total_brate, /* i : last total bitrate */ - const Word32 igf_brate, /* i : IGF configuration bitrate */ - const Word16 MCT_flag /* i : hMCT handle allocated (1) or not (0) */ + const Word32 igf_brate, /* i : IGF configuration bitrate */ + const Word16 MCT_flag /* i : hMCT handle allocated (1) or not (0) */ ) { TCX_ENC_HANDLE hTcxEnc = st->hTcxEnc; -- GitLab