Commit e643e048 authored by multrus's avatar multrus
Browse files

[cleanup] accept FIX_BASOP_2541_OMASA_ENC_FIXES

parent 8dce4bc0
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -115,7 +115,6 @@
#define FIX_BASOP_2023_TDREND_DISTATT_PRECISION         /* Eri: Basop issue 2023: Distance attenuation scaling, adding clamping of distance att input and listener position */
#define FIX_BASOP_2023_TDREND_DISTATT_PRECISION_BUGFIX  /* Eri: Bug discovered in cleanup of basop issue 2023 */
#define FIX_1576_LCLD_CRASH_DIFFERENT_CODEC_ISAR_FRAME_SIZE  /* Dolby: float issue 1576: fix for crash in LCLD mode when codec frame size is less than isar frame size */
#define FIX_BASOP_2541_OMASA_ENC_FIXES                  /* Nokia: BASOP issue 2541: Fix function ivas_encode_masaism_metadata_fx */
#define FIX_BASOP_2545_FIX_LTV_REGRESSION_2529          /* Nokia: BASOP issue 2545: Fix LTV regression caused by issue 2529 fix */
#define FIX_1548_HARMONIZE_NON_DIEGETIC_PANNING_LAW     /* Orange: float issue 1548: Harmonize non diegetic panning law in ISM and renderers */
#define FIX_FLOAT_1573_POSITION_UPDATE                  /* Eri: Float issue 1573: For static orientation and listener movement, the PoseUpdated flag is cleared and prevents 5 ms update rate. */
+0 −14
Original line number Diff line number Diff line
@@ -4815,13 +4815,8 @@ static void ivas_encode_masaism_metadata_fx(
                eneBand32 = W_extract_h( W_shl( eneBand, shift ) );
                eneBand_exp = sub( 63, add( add( hMasa->data.q_energy, 1 ), shift ) );

#ifdef FIX_BASOP_2541_OMASA_ENC_FIXES
                energy_ism = L_tmp; // Copy existing value
                energy_ism_e = L_tmp_e;
#else
                energy_ism = 0;
                energy_ism_e = 0;
#endif
                move32();
                move16();
                FOR( obj = 0; obj < nchan_ism; obj++ )
@@ -4834,20 +4829,11 @@ static void ivas_encode_masaism_metadata_fx(

                FOR( band = 0; band < omasa_nbands; band++ )
                {
#ifndef FIX_BASOP_2541_OMASA_ENC_FIXES
                    energy_ism = BASOP_Util_Add_Mant32Exp( energy_ism, energy_ism_e, hOmasaEnergy->energy_ism_fx[sf][band], hOmasaEnergy->energy_ism_fx_e[sf][band], &energy_ism_e );
#endif
                    FOR( obj = 0; obj < nchan_ism; obj++ )
                    {
#ifdef FIX_BASOP_2541_OMASA_ENC_FIXES
                        L_tmp = Mpy_32_32( hOmasaEnergy->energy_ism_fx[sf][band], hOmasaEnergy->energy_ratio_ism_fx[sf][band][obj] ); // Q = (31 - hOmasaEnergy->energy_ism_fx_e[sf][band]) + Q30 - 31
                        L_tmp_e = add( 1, hOmasaEnergy->energy_ism_fx_e[sf][band] );
                        energy_ism_ind[obj] = BASOP_Util_Add_Mant32Exp( energy_ism_ind[obj], energy_ism_ind_e[obj], L_tmp, L_tmp_e, &energy_ism_ind_e[obj] );
#else

                        hOmasaData->masa_to_total_energy_ratio_fx[sf][0] = ONE_IN_Q30; // 1.0f in Q30
                        move32();
#endif
                    }
                }