Loading lib_com/ivas_cnst.h +3 −1 Original line number Diff line number Diff line Loading @@ -1223,7 +1223,9 @@ enum #define NO_BITS_MASA_ISM_NO_OBJ 2 #ifdef IVAS_FLOAT_FIXED #ifdef NON_BE_FIX_BASOP_819_THRESHOLD_MASA2TOTAL #define MASA2TOTAL_THR 0.9799999f #define MASA2TOTAL_PREC_THRESHOLD 1e-5f //3.051757812500e-05 #define MASA2TOTAL_PREC_INV_THRESHOLD 1e5f //32768.0f #define MASA2TOTAL_THR 0.979999f #else #define MASA2TOTAL_THR 0.98f #endif Loading lib_dec/ivas_qmetadata_dec.c +12 −0 Original line number Diff line number Diff line Loading @@ -8711,6 +8711,10 @@ void ivas_omasa_decode_masa_to_total_fx( move32(); masa_to_total_energy_ratio_fx[i][j] = L_min( ONE_IN_Q30, masa_to_total_energy_ratio_fx[i][j] ); move32(); #ifdef NON_BE_FIX_BASOP_819_THRESHOLD_MASA2TOTAL1 masa_to_total_energy_ratio_fx[i][j] = masa_to_total_energy_ratio_fx[i][j] >> 15; /* Q30 to reach the Q10 used before comparing with threshold*/ masa_to_total_energy_ratio_fx[i][j] = masa_to_total_energy_ratio_fx[i][j] << 15; #endif k = add( k, 1 ); } } Loading @@ -8722,6 +8726,10 @@ void ivas_omasa_decode_masa_to_total_fx( FOR( j = 0; j < nbands; j++ ) { masa_to_total_energy_ratio_fx[i][j] = masa_to_total_energy_ratio_fx[0][j]; #ifdef NON_BE_FIX_BASOP_819_THRESHOLD_MASA2TOTAL1 masa_to_total_energy_ratio_fx[i][j] = masa_to_total_energy_ratio_fx[i][j] >> 15; /* Q30 to reach the Q10 used before comparing with threshold*/ masa_to_total_energy_ratio_fx[i][j] = masa_to_total_energy_ratio_fx[i][j] << 15; #endif move32(); } } Loading @@ -8734,6 +8742,10 @@ void ivas_omasa_decode_masa_to_total_fx( FOR( i = 0; i < nblocks; i++ ) { masa_to_total_energy_ratio_fx[i][j] = masa_to_total_energy_ratio_fx[i][0]; #ifdef NON_BE_FIX_BASOP_819_THRESHOLD_MASA2TOTAL1 masa_to_total_energy_ratio_fx[i][j] = masa_to_total_energy_ratio_fx[i][j] >> 15; /* Q30 to reach the Q10 used before comparing with threshold*/ masa_to_total_energy_ratio_fx[i][j] = masa_to_total_energy_ratio_fx[i][j] << 15; #endif move32(); } } Loading lib_enc/ivas_qmetadata_enc.c +2 −2 Original line number Diff line number Diff line Loading @@ -7808,8 +7808,8 @@ void ivas_omasa_encode_masa_to_total( masa_to_total_energy_ratio[i][j] = max( 0.0f, q_dct_data[k] ); masa_to_total_energy_ratio[i][j] = min( 1.0f, masa_to_total_energy_ratio[i][j] ); #ifdef NON_BE_FIX_BASOP_819_THRESHOLD_MASA2TOTAL int_tmp = (int32_t) ( MASA_SUR_COH_PRECISION * masa_to_total_energy_ratio[i][j] ); masa_to_total_energy_ratio[i][j] = (float) ( int_tmp * MASA_SUR_COH_THRESHOLD ); int_tmp = (int32_t) (( MASA2TOTAL_PREC_INV_THRESHOLD * masa_to_total_energy_ratio[i][j] )); masa_to_total_energy_ratio[i][j] = (float) ( int_tmp * MASA2TOTAL_PREC_THRESHOLD ); #endif k++; } Loading Loading
lib_com/ivas_cnst.h +3 −1 Original line number Diff line number Diff line Loading @@ -1223,7 +1223,9 @@ enum #define NO_BITS_MASA_ISM_NO_OBJ 2 #ifdef IVAS_FLOAT_FIXED #ifdef NON_BE_FIX_BASOP_819_THRESHOLD_MASA2TOTAL #define MASA2TOTAL_THR 0.9799999f #define MASA2TOTAL_PREC_THRESHOLD 1e-5f //3.051757812500e-05 #define MASA2TOTAL_PREC_INV_THRESHOLD 1e5f //32768.0f #define MASA2TOTAL_THR 0.979999f #else #define MASA2TOTAL_THR 0.98f #endif Loading
lib_dec/ivas_qmetadata_dec.c +12 −0 Original line number Diff line number Diff line Loading @@ -8711,6 +8711,10 @@ void ivas_omasa_decode_masa_to_total_fx( move32(); masa_to_total_energy_ratio_fx[i][j] = L_min( ONE_IN_Q30, masa_to_total_energy_ratio_fx[i][j] ); move32(); #ifdef NON_BE_FIX_BASOP_819_THRESHOLD_MASA2TOTAL1 masa_to_total_energy_ratio_fx[i][j] = masa_to_total_energy_ratio_fx[i][j] >> 15; /* Q30 to reach the Q10 used before comparing with threshold*/ masa_to_total_energy_ratio_fx[i][j] = masa_to_total_energy_ratio_fx[i][j] << 15; #endif k = add( k, 1 ); } } Loading @@ -8722,6 +8726,10 @@ void ivas_omasa_decode_masa_to_total_fx( FOR( j = 0; j < nbands; j++ ) { masa_to_total_energy_ratio_fx[i][j] = masa_to_total_energy_ratio_fx[0][j]; #ifdef NON_BE_FIX_BASOP_819_THRESHOLD_MASA2TOTAL1 masa_to_total_energy_ratio_fx[i][j] = masa_to_total_energy_ratio_fx[i][j] >> 15; /* Q30 to reach the Q10 used before comparing with threshold*/ masa_to_total_energy_ratio_fx[i][j] = masa_to_total_energy_ratio_fx[i][j] << 15; #endif move32(); } } Loading @@ -8734,6 +8742,10 @@ void ivas_omasa_decode_masa_to_total_fx( FOR( i = 0; i < nblocks; i++ ) { masa_to_total_energy_ratio_fx[i][j] = masa_to_total_energy_ratio_fx[i][0]; #ifdef NON_BE_FIX_BASOP_819_THRESHOLD_MASA2TOTAL1 masa_to_total_energy_ratio_fx[i][j] = masa_to_total_energy_ratio_fx[i][j] >> 15; /* Q30 to reach the Q10 used before comparing with threshold*/ masa_to_total_energy_ratio_fx[i][j] = masa_to_total_energy_ratio_fx[i][j] << 15; #endif move32(); } } Loading
lib_enc/ivas_qmetadata_enc.c +2 −2 Original line number Diff line number Diff line Loading @@ -7808,8 +7808,8 @@ void ivas_omasa_encode_masa_to_total( masa_to_total_energy_ratio[i][j] = max( 0.0f, q_dct_data[k] ); masa_to_total_energy_ratio[i][j] = min( 1.0f, masa_to_total_energy_ratio[i][j] ); #ifdef NON_BE_FIX_BASOP_819_THRESHOLD_MASA2TOTAL int_tmp = (int32_t) ( MASA_SUR_COH_PRECISION * masa_to_total_energy_ratio[i][j] ); masa_to_total_energy_ratio[i][j] = (float) ( int_tmp * MASA_SUR_COH_THRESHOLD ); int_tmp = (int32_t) (( MASA2TOTAL_PREC_INV_THRESHOLD * masa_to_total_energy_ratio[i][j] )); masa_to_total_energy_ratio[i][j] = (float) ( int_tmp * MASA2TOTAL_PREC_THRESHOLD ); #endif k++; } Loading