From 7ffde526906dfa69d89aacb290a5e49179d540b7 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Wed, 16 Apr 2025 09:05:49 +0200 Subject: [PATCH 1/3] Accept FIX_911_REMOVE_CREND_DUPLICATION --- lib_com/options.h | 1 - lib_rend/ivas_crend_fx.c | 189 ----------------------------------- lib_rend/ivas_prot_rend_fx.h | 19 ---- lib_rend/lib_rend.c | 50 --------- 4 files changed, 259 deletions(-) diff --git a/lib_com/options.h b/lib_com/options.h index 1b1465cc5..05c7634d0 100755 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -94,7 +94,6 @@ #endif #define NONBE_FIX_1058_DECODER_ERROR_WITH_REVERB_ROOM /* FhG: issue 1058: do not initialize EFAP when IntSetup is HOA3 */ #define NONBE_FIX_943_RECONFIG_IGF_AFTER_SETTING_BW /* FhG: issue 943: fix crash in BW switchin from WB in MDCT-Stereo core encoder */ -#define FIX_911_REMOVE_CREND_DUPLICATION /* VA: issue 911: resolve duplication of CRend binaural external renderer function */ #define FIX_938_GCC_12_WARNINGS /* VA: issue #938: remove set_f(.,.,0) call in which length is always 0 to remove GCC 12.0 warning */ #define NONBE_FIX_944_FEC_OMASA_1SEP_OBJ_MASA /* Nokia: issue 944: fix FEC error in OMASA */ diff --git a/lib_rend/ivas_crend_fx.c b/lib_rend/ivas_crend_fx.c index f265b0ac7..ef2c477a3 100644 --- a/lib_rend/ivas_crend_fx.c +++ b/lib_rend/ivas_crend_fx.c @@ -1426,11 +1426,9 @@ ivas_error ivas_rend_initCrendWrapper( ( *pCrend )->binaural_latency_ns = 0; move32(); ( *pCrend )->hHrtfCrend = NULL; -#ifdef FIX_911_REMOVE_CREND_DUPLICATION ( *pCrend )->io_qfactor = 0; move16(); ( *pCrend )->p_io_qfactor = &( *pCrend )->io_qfactor; -#endif #ifdef SPLIT_REND_WITH_HEAD_ROT FOR( pos_idx = 0; pos_idx < num_poses; pos_idx++ ) @@ -2054,177 +2052,6 @@ static ivas_error ivas_rend_crendConvolver( return IVAS_ERR_OK; } -#ifndef FIX_911_REMOVE_CREND_DUPLICATION -/*-----------------------------------------------------------------------------------------* - * Function ivas_rend_crend_Process() - * - * Process call for IVAS Crend renderer - *-----------------------------------------------------------------------------------------*/ - -ivas_error ivas_rend_crendProcess( - const CREND_WRAPPER *pCrend, - const AUDIO_CONFIG inConfig, - const AUDIO_CONFIG outConfig, - DECODER_CONFIG_HANDLE hDecoderConfig, - COMBINED_ORIENTATION_HANDLE hCombinedOrientationData, - IVAS_OUTPUT_SETUP_HANDLE hIntSetup, - EFAP_HANDLE hEFAPdata, - Word32 *output_fx[], /* i/o: input/output audio channels Qx */ - const Word32 output_Fs, -#ifdef SPLIT_REND_WITH_HEAD_ROT - const Word16 num_subframes /* i : number of subframes to render */, - const Word16 pos_idx -#else - const Word16 num_subframes /* i : number of subframes to render */ -#endif -) -{ - Word16 i, subframe_idx, subframe_len; - Word16 nchan_out; - Word32 pcm_tmp_fx[BINAURAL_CHANNELS][L_FRAME48k]; - Word32 *p_pcm_tmp_fx[BINAURAL_CHANNELS]; - IVAS_REND_AudioConfigType inConfigType; - Word8 combinedOrientationEnabled; - ivas_error error; - CREND_HANDLE hCrend; - -#ifdef SPLIT_REND_WITH_HEAD_ROT - hCrend = pCrend->hCrend[pos_idx]; -#else - hCrend = pCrend->hCrend; -#endif - - combinedOrientationEnabled = 0; - move16(); - IF( hCombinedOrientationData != NULL ) - { - FOR( subframe_idx = 0; subframe_idx < num_subframes; subframe_idx++ ) - { - IF( hCombinedOrientationData->enableCombinedOrientation[subframe_idx] != 0 ) - { - combinedOrientationEnabled = 1; - move16(); - BREAK; - } - } - } - - push_wmops( "ivas_rend_crendProcess" ); - inConfigType = getAudioConfigType( inConfig ); - - IF( NE_32( ( error = getAudioConfigNumChannels( outConfig, &nchan_out ) ), IVAS_ERR_OK ) ) - { - return error; - } - subframe_len = L_SUBFRAME_48k; - move16(); - SWITCH( output_Fs ) - { - case 48000: - subframe_len = L_SUBFRAME_48k; - move16(); - BREAK; - case 32000: - subframe_len = L_SUBFRAME_32k; - move16(); - BREAK; - case 16000: - subframe_len = L_SUBFRAME_16k; - move16(); - BREAK; - case 8000: - subframe_len = L_SUBFRAME_8k; - move16(); - BREAK; - default: - BREAK; - } - - FOR( i = 0; i < BINAURAL_CHANNELS; i++ ) - { - p_pcm_tmp_fx[i] = pcm_tmp_fx[i]; - move32(); - } - - FOR( subframe_idx = 0; subframe_idx < num_subframes; subframe_idx++ ) - { - /* Early Reflections */ - IF( hCrend->reflections != NULL ) - { - test(); - IF( EQ_16( hCrend->reflections->use_er, 1 ) && EQ_16( hCrend->reflections->is_ready, 1 ) ) - { - IF( NE_32( ( error = ivas_er_process( hCrend->reflections, subframe_len, subframe_idx, output_fx, inConfig ) ), IVAS_ERR_OK ) ) - { - return error; - } - } - } - - test(); - IF( hDecoderConfig && combinedOrientationEnabled ) - { - /* Orientation tracking */ - - /* Rotation in SHD for: - MC with elevation (5_1_2 / 5_1_4 / 7_1_4) -> BINAURAL - SBA SPAR -> BINAURAL or BINAURAL_ROOM - */ - test(); - test(); - test(); - IF( EQ_16( inConfig, IVAS_AUDIO_CONFIG_FOA ) || EQ_16( inConfig, IVAS_AUDIO_CONFIG_HOA2 ) || EQ_16( inConfig, IVAS_AUDIO_CONFIG_HOA3 ) ) - { - rotateFrame_shd( hCombinedOrientationData, output_fx, subframe_len, *hIntSetup, subframe_idx ); - } - /* Rotation in SD for MC -> BINAURAL_ROOM */ - ELSE IF( ( hIntSetup != NULL ) && hIntSetup->is_loudspeaker_setup ) - { - rotateFrame_sd( hCombinedOrientationData, output_fx, subframe_len, *hIntSetup, hEFAPdata, subframe_idx ); - } - } - test(); - IF( EQ_16( inConfigType, IVAS_REND_AUDIO_CONFIG_TYPE_CHANNEL_BASED ) || EQ_16( inConfigType, IVAS_REND_AUDIO_CONFIG_TYPE_AMBISONICS ) ) - { -#ifdef SPLIT_REND_WITH_HEAD_ROT - IF( NE_32( ( error = ivas_rend_crendConvolver( pCrend, inConfig, outConfig, output_fx, p_pcm_tmp_fx, output_Fs, subframe_idx, pos_idx ) ), IVAS_ERR_OK ) ) -#else - IF( NE_32( ( error = ivas_rend_crendConvolver( pCrend, inConfig, outConfig, output_fx, p_pcm_tmp_fx, output_Fs, subframe_idx ) ), IVAS_ERR_OK ) ) -#endif - { - return error; - } - - IF( hCrend->hReverb != NULL ) - { -#ifdef SPLIT_REND_WITH_HEAD_ROT - IF( NE_32( ( error = ivas_reverb_process_fx( pCrend->hCrend[pos_idx]->hReverb, inConfig, 1, output_fx, p_pcm_tmp_fx, subframe_idx ) ), IVAS_ERR_OK ) ) -#else - IF( NE_32( ( error = ivas_reverb_process_fx( pCrend->hCrend->hReverb, inConfig, 1, output_fx, p_pcm_tmp_fx, subframe_idx ) ), IVAS_ERR_OK ) ) -#endif - { - return error; - } - } - - /* update combined orientation access index */ - ivas_combined_orientation_update_index( hCombinedOrientationData, subframe_len ); - } - ELSE - { - return IVAS_ERR_INVALID_INPUT_FORMAT; - } - } - /* move to output */ - FOR( i = 0; i < nchan_out; i++ ) - { - MVR2R_WORD32( pcm_tmp_fx[i], output_fx[i], imult1616( num_subframes, subframe_len ) ); - } - - pop_wmops(); - return IVAS_ERR_OK; -} -#endif /*-----------------------------------------------------------------------------------------* * Function ivas_rend_crendProcessSubframe() @@ -2299,10 +2126,8 @@ ivas_error ivas_rend_crendProcessSubframe( p_pcm_tmp_fx[ch] = pcm_tmp_fx[ch]; } -#ifdef FIX_911_REMOVE_CREND_DUPLICATION IF( hTcBuffer != NULL ) { -#endif slot_size = hTcBuffer->n_samples_granularity; move16(); @@ -2319,7 +2144,6 @@ ivas_error ivas_rend_crendProcessSubframe( last_sf = add( last_sf, 1 ); } -#ifdef FIX_911_REMOVE_CREND_DUPLICATION subframe_len = -1; /* will be set later */ move16(); } @@ -2353,18 +2177,13 @@ ivas_error ivas_rend_crendProcessSubframe( last_sf_tmp = div_s( n_samples_to_render, den ); last_sf = shr( last_sf_tmp, sub( 15, n_den ) ); } -#endif FOR( subframe_idx = first_sf; subframe_idx < last_sf; subframe_idx++ ) { -#ifdef FIX_911_REMOVE_CREND_DUPLICATION if ( hTcBuffer != NULL ) { -#endif subframe_len = imult1616( hTcBuffer->subframe_nbslots[subframe_idx], hTcBuffer->n_samples_granularity ); -#ifdef FIX_911_REMOVE_CREND_DUPLICATION } -#endif /* Early Reflections */ IF( hCrend->reflections != NULL ) @@ -2439,15 +2258,11 @@ ivas_error ivas_rend_crendProcessSubframe( p_pcm_tmp_fx[ch] += subframe_len; } -#ifdef FIX_911_REMOVE_CREND_DUPLICATION if ( hTcBuffer != NULL ) { -#endif hTcBuffer->slots_rendered = add( hTcBuffer->subframe_nbslots[subframe_idx], hTcBuffer->slots_rendered ); move16(); -#ifdef FIX_911_REMOVE_CREND_DUPLICATION } -#endif } ELSE { @@ -2482,15 +2297,11 @@ ivas_error ivas_rend_crendProcessSubframe( MVR2R_WORD32( pcm_tmp_fx[ch], output[ch], n_samples_to_render ); // Qx } -#ifdef FIX_911_REMOVE_CREND_DUPLICATION if ( hTcBuffer != NULL ) { -#endif hTcBuffer->subframes_rendered = last_sf; move16(); -#ifdef FIX_911_REMOVE_CREND_DUPLICATION } -#endif pop_wmops(); diff --git a/lib_rend/ivas_prot_rend_fx.h b/lib_rend/ivas_prot_rend_fx.h index a72e7ec3d..4e23011b4 100644 --- a/lib_rend/ivas_prot_rend_fx.h +++ b/lib_rend/ivas_prot_rend_fx.h @@ -895,25 +895,6 @@ ivas_error ivas_rend_initCrendWrapper( #endif ); -#ifndef FIX_911_REMOVE_CREND_DUPLICATION -ivas_error ivas_rend_crendProcess( - const CREND_WRAPPER *pCrend, - const AUDIO_CONFIG inConfig, - const AUDIO_CONFIG outConfig, - DECODER_CONFIG_HANDLE hDecoderConfig, - COMBINED_ORIENTATION_HANDLE hCombinedOrientationData, - IVAS_OUTPUT_SETUP_HANDLE hIntSetup, - EFAP_HANDLE hEFAPdata, - Word32 *output[], /* i/o: input/output audio channels */ - const Word32 output_Fs, -#ifdef SPLIT_REND_WITH_HEAD_ROT - const Word16 num_subframes, /* i : number of subframes to render */ - const Word16 pos_idx /* i : pose index */ -#else - const Word16 num_subframes /* i : number of subframes to render */ -#endif -); -#endif ivas_error ivas_rend_crendProcessSubframe( const CREND_WRAPPER *pCrend, /* i/o: Crend wrapper handle */ const AUDIO_CONFIG inConfig, /* i : input audio configuration */ diff --git a/lib_rend/lib_rend.c b/lib_rend/lib_rend.c index 62bee3a6b..aea39eaa9 100644 --- a/lib_rend/lib_rend.c +++ b/lib_rend/lib_rend.c @@ -5982,14 +5982,7 @@ static ivas_error renderIsmToBinauralRoom( #ifdef SPLIT_REND_WITH_HEAD_ROT /* render 7_1_4 with BRIRs */ -#ifdef FIX_911_REMOVE_CREND_DUPLICATION IF( NE_32( ( error = ivas_rend_crendProcessSubframe( ismInput->crendWrapper, IVAS_AUDIO_CONFIG_7_1_4, IVAS_AUDIO_CONFIG_BINAURAL_ROOM_IR, NULL, NULL, NULL, NULL, NULL, p_tmpRendBuffer, p_tmpRendBuffer, ismInput->base.inputBuffer.config.numSamplesPerChannel, *ismInput->base.ctx.pOutSampleRate, 0 ) ), IVAS_ERR_OK ) ) -#else - IF( NE_32( ( error = ivas_rend_crendProcess( ismInput->crendWrapper, IVAS_AUDIO_CONFIG_7_1_4, IVAS_AUDIO_CONFIG_BINAURAL_ROOM_IR, - NULL, NULL, NULL, NULL, p_tmpRendBuffer, *ismInput->base.ctx.pOutSampleRate, - getNumSubframesInBuffer( &outAudio, *ismInput->base.ctx.pOutSampleRate ), 0 ) ), - IVAS_ERR_OK ) ) -#endif #else /* render 7_1_4 with BRIRs */ IF( NE_32( ( error = ivas_rend_crendProcess( ismInput->crendWrapper, IVAS_AUDIO_CONFIG_7_1_4, IVAS_AUDIO_CONFIG_BINAURAL_ROOM_IR, @@ -6806,13 +6799,7 @@ static ivas_error renderMcToBinaural( /* call CREND */ #ifdef SPLIT_REND_WITH_HEAD_ROT -#ifdef FIX_911_REMOVE_CREND_DUPLICATION IF( NE_32( ( error = ivas_rend_crendProcessSubframe( mcInput->crendWrapper, mcInput->base.inConfig, outConfig, NULL, NULL, NULL, NULL, NULL, p_tmpRendBuffer_fx, p_tmpRendBuffer_fx, mcInput->base.inputBuffer.config.numSamplesPerChannel, *mcInput->base.ctx.pOutSampleRate, 0 ) ), IVAS_ERR_OK ) ) -#else - IF( NE_32( ( error = ivas_rend_crendProcess( mcInput->crendWrapper, mcInput->base.inConfig, outConfig, NULL, NULL, NULL, NULL, p_tmpRendBuffer_fx, *mcInput->base.ctx.pOutSampleRate, - getNumSubframesInBuffer( &outAudio, *mcInput->base.ctx.pOutSampleRate ), 0 ) ), - IVAS_ERR_OK ) ) -#endif #else IF( NE_32( ( error = ivas_rend_crendProcess( mcInput->crendWrapper, mcInput->base.inConfig, outConfig, NULL, NULL, NULL, NULL, p_tmpRendBuffer_fx, *mcInput->base.ctx.pOutSampleRate, getNumSubframesInBuffer( &outAudio, *mcInput->base.ctx.pOutSampleRate ) ) ), @@ -6957,13 +6944,7 @@ static ivas_error renderMcToBinauralRoom( /* call CREND */ #ifdef SPLIT_REND_WITH_HEAD_ROT -#ifdef FIX_911_REMOVE_CREND_DUPLICATION IF( NE_32( ( error = ivas_rend_crendProcessSubframe( mcInput->crendWrapper, mcInput->base.inConfig, outConfig, NULL, NULL, NULL, NULL, NULL, p_tmpRendBuffer, p_tmpRendBuffer, mcInput->base.inputBuffer.config.numSamplesPerChannel, *mcInput->base.ctx.pOutSampleRate, 0 ) ), IVAS_ERR_OK ) ) -#else - IF( NE_32( ( error = ivas_rend_crendProcess( mcInput->crendWrapper, mcInput->base.inConfig, outConfig, NULL, NULL, NULL, NULL, p_tmpRendBuffer, *mcInput->base.ctx.pOutSampleRate, - getNumSubframesInBuffer( &outAudio, *mcInput->base.ctx.pOutSampleRate ), 0 ) ), - IVAS_ERR_OK ) ) -#endif #else IF( NE_32( ( error = ivas_rend_crendProcess( mcInput->crendWrapper, mcInput->base.inConfig, outConfig, NULL, NULL, NULL, NULL, p_tmpRendBuffer, *mcInput->base.ctx.pOutSampleRate, getNumSubframesInBuffer( &outAudio, *mcInput->base.ctx.pOutSampleRate ) ) ), @@ -7096,13 +7077,7 @@ static ivas_error renderMcCustomLsToBinauralRoom( /* call CREND */ #ifdef SPLIT_REND_WITH_HEAD_ROT -#ifdef FIX_911_REMOVE_CREND_DUPLICATION IF( NE_32( ( error = ivas_rend_crendProcessSubframe( mcInput->crendWrapper, IVAS_AUDIO_CONFIG_7_1_4, outConfig, NULL, NULL, NULL, NULL, NULL, p_tmpCrendBuffer, p_tmpCrendBuffer, mcInput->base.inputBuffer.config.numSamplesPerChannel, *mcInput->base.ctx.pOutSampleRate, 0 ) ), IVAS_ERR_OK ) ) -#else - IF( NE_32( ( error = ivas_rend_crendProcess( mcInput->crendWrapper, IVAS_AUDIO_CONFIG_7_1_4, outConfig, NULL, NULL, NULL, NULL, - p_tmpCrendBuffer, *mcInput->base.ctx.pOutSampleRate, getNumSubframesInBuffer( &outAudio, *mcInput->base.ctx.pOutSampleRate ), 0 ) ), - IVAS_ERR_OK ) ) -#endif #else IF( NE_32( ( error = ivas_rend_crendProcess( mcInput->crendWrapper, IVAS_AUDIO_CONFIG_7_1_4, outConfig, NULL, NULL, NULL, NULL, p_tmpCrendBuffer, *mcInput->base.ctx.pOutSampleRate, getNumSubframesInBuffer( &outAudio, *mcInput->base.ctx.pOutSampleRate ) ) ), @@ -7358,13 +7333,7 @@ static ivas_error renderMcToSplitBinaural( copyBufferTo2dArray_fx( tmpRotBuffer, tmpRendBuffer ); /* call CREND (rotation already performed) */ -#ifdef FIX_911_REMOVE_CREND_DUPLICATION IF( NE_32( ( error = ivas_rend_crendProcessSubframe( mcInput->crendWrapper, mcInput->base.inConfig, outConfig, NULL, NULL, NULL, NULL, NULL, p_tmpRendBuffer, p_tmpRendBuffer, mcInput->base.inputBuffer.config.numSamplesPerChannel, *mcInput->base.ctx.pOutSampleRate, pos_idx ) ), IVAS_ERR_OK ) ) -#else - IF( NE_32( ( error = ivas_rend_crendProcess( mcInput->crendWrapper, mcInput->base.inConfig, outConfig, NULL, NULL, NULL, NULL, - p_tmpRendBuffer, *mcInput->base.ctx.pOutSampleRate, getNumSubframesInBuffer( &tmpRotBuffer, *mcInput->base.ctx.pOutSampleRate ), pos_idx ) ), - IVAS_ERR_OK ) ) -#endif { return error; } @@ -7638,13 +7607,7 @@ static ivas_error renderSbaToMultiBinaural( assert( sbaInput->crendWrapper->hCrend[0]->hReverb == NULL ); /* call CREND */ -#ifdef FIX_911_REMOVE_CREND_DUPLICATION IF( NE_32( ( error = ivas_rend_crendProcessSubframe( sbaInput->crendWrapper, sbaInput->base.inConfig, outConfig, NULL, NULL, NULL, NULL, NULL, p_tmpCrendBuffer, p_tmpCrendBuffer, sbaInput->base.inputBuffer.config.numSamplesPerChannel, *sbaInput->base.ctx.pOutSampleRate, pos_idx ) ), IVAS_ERR_OK ) ) -#else - IF( NE_32( ( error = ivas_rend_crendProcess( sbaInput->crendWrapper, sbaInput->base.inConfig, outConfig, NULL, NULL, NULL, NULL, p_tmpCrendBuffer, *sbaInput->base.ctx.pOutSampleRate, - getNumSubframesInBuffer( &tmpRotBuffer, *sbaInput->base.ctx.pOutSampleRate ), pos_idx ) ), - IVAS_ERR_OK ) ) -#endif { return error; } @@ -7834,13 +7797,7 @@ static ivas_error renderSbaToBinaural( /* call CREND */ #ifdef SPLIT_REND_WITH_HEAD_ROT -#ifdef FIX_911_REMOVE_CREND_DUPLICATION IF( NE_32( ( error = ivas_rend_crendProcessSubframe( sbaInput->crendWrapper, sbaInput->base.inConfig, outConfig, NULL, NULL, NULL, NULL, NULL, output_fx, output_fx, sbaInput->base.inputBuffer.config.numSamplesPerChannel, *sbaInput->base.ctx.pOutSampleRate, 0 ) ), IVAS_ERR_OK ) ) -#else - IF( NE_32( ( error = ivas_rend_crendProcess( sbaInput->crendWrapper, sbaInput->base.inConfig, outConfig, NULL, NULL, NULL, NULL, output_fx, *sbaInput->base.ctx.pOutSampleRate, - getNumSubframesInBuffer( &outAudio, *sbaInput->base.ctx.pOutSampleRate ), 0 ) ), - IVAS_ERR_OK ) ) -#endif #else IF( NE_32( ( error = ivas_rend_crendProcess( sbaInput->crendWrapper, sbaInput->base.inConfig, outConfig, NULL, NULL, NULL, NULL, output_fx, *sbaInput->base.ctx.pOutSampleRate, getNumSubframesInBuffer( &outAudio, *sbaInput->base.ctx.pOutSampleRate ) ) ), @@ -7971,14 +7928,7 @@ static ivas_error renderSbaToBinauralRoom( /* call CREND */ #ifdef SPLIT_REND_WITH_HEAD_ROT -#ifdef FIX_911_REMOVE_CREND_DUPLICATION IF( NE_32( ( error = ivas_rend_crendProcessSubframe( sbaInput->crendWrapper, IVAS_AUDIO_CONFIG_7_1_4, outConfig, NULL, NULL, NULL, NULL, NULL, p_tmpCrendBuffer, p_tmpCrendBuffer, sbaInput->base.inputBuffer.config.numSamplesPerChannel, *sbaInput->base.ctx.pOutSampleRate, 0 ) ), IVAS_ERR_OK ) ) -#else - IF( NE_32( ( error = ivas_rend_crendProcess( sbaInput->crendWrapper, IVAS_AUDIO_CONFIG_7_1_4, outConfig, - NULL, NULL, NULL, NULL, p_tmpCrendBuffer, *sbaInput->base.ctx.pOutSampleRate, - getNumSubframesInBuffer( &outAudio, *sbaInput->base.ctx.pOutSampleRate ), 0 ) ), - IVAS_ERR_OK ) ) -#endif #else IF( NE_32( ( error = ivas_rend_crendProcess( sbaInput->crendWrapper, IVAS_AUDIO_CONFIG_7_1_4, outConfig, NULL, NULL, NULL, NULL, p_tmpCrendBuffer, *sbaInput->base.ctx.pOutSampleRate, -- GitLab From d629db7a76d458a592a98a1f27e566aa667656cd Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Wed, 16 Apr 2025 09:06:06 +0200 Subject: [PATCH 2/3] Accept FIX_938_GCC_12_WARNINGS --- lib_com/options.h | 1 - lib_enc/enc_higher_acelp_fx.c | 6 ------ 2 files changed, 7 deletions(-) diff --git a/lib_com/options.h b/lib_com/options.h index 05c7634d0..c936cf602 100755 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -94,7 +94,6 @@ #endif #define NONBE_FIX_1058_DECODER_ERROR_WITH_REVERB_ROOM /* FhG: issue 1058: do not initialize EFAP when IntSetup is HOA3 */ #define NONBE_FIX_943_RECONFIG_IGF_AFTER_SETTING_BW /* FhG: issue 943: fix crash in BW switchin from WB in MDCT-Stereo core encoder */ -#define FIX_938_GCC_12_WARNINGS /* VA: issue #938: remove set_f(.,.,0) call in which length is always 0 to remove GCC 12.0 warning */ #define NONBE_FIX_944_FEC_OMASA_1SEP_OBJ_MASA /* Nokia: issue 944: fix FEC error in OMASA */ /* #################### End BASOP porting switches ############################ */ diff --git a/lib_enc/enc_higher_acelp_fx.c b/lib_enc/enc_higher_acelp_fx.c index 6b2457d95..5edc6229f 100644 --- a/lib_enc/enc_higher_acelp_fx.c +++ b/lib_enc/enc_higher_acelp_fx.c @@ -290,9 +290,6 @@ void transf_cdbk_enc_fx( x_tran[i] = shl_o( x_norm[i], Q_AVQ_OUT_DEC, &Overflow ); move16(); } -#ifndef FIX_938_GCC_12_WARNINGS - set16_fx( x_tran + Nsv * WIDTH_BAND, 0, sub( L_SUBFR, i_mult2( WIDTH_BAND, Nsv ) ) ); -#endif test(); test(); @@ -645,9 +642,6 @@ void transf_cdbk_enc_ivas_fx( x_tran[i] = shl_o( x_norm[i], Q_AVQ_OUT_DEC, &Overflow ); move16(); } -#ifndef FIX_938_GCC_12_WARNINGS - set16_fx( x_tran + Nsv * WIDTH_BAND, 0, sub( L_SUBFR, i_mult2( WIDTH_BAND, Nsv ) ) ); -#endif test(); test(); -- GitLab From 83927371e68d2cf92b1c3b93e853df653a4a7477 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Wed, 16 Apr 2025 09:06:19 +0200 Subject: [PATCH 3/3] Accept NONBE_FIX_943_RECONFIG_IGF_AFTER_SETTING_BW --- lib_com/options.h | 1 - lib_enc/ivas_cpe_enc_fx.c | 23 ----------------------- 2 files changed, 24 deletions(-) diff --git a/lib_com/options.h b/lib_com/options.h index c936cf602..e071c4da6 100755 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -93,7 +93,6 @@ #define FIX_1372_ISAR_POST_REND #endif #define NONBE_FIX_1058_DECODER_ERROR_WITH_REVERB_ROOM /* FhG: issue 1058: do not initialize EFAP when IntSetup is HOA3 */ -#define NONBE_FIX_943_RECONFIG_IGF_AFTER_SETTING_BW /* FhG: issue 943: fix crash in BW switchin from WB in MDCT-Stereo core encoder */ #define NONBE_FIX_944_FEC_OMASA_1SEP_OBJ_MASA /* Nokia: issue 944: fix FEC error in OMASA */ /* #################### End BASOP porting switches ############################ */ diff --git a/lib_enc/ivas_cpe_enc_fx.c b/lib_enc/ivas_cpe_enc_fx.c index ca33dea1f..826c23fdd 100644 --- a/lib_enc/ivas_cpe_enc_fx.c +++ b/lib_enc/ivas_cpe_enc_fx.c @@ -976,27 +976,6 @@ ivas_error ivas_cpe_enc_fx( /*----------------------------------------------------------------* * Core codec configuration *----------------------------------------------------------------*/ -#ifndef NONBE_FIX_943_RECONFIG_IGF_AFTER_SETTING_BW - /* IGF reconfiguration */ - FOR( n = 0; n < n_CoreChannels; n++ ) - { - test(); - test(); - test(); - test(); - test(); - test(); - IF( ( NE_32( hCPE->last_element_brate, hCPE->element_brate ) || NE_16( hCPE->element_mode, hCPE->last_element_mode ) || ( EQ_16( hCPE->element_mode, IVAS_CPE_TD ) && NE_16( sts[0]->bits_frame_nominal, last_bits_frame_nominal ) ) || NE_16( sts[n]->last_bwidth, sts[n]->bwidth ) ) && ( n == 0 || EQ_16( hCPE->element_mode, IVAS_CPE_MDCT ) ) ) - { - Word16 igf; - igf = getIgfPresent_fx( sts[n]->element_mode, L_mult0( sts[n]->bits_frame_nominal, FRAMES_PER_SEC ), sts[n]->max_bwidth, sts[n]->rf_mode ); /* Q0 */ - IF( ( error = IGF_Reconfig_fx( &sts[n]->hIGFEnc, igf, 0, L_mult0( sts[n]->bits_frame_nominal, FRAMES_PER_SEC ), sts[n]->max_bwidth, sts[n]->element_mode, sts[n]->rf_mode ) ) != IVAS_ERR_OK ) - { - return error; - } - } - } -#endif test(); IF( EQ_16( hCPE->element_mode, IVAS_CPE_MDCT ) && st_ivas->hMCT == NULL ) @@ -1028,7 +1007,6 @@ ivas_error ivas_cpe_enc_fx( } } -#ifdef NONBE_FIX_943_RECONFIG_IGF_AFTER_SETTING_BW /* IGF reconfiguration */ FOR( n = 0; n < n_CoreChannels; n++ ) { @@ -1048,7 +1026,6 @@ ivas_error ivas_cpe_enc_fx( } } } -#endif /* set ACELP@12k8 / ACELP@16k flag for flexible ACELP core */ FOR( n = 0; n < n_CoreChannels; n++ ) -- GitLab