Loading apps/decoder.c +113 −21 Original line number Diff line number Diff line Loading @@ -159,14 +159,13 @@ typedef struct static bool parseCmdlIVAS_dec( int16_t argc, char **argv, DecArguments *arg ); static void usage_dec( void ); #ifdef FIX_FLOAT_1539_G192_FORMAT_SWITCH static ivas_error decodeG192( DecArguments arg, BS_READER_HANDLE hBsReader, IVAS_DEC_HRTF_BINARY_WRAPPER *hHrtfBinary, RotFileReader *headRotReader, RotFileReader *externalOrientationFileReader, RotFileReader *refRotReader, Vector3PairFileReader *referenceVectorReader, ObjectEditFileReader *objectEditFileReader, ISAR_SPLIT_REND_BITS_DATA *splitRendBits, IVAS_DEC_HANDLE *phIvasDec, int16_t *pcmBuf ); #else static ivas_error decodeG192( DecArguments arg, BS_READER_HANDLE hBsReader, IVAS_DEC_HRTF_BINARY_WRAPPER *hHrtfBinary, RotFileReader *headRotReader, RotFileReader *externalOrientationFileReader, RotFileReader *refRotReader, Vector3PairFileReader *referenceVectorReader, ObjectEditFileReader *objectEditFileReader, ISAR_SPLIT_REND_BITS_DATA *splitRendBits, IVAS_DEC_HANDLE hIvasDec, int16_t *pcmBuf ); #endif static ivas_error decodeVoIP( DecArguments arg, BS_READER_HANDLE hBsReader, IVAS_DEC_HRTF_BINARY_WRAPPER *hHrtf, RotFileReader *headRotReader, RotFileReader *externalOrientationFileReader, RotFileReader *refRotReader, Vector3PairFileReader *referenceVectorReader, ObjectEditFileReader *objectEditFileReader, ISAR_SPLIT_REND_BITS_DATA *splitRendBits, IVAS_DEC_HANDLE *phIvasDec, int16_t *pcmBuf ); static ivas_error load_hrtf_from_file( IVAS_DEC_HRTF_BINARY_WRAPPER *hHrtfBinary, IVAS_DEC_HANDLE hIvasDec, const IVAS_AUDIO_CONFIG OutputConfig, const int32_t output_Fs ); static void do_object_editing_fx( IVAS_EDITABLE_PARAMETERS *editableParameters, ObjectEditFileReader *objectEditFileReader ); #ifdef FIX_FMSW_DEC_EXT static ivas_error updateOnFormatSwitching( IVAS_DEC_HANDLE hIvasDec, IVAS_DEC_BS_FORMAT *pBsFormat, const char *outputWavFilename, MasaFileWriter **ppMasaWriter, IsmFileWriter *ismWriters[IVAS_MAX_NUM_OBJECTS], int16_t *pNumOutChannels, uint16_t *pNumObj, const bool delayCompensationEnabled ); #endif /*------------------------------------------------------------------------------------------* Loading Loading @@ -207,7 +206,6 @@ int main( reset_mem( USE_BYTES ); #endif splitRendBits.bits_buf = splitRendBitsBuf; /*------------------------------------------------------------------------------------------* Loading Loading @@ -457,7 +455,6 @@ int main( } } /*-------------------------------------------------------------------* * Load renderer configuration from file *--------------------------------------------------------------------*/ Loading Loading @@ -542,6 +539,7 @@ int main( fprintf( stderr, "Failed to get directivity patterns for one or more of IDs: %d %d %d %d\n\n", arg.directivityPatternId[0], arg.directivityPatternId[1], arg.directivityPatternId[2], arg.directivityPatternId[3] ); goto cleanup; } if ( ( error = RenderConfigReader_getDistanceAttenuation( renderConfigReader, renderConfig.distAtt_fx ) ) != IVAS_ERR_OK ) { fprintf( stderr, "Failed to get Distance Attenuation \n\n" ); Loading Loading @@ -612,6 +610,7 @@ int main( hLsCustomData.azimuth_fx[i] = (Word32) ( hLsCustomData.azimuth[i] * ( 1u << 22 ) ); hLsCustomData.elevation_fx[i] = (Word32) ( hLsCustomData.elevation[i] * ( 1u << 22 ) ); } if ( ( error = IVAS_DEC_FeedCustomLsData( hIvasDec, hLsCustomData ) ) != IVAS_ERR_OK ) { fprintf( stderr, "\nIVAS_DEC_FeedCustomLsData failed: %s\n", IVAS_DEC_GetErrorMessage( error ) ); Loading Loading @@ -670,11 +669,7 @@ int main( } else { #ifdef FIX_FLOAT_1539_G192_FORMAT_SWITCH error = decodeG192( arg, hBsReader, &hHrtfBinary, headRotReader, externalOrientationFileReader, refRotReader, referenceVectorReader, objectEditFileReader, &splitRendBits, &hIvasDec, pcmBuf ); #else error = decodeG192( arg, hBsReader, &hHrtfBinary, headRotReader, externalOrientationFileReader, refRotReader, referenceVectorReader, objectEditFileReader, &splitRendBits, hIvasDec, pcmBuf ); #endif } if ( error == IVAS_ERR_OK || error == IVAS_ERR_END_OF_FILE ) Loading @@ -694,7 +689,6 @@ int main( goto cleanup; } /*------------------------------------------------------------------------------------------* * Close files and deallocate resources *------------------------------------------------------------------------------------------*/ Loading Loading @@ -742,7 +736,6 @@ cleanup: print_wmops(); print_mem( NULL ); #endif if ( !arg.quietModeEnabled ) { printf( "\n" ); Loading Loading @@ -2002,11 +1995,7 @@ static ivas_error decodeG192( Vector3PairFileReader *referenceVectorReader, ObjectEditFileReader *objectEditFileReader, ISAR_SPLIT_REND_BITS_DATA *splitRendBits, #ifdef FIX_FLOAT_1539_G192_FORMAT_SWITCH IVAS_DEC_HANDLE *phIvasDec, #else IVAS_DEC_HANDLE hIvasDec, #endif int16_t *pcmBuf ) { Loading @@ -2014,9 +2003,7 @@ static ivas_error decodeG192( uint16_t bit_stream[IVAS_MAX_BITS_PER_FRAME + 4 * 8]; int16_t i, num_bits; int16_t bfi = 0; #ifdef FIX_FLOAT_1539_G192_FORMAT_SWITCH IVAS_DEC_HANDLE hIvasDec = *phIvasDec; #endif AudioFileWriter *afWriter = NULL; MasaFileWriter *masaWriter = NULL; bool decodedGoodFrame = false; Loading @@ -2040,7 +2027,9 @@ static ivas_error decodeG192( int16_t isSplitRend, isSplitCoded; IVAS_RENDER_CONFIG_DATA renderConfig; RenderConfigReader *renderConfigReader = NULL; #ifdef FIX_FLOAT_1539_G192_FORMAT_SWITCH #ifdef FIX_FMSW_DEC_EXT bool restartNeeded = false; #else bool restartNeeded; #endif Loading Loading @@ -2133,6 +2122,7 @@ static ivas_error decodeG192( fprintf( stderr, "\nError getting render frame size in samples\n" ); return error; } if ( ( error = IVAS_DEC_GetReferencesUpdateFrequency( hIvasDec, &vec_pos_len ) ) != IVAS_ERR_OK ) { fprintf( stderr, "\nError getting render frame size in samples\n" ); Loading Loading @@ -2297,7 +2287,6 @@ static ivas_error decodeG192( return error; } #ifdef FIX_FLOAT_1539_G192_FORMAT_SWITCH if ( ( error = IVAS_DEC_isRestartNeeded( hIvasDec, &restartNeeded ) ) != IVAS_ERR_OK ) { return error; Loading @@ -2311,7 +2300,6 @@ static ivas_error decodeG192( goto cleanup; } } #endif /* Placeholder for memory reallocation */ /* ... */ Loading Loading @@ -2430,6 +2418,18 @@ static ivas_error decodeG192( } } #ifdef FIX_FMSW_DEC_EXT /* Output writing update in case of format switching and EXTERNAL output */ if ( restartNeeded && arg.outputConfig == IVAS_AUDIO_CONFIG_EXTERNAL ) { if ( ( error = updateOnFormatSwitching( hIvasDec, &bsFormat, arg.outputWavFilename, &masaWriter, ismWriters, &nOutChannels, &numObj, arg.delayCompensationEnabled ) ) != IVAS_ERR_OK ) { fprintf( stderr, "Error in updateOnFormatSwitching(): %s\n", IVAS_DEC_GetErrorMessage( error ) ); goto cleanup; } } #endif /* Write current frame */ if ( decodedGoodFrame ) { Loading Loading @@ -2823,7 +2823,11 @@ static ivas_error decodeVoIP( int16_t i; IVAS_DEC_HANDLE hIvasDec = *phIvasDec; #ifdef FIX_FMSW_DEC_EXT bool restartNeeded = false; #else bool restartNeeded; #endif IVAS_RTP ivasRtp = { 0 }; IVAS_RTP srRtp = { 0 }; IVAS_RTP_SR_INFO srInfo = { true, false, 0, 20, IVAS_SR_TRANSPORT_LCLD }; Loading Loading @@ -3310,6 +3314,18 @@ static ivas_error decodeVoIP( } } #ifdef FIX_FMSW_DEC_EXT /* Output writing update in case of format switching and EXTERNAL output */ if ( restartNeeded && arg.outputConfig == IVAS_AUDIO_CONFIG_EXTERNAL ) { if ( ( error = updateOnFormatSwitching( hIvasDec, &bsFormat, arg.outputWavFilename, &masaWriter, ismWriters, &nOutChannels, &numObj, arg.delayCompensationEnabled ) ) != IVAS_ERR_OK ) { fprintf( stderr, "Error in updateOnFormatSwitching(): %s\n", IVAS_DEC_GetErrorMessage( error ) ); goto cleanup; } } #endif /* Write current frame */ if ( !srRtp.hPack && decodedGoodFrame ) { Loading Loading @@ -3918,4 +3934,80 @@ static ivas_error load_hrtf_from_file( return IVAS_ERR_OK; } #ifdef FIX_FMSW_DEC_EXT /*---------------------------------------------------------------------* * updateOnFormatSwitching() * * In case of IVAS format switching and EXTERNAL output, * update decoder wrt. output writing *---------------------------------------------------------------------*/ static ivas_error updateOnFormatSwitching( IVAS_DEC_HANDLE hIvasDec, /* i/o: IVAS decoder handle */ IVAS_DEC_BS_FORMAT *pBsFormat, /* o : format of currently decoded bitstream */ const char *outputWavFilename, /* i : name of the output audio file */ MasaFileWriter **ppMasaWriter, /* o : MasaFileWriter handle */ IsmFileWriter *ismWriters[IVAS_MAX_NUM_OBJECTS], /* o : 1-4 ismWriters handles */ int16_t *pNumOutChannels, /* o : number of output channels */ uint16_t *pNumObj, /* o : number of ISM objects */ const bool delayCompensationEnabled /* i : is delay compensation enabled */ ) { ivas_error error; /* in case of EXT output, the number of output audio channels can change */ if ( ( error = IVAS_DEC_GetNumOutputChannels( hIvasDec, pNumOutChannels ) ) != IVAS_ERR_OK ) { fprintf( stderr, "\nError in IVAS_DEC_GetNumOutputChannels, code: %d\n", error ); return error; } /* Get the format of currently decoded bitstream */ if ( ( error = IVAS_DEC_GetFormat( hIvasDec, pBsFormat ) ) != IVAS_ERR_OK ) { fprintf( stderr, "\nError in IVAS_DEC_GetFormat, code: %d\n", error ); return error; } *pNumObj = 0; if ( *pBsFormat == IVAS_DEC_BS_OBJ || *pBsFormat == IVAS_DEC_BS_MASA_ISM || *pBsFormat == IVAS_DEC_BS_SBA_ISM ) { if ( ( error = IVAS_DEC_GetNumObjects( hIvasDec, pNumObj ) ) != IVAS_ERR_OK ) { fprintf( stderr, "\nError in IVAS_DEC_GetNumObjects: %s\n", IVAS_DEC_GetErrorMessage( error ) ); return error; } /* If outputting ISM/OMASA/OSBA, ensure the output metadata files are opened */ for ( int16_t i = 0; i < *pNumObj; ++i ) { if ( ismWriters[i] == NULL ) { if ( ( error = IsmFileWriter_open( outputWavFilename, i, &ismWriters[i] ) ) != IVAS_ERR_OK ) { fprintf( stderr, "\nError: Error opening ISM decoded metadata file %s\n", IsmFileWriter_getFilePath( ismWriters[i] ) ); return error; } } } } /* If outputting MASA, ensure the output file metadata is opened */ if ( *pBsFormat == IVAS_DEC_BS_MASA || *pBsFormat == IVAS_DEC_BS_MASA_ISM ) { if ( ppMasaWriter != NULL ) { if ( ( error = MasaFileWriter_open( outputWavFilename, delayCompensationEnabled, ppMasaWriter ) ) != IVAS_ERR_OK ) { fprintf( stderr, "\nError: Error opening MASA decoded metadata file %s\n", MasaFileWriter_getFilePath( *ppMasaWriter ) ); return error; } } } return IVAS_ERR_OK; } #endif #undef WMC_TOOL_SKIP lib_com/core_com_config_fx.c +15 −0 Original line number Diff line number Diff line Loading @@ -825,7 +825,11 @@ Word16 getTcxLpcShapedAri( * Initialization of TCX *-----------------------------------------------------------------------*/ #ifdef HARMONIZE_2567_init_functions void init_tcx_cfg_fx( #else void init_tcx_cfg_ivas_fx( #endif TCX_CONFIG_HANDLE hTcxCfg, const Word32 total_brate, /*Q0*/ const Word32 sr_core, /*Q0*/ Loading @@ -841,7 +845,12 @@ void init_tcx_cfg_ivas_fx( const Word16 infoIGFStopFreq, /*Q0*/ const Word16 element_mode, /*Q0*/ const Word16 ini_frame, /*Q0*/ #ifdef HARMONIZE_2567_init_functions const Word16 MCT_flag, /*Q0*/ const Word16 fscaleFB /*Q0*/ ) #else const Word16 MCT_flag /*Q0*/ ) #endif { Word16 i; Word16 mdctWindowLength; Loading @@ -859,7 +868,11 @@ void init_tcx_cfg_ivas_fx( hTcxCfg->tcx_mdct_window_length_old = hTcxCfg->tcx_mdct_window_length; /*Q0*/ move16(); mdctWindowLength = getMdctWindowLength_fx( fscale ); /*Q0*/ #ifdef HARMONIZE_2567_init_functions mdctWindowLengthFB = getMdctWindowLength_fx( fscaleFB ); /*Q0*/ /* this replaces (int16_t) ( mdctWindowLength * input_Fs / sr_core ) as used in float */ #else mdctWindowLengthFB = (Word16) ( mdctWindowLength * input_Fs / sr_core ); #endif init_tcx_window_cfg_fx( hTcxCfg, sr_core, input_Fs, L_frame, L_frameTCX, mdctWindowLength, mdctWindowLengthFB, element_mode ); /* SQ deadzone & memory quantization*/ Loading Loading @@ -1080,6 +1093,7 @@ void init_tcx_window_cfg_fx( return; } #ifndef HARMONIZE_2567_init_functions void init_tcx_cfg_fx( TCX_CONFIG_HANDLE hTcxCfg, const Word32 total_brate, /*Q0*/ Loading Loading @@ -1227,3 +1241,4 @@ void init_tcx_cfg_fx( return; } #endif lib_com/gs_bitallocation_fx.c +0 −8 Original line number Diff line number Diff line Loading @@ -1146,22 +1146,14 @@ static Word16 Find_bit_alloc_IVAS_fx( /* bits_per_bands[i] = 112; */ bits_per_bands[i] = Q18_112; move32(); #ifndef FIX_2585_BIT_ALLOCATION_DIFF j = add( j, add( i, 1 ) ); #else j = add( i, 1 ); #endif } /* safety check for overage bit reallocation */ /* else if (bits_per_bands[i] + sum_bit / 3 > 112) */ ELSE IF( GT_32( L_add( bits_per_bands[i], Mpy_32_16_1( sum_bit, Q15_0_33 ) ), Q18_112 ) ) { #ifndef FIX_2585_BIT_ALLOCATION_DIFF j = add( j, add( i, 1 ) ); #else j = add( i, 1 ); #endif } } Loading lib_com/ivas_prot_fx.h +0 −22 Original line number Diff line number Diff line Loading @@ -1173,12 +1173,8 @@ void stereo_dft_dec_fx( Word32 stereo_dft_enc_synthesize_fx( STEREO_DFT_ENC_DATA_HANDLE hStereoDft, /* i/o: encoder stereo handle */ #ifdef NONBE_FIX_ISSUE_2206 Word32 *output_fx, /* i/o : output synthesis q_output */ Word16 *q_output, /* i/o : output synthesis Q0 */ #else Word32 *output_fx, /* o : output synthesis Q16 */ #endif Word16 *output_start_index, Word16 *output_end_index, const Word16 chan, /* i : channel number */ Loading Loading @@ -1358,12 +1354,8 @@ void stereo_tcx_init_dec_fx( void stereo_icBWE_enc_fx( CPE_ENC_HANDLE hCPE, /* i/o: CPE encoder structure */ #ifdef NONBE_FIX_ISSUE_2206_SWB_EXPERIMENT const Word16 shb_speech_ref_fx16[], /* i : SHB speech ref channel shb_speech_ref_q*/ const Word16 shb_speech_ref_q, /* i : SHB speech ref channel Q */ #else const Word16 shb_speech_ref_fx16[], /* i : SHB speech ref channel Q0*/ #endif Word16 shb_speech_nonref_fx_16[], /* i/o: SHB speech non-ref channel shb_speech_nonref_e*/ Word16 shb_speech_nonref_e, /* i/o: SHB speech non-ref channel */ const Word16 *voice_factors_fx /* i : voicing factors Q15 */ Loading Loading @@ -2673,9 +2665,7 @@ Word16 ivas_acelp_tcx20_switching_fx( Word16 *inp_fx, /* i : new input signal */ Word16 q_inp, /* i : i/p Q */ Word16 *wsp, /* i : input weighted signal */ #ifdef NONBE_FIX_ISSUE_2206 Word16 q_wsp, /* i : Q of input weighted signal */ #endif Word32 non_staX, /* i : unbound non-stationarity for sp/mu clas */ Word16 *pitch_fr, /* i : fraction pitch values */ Word16 *voicing_fr, /* i : fractional voicing values */ Loading Loading @@ -5707,12 +5697,8 @@ void pre_proc_ivas_fx( Word16 *epsP_fx_q, /* i : LP prediction errors */ Word16 lsp_new_fx[M], /* i/o: LSPs at the end of the frame Q15*/ Word16 lsp_mid_fx[M], /* i/o: LSPs in the middle of the frame Q15*/ #ifdef NONBE_FIX_ISSUE_2206 Word16 *new_inp_resamp16k_fx, /* o : new input signal @16kHz, non pre-emphasised, used by the WB TBE/BWE q_new_inp_resamp16k_fx*/ Word16 *q_new_inp_resamp16k_fx, /* o : Q value of new input signal @16kHz, non pre-emphasised, used by the WB TBE/BWE */ #else Word16 *new_inp_resamp16k_fx, /* o : new input signal @16kHz, non pre-emphasised, used by the WB TBE/BWE Q_new-1*/ #endif Word16 *Voicing_flag, /* o : voicing flag for HQ FEC Q0*/ Word16 old_wsp_fx[], /* i : weighted input signal buffer e_old_wsp*/ const Word16 e_old_wsp, /* i : Q value of weighted input signal buffer */ Loading Loading @@ -6087,12 +6073,8 @@ UWord16 get_indice_st( void stereo_mdct_core_enc_fx( CPE_ENC_HANDLE hCPE, /* i/o: CPE encoder structure */ #ifdef NONBE_FIX_ISSUE_2206_MDCT_STEREO_FIX_2549 Word16 new_samples[CPE_CHANNELS][L_INP], /* i : new samples new_samples_q*/ Word16 *new_samples_q, #else Word16 new_samples[CPE_CHANNELS][L_INP], /* i : new samples Qnew-1*/ #endif Word16 old_wsp[CPE_CHANNELS][L_WSP], /* i : 12.8kHz weighted speech (for LTP Qx*/ Word16 pitch_buf_fx[CPE_CHANNELS][NB_SUBFR16k] /* o : floating pitch for each subframe Q6*/ ); Loading Loading @@ -6139,12 +6121,8 @@ void stereo_switching_dec_fx( void ivas_mdct_core_whitening_enc_fx( CPE_ENC_HANDLE hCPE, /* i/o: CPE encoder structure */ #ifdef NONBE_FIX_ISSUE_2206_MDCT_STEREO_FIX_2549 Word16 new_samples_fx[CPE_CHANNELS][L_INP], /* i : new samples Q_new[]-1*/ Word16 *Q_new, /* i : new samples q */ #else Word16 new_samples_fx[CPE_CHANNELS][L_INP], /* i : new samples */ #endif Word16 old_wsp_fx[CPE_CHANNELS][L_WSP], /* i : 12.8kHz weighted speech (for LTP */ Word16 pitch_buf[CPE_CHANNELS][NB_SUBFR16k], /* o : floating pitch for each subframe */ Word32 *mdst_spectrum_long[CPE_CHANNELS], /* o : buffer for MDST spectrum */ Loading lib_com/ivas_stereo_td_bit_alloc_fx.c +4 −14 Original line number Diff line number Diff line Loading @@ -204,7 +204,6 @@ void tdm_bit_alloc( } ELSE { #ifdef FIX_2585_BIT_ALLOCATION_DIFF Word16 neg = 0; move16(); if ( bit_rate_diff_fx < 0 ) Loading @@ -212,17 +211,12 @@ void tdm_bit_alloc( neg = 1; move16(); } #endif IF( LT_16( ener_ratio_idx, LRTD_STEREO_MID_IS_PRIM ) ) { bit_rate_diff_fx = imult3216( bit_rate_diff_fx, sub( LRTD_STEREO_MID_IS_PRIM, ener_ratio_idx ) ); /*Q0*/ bit_rate_diff_fx = L_shr( bit_rate_diff_fx, 1 ); /*Q0*/ bit_rate_diff_fx = Mpy_32_16_1( L_abs( bit_rate_diff_fx ), 3277 /*0.1f in Q15*/ ); /*Q0*/ #ifdef FIX_2585_BIT_ALLOCATION_DIFF if ( neg != 0 ) #else if ( bit_rate_diff_fx < 0 ) #endif { bit_rate_diff_fx = L_negate( bit_rate_diff_fx ); } Loading @@ -232,11 +226,7 @@ void tdm_bit_alloc( bit_rate_diff_fx = imult3216( bit_rate_diff_fx, sub( ener_ratio_idx, LRTD_STEREO_MID_IS_PRIM ) ); /*Q0*/ bit_rate_diff_fx = L_shr( bit_rate_diff_fx, 1 ); /*Q0*/ bit_rate_diff_fx = Mpy_32_16_1( L_abs( bit_rate_diff_fx ), 3277 /*0.1f in Q15*/ ); /*Q0*/ #ifdef FIX_2585_BIT_ALLOCATION_DIFF if ( neg != 0 ) #else if ( bit_rate_diff_fx < 0 ) #endif { bit_rate_diff_fx = L_negate( bit_rate_diff_fx ); } Loading Loading @@ -338,11 +328,7 @@ void tdm_bit_alloc( *tdm_low_rate_mode = 0; move16(); } #ifndef FIX_2585_BIT_ALLOCATION_DIFF ELSE IF( ( tdm_lp_reuse_flag == 0 && LT_32( *total_brate_sec, TDM_UC_NORMAL_MODE_MINBR_LP_R ) && EQ_16( coder_type, UNVOICED ) ) || ( tdm_lp_reuse_flag == 0 && LE_32( *total_brate_sec, L_deposit_l( add( tdm_bit_allc_tbl[idx][0], MID_LP_BRATE ) ) ) ) ) #else ELSE IF( ( tdm_lp_reuse_flag == 0 && LT_32( *total_brate_sec, TDM_UC_NORMAL_MODE_MINBR_LP_R ) && EQ_16( coder_type, UNVOICED ) ) || ( tdm_lp_reuse_flag == 0 && LT_32( *total_brate_sec, L_deposit_l( add( tdm_bit_allc_tbl[idx][0], MID_LP_BRATE ) ) ) ) ) #endif { *total_brate_sec = L_add( *total_brate_sec, MID_LP_BRATE ); /*Q0*/ move32(); Loading Loading @@ -730,7 +716,11 @@ void tdm_SCh_LSF_intra_pred_fx( fixed_beta = 30801; // 0.94f in Q15 move16(); } #ifndef FIX_ISSUE_2613_WRONG_COMP_MACRO ELSE IF( element_brate <= IVAS_24k4 ) #else ELSE IF( LE_32( element_brate, IVAS_24k4 ) ) #endif // !FIX_ISSUE_2613_WRONG_COMP_MACRO { fixed_beta = 29818; // 0.91f in Q15 move16(); Loading Loading
apps/decoder.c +113 −21 Original line number Diff line number Diff line Loading @@ -159,14 +159,13 @@ typedef struct static bool parseCmdlIVAS_dec( int16_t argc, char **argv, DecArguments *arg ); static void usage_dec( void ); #ifdef FIX_FLOAT_1539_G192_FORMAT_SWITCH static ivas_error decodeG192( DecArguments arg, BS_READER_HANDLE hBsReader, IVAS_DEC_HRTF_BINARY_WRAPPER *hHrtfBinary, RotFileReader *headRotReader, RotFileReader *externalOrientationFileReader, RotFileReader *refRotReader, Vector3PairFileReader *referenceVectorReader, ObjectEditFileReader *objectEditFileReader, ISAR_SPLIT_REND_BITS_DATA *splitRendBits, IVAS_DEC_HANDLE *phIvasDec, int16_t *pcmBuf ); #else static ivas_error decodeG192( DecArguments arg, BS_READER_HANDLE hBsReader, IVAS_DEC_HRTF_BINARY_WRAPPER *hHrtfBinary, RotFileReader *headRotReader, RotFileReader *externalOrientationFileReader, RotFileReader *refRotReader, Vector3PairFileReader *referenceVectorReader, ObjectEditFileReader *objectEditFileReader, ISAR_SPLIT_REND_BITS_DATA *splitRendBits, IVAS_DEC_HANDLE hIvasDec, int16_t *pcmBuf ); #endif static ivas_error decodeVoIP( DecArguments arg, BS_READER_HANDLE hBsReader, IVAS_DEC_HRTF_BINARY_WRAPPER *hHrtf, RotFileReader *headRotReader, RotFileReader *externalOrientationFileReader, RotFileReader *refRotReader, Vector3PairFileReader *referenceVectorReader, ObjectEditFileReader *objectEditFileReader, ISAR_SPLIT_REND_BITS_DATA *splitRendBits, IVAS_DEC_HANDLE *phIvasDec, int16_t *pcmBuf ); static ivas_error load_hrtf_from_file( IVAS_DEC_HRTF_BINARY_WRAPPER *hHrtfBinary, IVAS_DEC_HANDLE hIvasDec, const IVAS_AUDIO_CONFIG OutputConfig, const int32_t output_Fs ); static void do_object_editing_fx( IVAS_EDITABLE_PARAMETERS *editableParameters, ObjectEditFileReader *objectEditFileReader ); #ifdef FIX_FMSW_DEC_EXT static ivas_error updateOnFormatSwitching( IVAS_DEC_HANDLE hIvasDec, IVAS_DEC_BS_FORMAT *pBsFormat, const char *outputWavFilename, MasaFileWriter **ppMasaWriter, IsmFileWriter *ismWriters[IVAS_MAX_NUM_OBJECTS], int16_t *pNumOutChannels, uint16_t *pNumObj, const bool delayCompensationEnabled ); #endif /*------------------------------------------------------------------------------------------* Loading Loading @@ -207,7 +206,6 @@ int main( reset_mem( USE_BYTES ); #endif splitRendBits.bits_buf = splitRendBitsBuf; /*------------------------------------------------------------------------------------------* Loading Loading @@ -457,7 +455,6 @@ int main( } } /*-------------------------------------------------------------------* * Load renderer configuration from file *--------------------------------------------------------------------*/ Loading Loading @@ -542,6 +539,7 @@ int main( fprintf( stderr, "Failed to get directivity patterns for one or more of IDs: %d %d %d %d\n\n", arg.directivityPatternId[0], arg.directivityPatternId[1], arg.directivityPatternId[2], arg.directivityPatternId[3] ); goto cleanup; } if ( ( error = RenderConfigReader_getDistanceAttenuation( renderConfigReader, renderConfig.distAtt_fx ) ) != IVAS_ERR_OK ) { fprintf( stderr, "Failed to get Distance Attenuation \n\n" ); Loading Loading @@ -612,6 +610,7 @@ int main( hLsCustomData.azimuth_fx[i] = (Word32) ( hLsCustomData.azimuth[i] * ( 1u << 22 ) ); hLsCustomData.elevation_fx[i] = (Word32) ( hLsCustomData.elevation[i] * ( 1u << 22 ) ); } if ( ( error = IVAS_DEC_FeedCustomLsData( hIvasDec, hLsCustomData ) ) != IVAS_ERR_OK ) { fprintf( stderr, "\nIVAS_DEC_FeedCustomLsData failed: %s\n", IVAS_DEC_GetErrorMessage( error ) ); Loading Loading @@ -670,11 +669,7 @@ int main( } else { #ifdef FIX_FLOAT_1539_G192_FORMAT_SWITCH error = decodeG192( arg, hBsReader, &hHrtfBinary, headRotReader, externalOrientationFileReader, refRotReader, referenceVectorReader, objectEditFileReader, &splitRendBits, &hIvasDec, pcmBuf ); #else error = decodeG192( arg, hBsReader, &hHrtfBinary, headRotReader, externalOrientationFileReader, refRotReader, referenceVectorReader, objectEditFileReader, &splitRendBits, hIvasDec, pcmBuf ); #endif } if ( error == IVAS_ERR_OK || error == IVAS_ERR_END_OF_FILE ) Loading @@ -694,7 +689,6 @@ int main( goto cleanup; } /*------------------------------------------------------------------------------------------* * Close files and deallocate resources *------------------------------------------------------------------------------------------*/ Loading Loading @@ -742,7 +736,6 @@ cleanup: print_wmops(); print_mem( NULL ); #endif if ( !arg.quietModeEnabled ) { printf( "\n" ); Loading Loading @@ -2002,11 +1995,7 @@ static ivas_error decodeG192( Vector3PairFileReader *referenceVectorReader, ObjectEditFileReader *objectEditFileReader, ISAR_SPLIT_REND_BITS_DATA *splitRendBits, #ifdef FIX_FLOAT_1539_G192_FORMAT_SWITCH IVAS_DEC_HANDLE *phIvasDec, #else IVAS_DEC_HANDLE hIvasDec, #endif int16_t *pcmBuf ) { Loading @@ -2014,9 +2003,7 @@ static ivas_error decodeG192( uint16_t bit_stream[IVAS_MAX_BITS_PER_FRAME + 4 * 8]; int16_t i, num_bits; int16_t bfi = 0; #ifdef FIX_FLOAT_1539_G192_FORMAT_SWITCH IVAS_DEC_HANDLE hIvasDec = *phIvasDec; #endif AudioFileWriter *afWriter = NULL; MasaFileWriter *masaWriter = NULL; bool decodedGoodFrame = false; Loading @@ -2040,7 +2027,9 @@ static ivas_error decodeG192( int16_t isSplitRend, isSplitCoded; IVAS_RENDER_CONFIG_DATA renderConfig; RenderConfigReader *renderConfigReader = NULL; #ifdef FIX_FLOAT_1539_G192_FORMAT_SWITCH #ifdef FIX_FMSW_DEC_EXT bool restartNeeded = false; #else bool restartNeeded; #endif Loading Loading @@ -2133,6 +2122,7 @@ static ivas_error decodeG192( fprintf( stderr, "\nError getting render frame size in samples\n" ); return error; } if ( ( error = IVAS_DEC_GetReferencesUpdateFrequency( hIvasDec, &vec_pos_len ) ) != IVAS_ERR_OK ) { fprintf( stderr, "\nError getting render frame size in samples\n" ); Loading Loading @@ -2297,7 +2287,6 @@ static ivas_error decodeG192( return error; } #ifdef FIX_FLOAT_1539_G192_FORMAT_SWITCH if ( ( error = IVAS_DEC_isRestartNeeded( hIvasDec, &restartNeeded ) ) != IVAS_ERR_OK ) { return error; Loading @@ -2311,7 +2300,6 @@ static ivas_error decodeG192( goto cleanup; } } #endif /* Placeholder for memory reallocation */ /* ... */ Loading Loading @@ -2430,6 +2418,18 @@ static ivas_error decodeG192( } } #ifdef FIX_FMSW_DEC_EXT /* Output writing update in case of format switching and EXTERNAL output */ if ( restartNeeded && arg.outputConfig == IVAS_AUDIO_CONFIG_EXTERNAL ) { if ( ( error = updateOnFormatSwitching( hIvasDec, &bsFormat, arg.outputWavFilename, &masaWriter, ismWriters, &nOutChannels, &numObj, arg.delayCompensationEnabled ) ) != IVAS_ERR_OK ) { fprintf( stderr, "Error in updateOnFormatSwitching(): %s\n", IVAS_DEC_GetErrorMessage( error ) ); goto cleanup; } } #endif /* Write current frame */ if ( decodedGoodFrame ) { Loading Loading @@ -2823,7 +2823,11 @@ static ivas_error decodeVoIP( int16_t i; IVAS_DEC_HANDLE hIvasDec = *phIvasDec; #ifdef FIX_FMSW_DEC_EXT bool restartNeeded = false; #else bool restartNeeded; #endif IVAS_RTP ivasRtp = { 0 }; IVAS_RTP srRtp = { 0 }; IVAS_RTP_SR_INFO srInfo = { true, false, 0, 20, IVAS_SR_TRANSPORT_LCLD }; Loading Loading @@ -3310,6 +3314,18 @@ static ivas_error decodeVoIP( } } #ifdef FIX_FMSW_DEC_EXT /* Output writing update in case of format switching and EXTERNAL output */ if ( restartNeeded && arg.outputConfig == IVAS_AUDIO_CONFIG_EXTERNAL ) { if ( ( error = updateOnFormatSwitching( hIvasDec, &bsFormat, arg.outputWavFilename, &masaWriter, ismWriters, &nOutChannels, &numObj, arg.delayCompensationEnabled ) ) != IVAS_ERR_OK ) { fprintf( stderr, "Error in updateOnFormatSwitching(): %s\n", IVAS_DEC_GetErrorMessage( error ) ); goto cleanup; } } #endif /* Write current frame */ if ( !srRtp.hPack && decodedGoodFrame ) { Loading Loading @@ -3918,4 +3934,80 @@ static ivas_error load_hrtf_from_file( return IVAS_ERR_OK; } #ifdef FIX_FMSW_DEC_EXT /*---------------------------------------------------------------------* * updateOnFormatSwitching() * * In case of IVAS format switching and EXTERNAL output, * update decoder wrt. output writing *---------------------------------------------------------------------*/ static ivas_error updateOnFormatSwitching( IVAS_DEC_HANDLE hIvasDec, /* i/o: IVAS decoder handle */ IVAS_DEC_BS_FORMAT *pBsFormat, /* o : format of currently decoded bitstream */ const char *outputWavFilename, /* i : name of the output audio file */ MasaFileWriter **ppMasaWriter, /* o : MasaFileWriter handle */ IsmFileWriter *ismWriters[IVAS_MAX_NUM_OBJECTS], /* o : 1-4 ismWriters handles */ int16_t *pNumOutChannels, /* o : number of output channels */ uint16_t *pNumObj, /* o : number of ISM objects */ const bool delayCompensationEnabled /* i : is delay compensation enabled */ ) { ivas_error error; /* in case of EXT output, the number of output audio channels can change */ if ( ( error = IVAS_DEC_GetNumOutputChannels( hIvasDec, pNumOutChannels ) ) != IVAS_ERR_OK ) { fprintf( stderr, "\nError in IVAS_DEC_GetNumOutputChannels, code: %d\n", error ); return error; } /* Get the format of currently decoded bitstream */ if ( ( error = IVAS_DEC_GetFormat( hIvasDec, pBsFormat ) ) != IVAS_ERR_OK ) { fprintf( stderr, "\nError in IVAS_DEC_GetFormat, code: %d\n", error ); return error; } *pNumObj = 0; if ( *pBsFormat == IVAS_DEC_BS_OBJ || *pBsFormat == IVAS_DEC_BS_MASA_ISM || *pBsFormat == IVAS_DEC_BS_SBA_ISM ) { if ( ( error = IVAS_DEC_GetNumObjects( hIvasDec, pNumObj ) ) != IVAS_ERR_OK ) { fprintf( stderr, "\nError in IVAS_DEC_GetNumObjects: %s\n", IVAS_DEC_GetErrorMessage( error ) ); return error; } /* If outputting ISM/OMASA/OSBA, ensure the output metadata files are opened */ for ( int16_t i = 0; i < *pNumObj; ++i ) { if ( ismWriters[i] == NULL ) { if ( ( error = IsmFileWriter_open( outputWavFilename, i, &ismWriters[i] ) ) != IVAS_ERR_OK ) { fprintf( stderr, "\nError: Error opening ISM decoded metadata file %s\n", IsmFileWriter_getFilePath( ismWriters[i] ) ); return error; } } } } /* If outputting MASA, ensure the output file metadata is opened */ if ( *pBsFormat == IVAS_DEC_BS_MASA || *pBsFormat == IVAS_DEC_BS_MASA_ISM ) { if ( ppMasaWriter != NULL ) { if ( ( error = MasaFileWriter_open( outputWavFilename, delayCompensationEnabled, ppMasaWriter ) ) != IVAS_ERR_OK ) { fprintf( stderr, "\nError: Error opening MASA decoded metadata file %s\n", MasaFileWriter_getFilePath( *ppMasaWriter ) ); return error; } } } return IVAS_ERR_OK; } #endif #undef WMC_TOOL_SKIP
lib_com/core_com_config_fx.c +15 −0 Original line number Diff line number Diff line Loading @@ -825,7 +825,11 @@ Word16 getTcxLpcShapedAri( * Initialization of TCX *-----------------------------------------------------------------------*/ #ifdef HARMONIZE_2567_init_functions void init_tcx_cfg_fx( #else void init_tcx_cfg_ivas_fx( #endif TCX_CONFIG_HANDLE hTcxCfg, const Word32 total_brate, /*Q0*/ const Word32 sr_core, /*Q0*/ Loading @@ -841,7 +845,12 @@ void init_tcx_cfg_ivas_fx( const Word16 infoIGFStopFreq, /*Q0*/ const Word16 element_mode, /*Q0*/ const Word16 ini_frame, /*Q0*/ #ifdef HARMONIZE_2567_init_functions const Word16 MCT_flag, /*Q0*/ const Word16 fscaleFB /*Q0*/ ) #else const Word16 MCT_flag /*Q0*/ ) #endif { Word16 i; Word16 mdctWindowLength; Loading @@ -859,7 +868,11 @@ void init_tcx_cfg_ivas_fx( hTcxCfg->tcx_mdct_window_length_old = hTcxCfg->tcx_mdct_window_length; /*Q0*/ move16(); mdctWindowLength = getMdctWindowLength_fx( fscale ); /*Q0*/ #ifdef HARMONIZE_2567_init_functions mdctWindowLengthFB = getMdctWindowLength_fx( fscaleFB ); /*Q0*/ /* this replaces (int16_t) ( mdctWindowLength * input_Fs / sr_core ) as used in float */ #else mdctWindowLengthFB = (Word16) ( mdctWindowLength * input_Fs / sr_core ); #endif init_tcx_window_cfg_fx( hTcxCfg, sr_core, input_Fs, L_frame, L_frameTCX, mdctWindowLength, mdctWindowLengthFB, element_mode ); /* SQ deadzone & memory quantization*/ Loading Loading @@ -1080,6 +1093,7 @@ void init_tcx_window_cfg_fx( return; } #ifndef HARMONIZE_2567_init_functions void init_tcx_cfg_fx( TCX_CONFIG_HANDLE hTcxCfg, const Word32 total_brate, /*Q0*/ Loading Loading @@ -1227,3 +1241,4 @@ void init_tcx_cfg_fx( return; } #endif
lib_com/gs_bitallocation_fx.c +0 −8 Original line number Diff line number Diff line Loading @@ -1146,22 +1146,14 @@ static Word16 Find_bit_alloc_IVAS_fx( /* bits_per_bands[i] = 112; */ bits_per_bands[i] = Q18_112; move32(); #ifndef FIX_2585_BIT_ALLOCATION_DIFF j = add( j, add( i, 1 ) ); #else j = add( i, 1 ); #endif } /* safety check for overage bit reallocation */ /* else if (bits_per_bands[i] + sum_bit / 3 > 112) */ ELSE IF( GT_32( L_add( bits_per_bands[i], Mpy_32_16_1( sum_bit, Q15_0_33 ) ), Q18_112 ) ) { #ifndef FIX_2585_BIT_ALLOCATION_DIFF j = add( j, add( i, 1 ) ); #else j = add( i, 1 ); #endif } } Loading
lib_com/ivas_prot_fx.h +0 −22 Original line number Diff line number Diff line Loading @@ -1173,12 +1173,8 @@ void stereo_dft_dec_fx( Word32 stereo_dft_enc_synthesize_fx( STEREO_DFT_ENC_DATA_HANDLE hStereoDft, /* i/o: encoder stereo handle */ #ifdef NONBE_FIX_ISSUE_2206 Word32 *output_fx, /* i/o : output synthesis q_output */ Word16 *q_output, /* i/o : output synthesis Q0 */ #else Word32 *output_fx, /* o : output synthesis Q16 */ #endif Word16 *output_start_index, Word16 *output_end_index, const Word16 chan, /* i : channel number */ Loading Loading @@ -1358,12 +1354,8 @@ void stereo_tcx_init_dec_fx( void stereo_icBWE_enc_fx( CPE_ENC_HANDLE hCPE, /* i/o: CPE encoder structure */ #ifdef NONBE_FIX_ISSUE_2206_SWB_EXPERIMENT const Word16 shb_speech_ref_fx16[], /* i : SHB speech ref channel shb_speech_ref_q*/ const Word16 shb_speech_ref_q, /* i : SHB speech ref channel Q */ #else const Word16 shb_speech_ref_fx16[], /* i : SHB speech ref channel Q0*/ #endif Word16 shb_speech_nonref_fx_16[], /* i/o: SHB speech non-ref channel shb_speech_nonref_e*/ Word16 shb_speech_nonref_e, /* i/o: SHB speech non-ref channel */ const Word16 *voice_factors_fx /* i : voicing factors Q15 */ Loading Loading @@ -2673,9 +2665,7 @@ Word16 ivas_acelp_tcx20_switching_fx( Word16 *inp_fx, /* i : new input signal */ Word16 q_inp, /* i : i/p Q */ Word16 *wsp, /* i : input weighted signal */ #ifdef NONBE_FIX_ISSUE_2206 Word16 q_wsp, /* i : Q of input weighted signal */ #endif Word32 non_staX, /* i : unbound non-stationarity for sp/mu clas */ Word16 *pitch_fr, /* i : fraction pitch values */ Word16 *voicing_fr, /* i : fractional voicing values */ Loading Loading @@ -5707,12 +5697,8 @@ void pre_proc_ivas_fx( Word16 *epsP_fx_q, /* i : LP prediction errors */ Word16 lsp_new_fx[M], /* i/o: LSPs at the end of the frame Q15*/ Word16 lsp_mid_fx[M], /* i/o: LSPs in the middle of the frame Q15*/ #ifdef NONBE_FIX_ISSUE_2206 Word16 *new_inp_resamp16k_fx, /* o : new input signal @16kHz, non pre-emphasised, used by the WB TBE/BWE q_new_inp_resamp16k_fx*/ Word16 *q_new_inp_resamp16k_fx, /* o : Q value of new input signal @16kHz, non pre-emphasised, used by the WB TBE/BWE */ #else Word16 *new_inp_resamp16k_fx, /* o : new input signal @16kHz, non pre-emphasised, used by the WB TBE/BWE Q_new-1*/ #endif Word16 *Voicing_flag, /* o : voicing flag for HQ FEC Q0*/ Word16 old_wsp_fx[], /* i : weighted input signal buffer e_old_wsp*/ const Word16 e_old_wsp, /* i : Q value of weighted input signal buffer */ Loading Loading @@ -6087,12 +6073,8 @@ UWord16 get_indice_st( void stereo_mdct_core_enc_fx( CPE_ENC_HANDLE hCPE, /* i/o: CPE encoder structure */ #ifdef NONBE_FIX_ISSUE_2206_MDCT_STEREO_FIX_2549 Word16 new_samples[CPE_CHANNELS][L_INP], /* i : new samples new_samples_q*/ Word16 *new_samples_q, #else Word16 new_samples[CPE_CHANNELS][L_INP], /* i : new samples Qnew-1*/ #endif Word16 old_wsp[CPE_CHANNELS][L_WSP], /* i : 12.8kHz weighted speech (for LTP Qx*/ Word16 pitch_buf_fx[CPE_CHANNELS][NB_SUBFR16k] /* o : floating pitch for each subframe Q6*/ ); Loading Loading @@ -6139,12 +6121,8 @@ void stereo_switching_dec_fx( void ivas_mdct_core_whitening_enc_fx( CPE_ENC_HANDLE hCPE, /* i/o: CPE encoder structure */ #ifdef NONBE_FIX_ISSUE_2206_MDCT_STEREO_FIX_2549 Word16 new_samples_fx[CPE_CHANNELS][L_INP], /* i : new samples Q_new[]-1*/ Word16 *Q_new, /* i : new samples q */ #else Word16 new_samples_fx[CPE_CHANNELS][L_INP], /* i : new samples */ #endif Word16 old_wsp_fx[CPE_CHANNELS][L_WSP], /* i : 12.8kHz weighted speech (for LTP */ Word16 pitch_buf[CPE_CHANNELS][NB_SUBFR16k], /* o : floating pitch for each subframe */ Word32 *mdst_spectrum_long[CPE_CHANNELS], /* o : buffer for MDST spectrum */ Loading
lib_com/ivas_stereo_td_bit_alloc_fx.c +4 −14 Original line number Diff line number Diff line Loading @@ -204,7 +204,6 @@ void tdm_bit_alloc( } ELSE { #ifdef FIX_2585_BIT_ALLOCATION_DIFF Word16 neg = 0; move16(); if ( bit_rate_diff_fx < 0 ) Loading @@ -212,17 +211,12 @@ void tdm_bit_alloc( neg = 1; move16(); } #endif IF( LT_16( ener_ratio_idx, LRTD_STEREO_MID_IS_PRIM ) ) { bit_rate_diff_fx = imult3216( bit_rate_diff_fx, sub( LRTD_STEREO_MID_IS_PRIM, ener_ratio_idx ) ); /*Q0*/ bit_rate_diff_fx = L_shr( bit_rate_diff_fx, 1 ); /*Q0*/ bit_rate_diff_fx = Mpy_32_16_1( L_abs( bit_rate_diff_fx ), 3277 /*0.1f in Q15*/ ); /*Q0*/ #ifdef FIX_2585_BIT_ALLOCATION_DIFF if ( neg != 0 ) #else if ( bit_rate_diff_fx < 0 ) #endif { bit_rate_diff_fx = L_negate( bit_rate_diff_fx ); } Loading @@ -232,11 +226,7 @@ void tdm_bit_alloc( bit_rate_diff_fx = imult3216( bit_rate_diff_fx, sub( ener_ratio_idx, LRTD_STEREO_MID_IS_PRIM ) ); /*Q0*/ bit_rate_diff_fx = L_shr( bit_rate_diff_fx, 1 ); /*Q0*/ bit_rate_diff_fx = Mpy_32_16_1( L_abs( bit_rate_diff_fx ), 3277 /*0.1f in Q15*/ ); /*Q0*/ #ifdef FIX_2585_BIT_ALLOCATION_DIFF if ( neg != 0 ) #else if ( bit_rate_diff_fx < 0 ) #endif { bit_rate_diff_fx = L_negate( bit_rate_diff_fx ); } Loading Loading @@ -338,11 +328,7 @@ void tdm_bit_alloc( *tdm_low_rate_mode = 0; move16(); } #ifndef FIX_2585_BIT_ALLOCATION_DIFF ELSE IF( ( tdm_lp_reuse_flag == 0 && LT_32( *total_brate_sec, TDM_UC_NORMAL_MODE_MINBR_LP_R ) && EQ_16( coder_type, UNVOICED ) ) || ( tdm_lp_reuse_flag == 0 && LE_32( *total_brate_sec, L_deposit_l( add( tdm_bit_allc_tbl[idx][0], MID_LP_BRATE ) ) ) ) ) #else ELSE IF( ( tdm_lp_reuse_flag == 0 && LT_32( *total_brate_sec, TDM_UC_NORMAL_MODE_MINBR_LP_R ) && EQ_16( coder_type, UNVOICED ) ) || ( tdm_lp_reuse_flag == 0 && LT_32( *total_brate_sec, L_deposit_l( add( tdm_bit_allc_tbl[idx][0], MID_LP_BRATE ) ) ) ) ) #endif { *total_brate_sec = L_add( *total_brate_sec, MID_LP_BRATE ); /*Q0*/ move32(); Loading Loading @@ -730,7 +716,11 @@ void tdm_SCh_LSF_intra_pred_fx( fixed_beta = 30801; // 0.94f in Q15 move16(); } #ifndef FIX_ISSUE_2613_WRONG_COMP_MACRO ELSE IF( element_brate <= IVAS_24k4 ) #else ELSE IF( LE_32( element_brate, IVAS_24k4 ) ) #endif // !FIX_ISSUE_2613_WRONG_COMP_MACRO { fixed_beta = 29818; // 0.91f in Q15 move16(); Loading