Loading lib_com/options.h +1 −0 Original line number Diff line number Diff line Loading @@ -134,6 +134,7 @@ #define FIX_1849_OBJ_EDITING_API #define NONBE_FIX_1262_OSBA_STEREO #define NONBE_1339_FIXOSBA_EXT_LOUDNESS /* FhG: issue 1339: apply scaling with EXT output in OSBA high-BR mode */ #define NONBE_1352_HARMONIZE_OSBA_LOUDNESS /* FhG: do not scale OSBA inputs by 0.5 any more */ /* #################### End BASOP porting switches ############################ */ Loading lib_dec/ivas_jbm_dec_fx.c +14 −1 Original line number Diff line number Diff line Loading @@ -2262,7 +2262,7 @@ ivas_error ivas_jbm_dec_render_fx( { Copy32( st_ivas->hTcBuffer->tc_fx[n] + st_ivas->hTcBuffer->n_samples_rendered, p_output_fx[n], *nSamplesRendered ); } #ifdef NONBE_1339_FIXOSBA_EXT_LOUDNESS #if defined( NONBE_1339_FIXOSBA_EXT_LOUDNESS ) && !defined( NONBE_1352_HARMONIZE_OSBA_LOUDNESS ) for ( n = 0; n < st_ivas->hDecoderConfig->nchan_out; n++ ) { scale_sig32( p_output_fx[n], *nSamplesRendered, -1 ); Loading @@ -2280,6 +2280,12 @@ ivas_error ivas_jbm_dec_render_fx( ELSE IF( EQ_32( st_ivas->renderer_type, RENDERER_BINAURAL_PARAMETRIC ) || EQ_32( st_ivas->renderer_type, RENDERER_BINAURAL_PARAMETRIC_ROOM ) ) { ivas_dirac_dec_binaural_render_fx( st_ivas, nSamplesAskedLocal, nSamplesRendered, nSamplesAvailableNext, nchan_remapped, p_output_fx ); #ifdef NONBE_1352_HARMONIZE_OSBA_LOUDNESS FOR ( n = 0; n < st_ivas->hDecoderConfig->nchan_out; n++ ) { scale_sig_32( p_output_fx[n], *nSamplesRendered, 1 ); } #endif } ELSE { Loading @@ -2299,6 +2305,13 @@ ivas_error ivas_jbm_dec_render_fx( set32_fx( p_output_fx[n], 0, *nSamplesRendered ); } } #ifdef NONBE_1352_HARMONIZE_OSBA_LOUDNESS FOR ( n = 0; n < st_ivas->hDecoderConfig->nchan_out; n++ ) { scale_sig32( p_output_fx[n], *nSamplesRendered, 1 ); } #endif } } ELSE IF( EQ_32( st_ivas->ivas_format, MC_FORMAT ) ) Loading lib_dec/ivas_osba_dec_fx.c +17 −5 Original line number Diff line number Diff line Loading @@ -203,13 +203,21 @@ ivas_error ivas_osba_dirac_td_binaural_jbm_fx( FOR( b = 0; b < num_cldfb_bands; b++ ) { st_ivas->hSplitBinRend->hMultiBinCldfbData->Cldfb_RealBuffer_Binaural_fx[n][slot_idx_start + slot_idx][b] = #ifdef NONBE_1352_HARMONIZE_OSBA_LOUDNESS L_add( st_ivas->hSplitBinRend->hMultiBinCldfbData->Cldfb_RealBuffer_Binaural_fx[n][add( slot_idx_start, slot_idx )][b], Cldfb_RealBuffer[b] ); #else L_add( L_shr( st_ivas->hSplitBinRend->hMultiBinCldfbData->Cldfb_RealBuffer_Binaural_fx[n][add( slot_idx_start, slot_idx )][b], 1 ), L_shr( Cldfb_RealBuffer[b], 1 ) ); #endif move32(); st_ivas->hSplitBinRend->hMultiBinCldfbData->Cldfb_ImagBuffer_Binaural_fx[n][slot_idx_start + slot_idx][b] = #ifdef NONBE_1352_HARMONIZE_OSBA_LOUDNESS L_add( st_ivas->hSplitBinRend->hMultiBinCldfbData->Cldfb_ImagBuffer_Binaural_fx[n][add( slot_idx_start, slot_idx )][b], Cldfb_ImagBuffer[b] ); #else L_add( L_shr( st_ivas->hSplitBinRend->hMultiBinCldfbData->Cldfb_ImagBuffer_Binaural_fx[n][add( slot_idx_start, slot_idx )][b], 1 ), L_shr( Cldfb_ImagBuffer[b], 1 ) ); #endif move32(); } } Loading @@ -227,7 +235,11 @@ ivas_error ivas_osba_dirac_td_binaural_jbm_fx( Word16 i; FOR( i = 0; i < nSamplesAsked; i++ ) { #ifdef NONBE_1352_HARMONIZE_OSBA_LOUDNESS output_fx[n][i] = L_add( output_fx[channel_offset + n][i], p_sepobj_fx[n][i] ); #else output_fx[n][i] = L_add( L_shr( output_fx[channel_offset + n][i], 1 ), L_shr( p_sepobj_fx[n][i], 1 ) ); #endif move32(); } } Loading Loading @@ -381,7 +393,7 @@ void ivas_osba_stereo_add_channels_fx( #ifdef NONBE_FIX_1262_OSBA_STEREO FOR( n = 0; n < nchan_out; n++ ) { // Word16 i; iWord16 i; //FOR( i = 0; i < n_samples_to_render; i++ ) //{ // output_fx[n][i] = L_shr( output_fx[n][i], 1 ); Loading Loading
lib_com/options.h +1 −0 Original line number Diff line number Diff line Loading @@ -134,6 +134,7 @@ #define FIX_1849_OBJ_EDITING_API #define NONBE_FIX_1262_OSBA_STEREO #define NONBE_1339_FIXOSBA_EXT_LOUDNESS /* FhG: issue 1339: apply scaling with EXT output in OSBA high-BR mode */ #define NONBE_1352_HARMONIZE_OSBA_LOUDNESS /* FhG: do not scale OSBA inputs by 0.5 any more */ /* #################### End BASOP porting switches ############################ */ Loading
lib_dec/ivas_jbm_dec_fx.c +14 −1 Original line number Diff line number Diff line Loading @@ -2262,7 +2262,7 @@ ivas_error ivas_jbm_dec_render_fx( { Copy32( st_ivas->hTcBuffer->tc_fx[n] + st_ivas->hTcBuffer->n_samples_rendered, p_output_fx[n], *nSamplesRendered ); } #ifdef NONBE_1339_FIXOSBA_EXT_LOUDNESS #if defined( NONBE_1339_FIXOSBA_EXT_LOUDNESS ) && !defined( NONBE_1352_HARMONIZE_OSBA_LOUDNESS ) for ( n = 0; n < st_ivas->hDecoderConfig->nchan_out; n++ ) { scale_sig32( p_output_fx[n], *nSamplesRendered, -1 ); Loading @@ -2280,6 +2280,12 @@ ivas_error ivas_jbm_dec_render_fx( ELSE IF( EQ_32( st_ivas->renderer_type, RENDERER_BINAURAL_PARAMETRIC ) || EQ_32( st_ivas->renderer_type, RENDERER_BINAURAL_PARAMETRIC_ROOM ) ) { ivas_dirac_dec_binaural_render_fx( st_ivas, nSamplesAskedLocal, nSamplesRendered, nSamplesAvailableNext, nchan_remapped, p_output_fx ); #ifdef NONBE_1352_HARMONIZE_OSBA_LOUDNESS FOR ( n = 0; n < st_ivas->hDecoderConfig->nchan_out; n++ ) { scale_sig_32( p_output_fx[n], *nSamplesRendered, 1 ); } #endif } ELSE { Loading @@ -2299,6 +2305,13 @@ ivas_error ivas_jbm_dec_render_fx( set32_fx( p_output_fx[n], 0, *nSamplesRendered ); } } #ifdef NONBE_1352_HARMONIZE_OSBA_LOUDNESS FOR ( n = 0; n < st_ivas->hDecoderConfig->nchan_out; n++ ) { scale_sig32( p_output_fx[n], *nSamplesRendered, 1 ); } #endif } } ELSE IF( EQ_32( st_ivas->ivas_format, MC_FORMAT ) ) Loading
lib_dec/ivas_osba_dec_fx.c +17 −5 Original line number Diff line number Diff line Loading @@ -203,13 +203,21 @@ ivas_error ivas_osba_dirac_td_binaural_jbm_fx( FOR( b = 0; b < num_cldfb_bands; b++ ) { st_ivas->hSplitBinRend->hMultiBinCldfbData->Cldfb_RealBuffer_Binaural_fx[n][slot_idx_start + slot_idx][b] = #ifdef NONBE_1352_HARMONIZE_OSBA_LOUDNESS L_add( st_ivas->hSplitBinRend->hMultiBinCldfbData->Cldfb_RealBuffer_Binaural_fx[n][add( slot_idx_start, slot_idx )][b], Cldfb_RealBuffer[b] ); #else L_add( L_shr( st_ivas->hSplitBinRend->hMultiBinCldfbData->Cldfb_RealBuffer_Binaural_fx[n][add( slot_idx_start, slot_idx )][b], 1 ), L_shr( Cldfb_RealBuffer[b], 1 ) ); #endif move32(); st_ivas->hSplitBinRend->hMultiBinCldfbData->Cldfb_ImagBuffer_Binaural_fx[n][slot_idx_start + slot_idx][b] = #ifdef NONBE_1352_HARMONIZE_OSBA_LOUDNESS L_add( st_ivas->hSplitBinRend->hMultiBinCldfbData->Cldfb_ImagBuffer_Binaural_fx[n][add( slot_idx_start, slot_idx )][b], Cldfb_ImagBuffer[b] ); #else L_add( L_shr( st_ivas->hSplitBinRend->hMultiBinCldfbData->Cldfb_ImagBuffer_Binaural_fx[n][add( slot_idx_start, slot_idx )][b], 1 ), L_shr( Cldfb_ImagBuffer[b], 1 ) ); #endif move32(); } } Loading @@ -227,7 +235,11 @@ ivas_error ivas_osba_dirac_td_binaural_jbm_fx( Word16 i; FOR( i = 0; i < nSamplesAsked; i++ ) { #ifdef NONBE_1352_HARMONIZE_OSBA_LOUDNESS output_fx[n][i] = L_add( output_fx[channel_offset + n][i], p_sepobj_fx[n][i] ); #else output_fx[n][i] = L_add( L_shr( output_fx[channel_offset + n][i], 1 ), L_shr( p_sepobj_fx[n][i], 1 ) ); #endif move32(); } } Loading Loading @@ -381,7 +393,7 @@ void ivas_osba_stereo_add_channels_fx( #ifdef NONBE_FIX_1262_OSBA_STEREO FOR( n = 0; n < nchan_out; n++ ) { // Word16 i; iWord16 i; //FOR( i = 0; i < n_samples_to_render; i++ ) //{ // output_fx[n][i] = L_shr( output_fx[n][i], 1 ); Loading