From ff938b8a0496fe6cf38d271c7c66fcb48e0fede0 Mon Sep 17 00:00:00 2001 From: "Azizi, Arash" Date: Thu, 30 Apr 2026 12:26:38 +0200 Subject: [PATCH 1/3] Issue 2568: creating switch --- lib_com/options.h | 1 + 1 file changed, 1 insertion(+) diff --git a/lib_com/options.h b/lib_com/options.h index 6579999f2..e919f5da7 100644 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -111,6 +111,7 @@ #define FIX_2095_REMOVE_UNUSED_ISAR_TABLES /* Dolby: remove unused ISAR */ #define FIX_BASOP_2560_STEREO_DFT_DEC_RESET /* FhG: BASOP issue 2560: align reset of hStereoDft->res_gains_ind_fx[][] between BASOP and float */ #define HARMONIZE_2539_cng_energy /* FhG: basop issue 2539: harmonize cng_energy with its ivas derivate */ +#define FIX_ISSUE_2568_ADAPR_GR_RPG1 /* FhG: basop issue 2568: Missing comparison macros in function adapt_GR_rpg1_ief_fx()*/ /* #################### End BE switches ################################## */ -- GitLab From 84faa8bd398f4e6ce6aeb800c856b80710147f00 Mon Sep 17 00:00:00 2001 From: "Azizi, Arash" Date: Thu, 30 Apr 2026 12:29:33 +0200 Subject: [PATCH 2/3] Issue 2568: fixing switch and fixing the issue --- lib_com/options.h | 2 +- lib_enc/ivas_stereo_adapt_GR_enc_fx.c | 12 ++++++++++-- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/lib_com/options.h b/lib_com/options.h index e919f5da7..d9b8af021 100644 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -111,7 +111,7 @@ #define FIX_2095_REMOVE_UNUSED_ISAR_TABLES /* Dolby: remove unused ISAR */ #define FIX_BASOP_2560_STEREO_DFT_DEC_RESET /* FhG: BASOP issue 2560: align reset of hStereoDft->res_gains_ind_fx[][] between BASOP and float */ #define HARMONIZE_2539_cng_energy /* FhG: basop issue 2539: harmonize cng_energy with its ivas derivate */ -#define FIX_ISSUE_2568_ADAPR_GR_RPG1 /* FhG: basop issue 2568: Missing comparison macros in function adapt_GR_rpg1_ief_fx()*/ +#define FIX_ISSUE_2568_ADAPT_GR_RPG1 /* FhG: basop issue 2568: Missing comparison macros in function adapt_GR_rpg1_ief_fx()*/ /* #################### End BE switches ################################## */ diff --git a/lib_enc/ivas_stereo_adapt_GR_enc_fx.c b/lib_enc/ivas_stereo_adapt_GR_enc_fx.c index bf54b6901..3257d8751 100644 --- a/lib_enc/ivas_stereo_adapt_GR_enc_fx.c +++ b/lib_enc/ivas_stereo_adapt_GR_enc_fx.c @@ -225,7 +225,11 @@ Word16 adapt_GR_rpg1_ief_fx( map0 = &maps[8 * NO_SYMB_GR_PRED_G]; - IF( in[0] == 0 ) +#ifndef FIX_ISSUE_2568_ADAPT_GR_RPG1 + IF(in[0] == 0) +#else + IF(EQ_16(in[0], 0)) +#endif // !FIX_ISSUE_2568_ADAPT_GR_RPG1 { s = 0; move16(); @@ -234,7 +238,11 @@ Word16 adapt_GR_rpg1_ief_fx( s = add( s, in[i] ); } - IF( s == 0 ) +#ifndef FIX_ISSUE_2568_ADAPT_GR_RPG1 + IF(s == 0) +#else + IF(EQ_16(s, 0)) +#endif // !FIX_ISSUE_2568_ADAPT_GR_RPG1 { /* encode only the first zero with GR1 */ *nbits = add( shr( map0[0], 1 ), 2 ); -- GitLab From 024e1b5cac387f60ed2e2cd7954c87cec4c8f3e5 Mon Sep 17 00:00:00 2001 From: "Azizi, Arash" Date: Thu, 30 Apr 2026 14:39:40 +0200 Subject: [PATCH 3/3] Issue 2568: Clang formatting patch --- lib_enc/ivas_stereo_adapt_GR_enc_fx.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib_enc/ivas_stereo_adapt_GR_enc_fx.c b/lib_enc/ivas_stereo_adapt_GR_enc_fx.c index 3257d8751..d1d69a019 100644 --- a/lib_enc/ivas_stereo_adapt_GR_enc_fx.c +++ b/lib_enc/ivas_stereo_adapt_GR_enc_fx.c @@ -226,9 +226,9 @@ Word16 adapt_GR_rpg1_ief_fx( map0 = &maps[8 * NO_SYMB_GR_PRED_G]; #ifndef FIX_ISSUE_2568_ADAPT_GR_RPG1 - IF(in[0] == 0) + IF( in[0] == 0 ) #else - IF(EQ_16(in[0], 0)) + IF( EQ_16( in[0], 0 ) ) #endif // !FIX_ISSUE_2568_ADAPT_GR_RPG1 { s = 0; @@ -239,9 +239,9 @@ Word16 adapt_GR_rpg1_ief_fx( } #ifndef FIX_ISSUE_2568_ADAPT_GR_RPG1 - IF(s == 0) + IF( s == 0 ) #else - IF(EQ_16(s, 0)) + IF( EQ_16( s, 0 ) ) #endif // !FIX_ISSUE_2568_ADAPT_GR_RPG1 { /* encode only the first zero with GR1 */ -- GitLab