Loading apps/decoder.c +5 −5 Original line number Diff line number Diff line Loading @@ -425,16 +425,16 @@ int main( IVAS_RENDER_CONFIG_DATA renderConfig; /* sanity check */ #ifndef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER if ( arg.outputFormat != IVAS_DEC_OUTPUT_BINAURAL_ROOM ) #ifdef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER if ( arg.outputFormat != IVAS_DEC_OUTPUT_BINAURAL_ROOM && arg.outputFormat != IVAS_DEC_OUTPUT_MONO ) { fprintf( stderr, "\nExternal Renderer Config is supported only when BINAURAL_ROOM is used as output. Exiting. \n" ); fprintf( stderr, "\nExternal Renderer Config is supported only when BINAURAL_ROOM or MONO is used as output. Exiting. \n" ); goto cleanup; } #else if ( arg.outputFormat != IVAS_DEC_OUTPUT_BINAURAL_ROOM && arg.outputFormat != IVAS_DEC_OUTPUT_MONO ) if ( arg.outputFormat != IVAS_DEC_OUTPUT_BINAURAL_ROOM ) { fprintf( stderr, "\nExternal Renderer Config is supported only when BINAURAL_ROOM or MONO is used as output. Exiting. \n" ); fprintf( stderr, "\nExternal Renderer Config is supported only when BINAURAL_ROOM is used as output. Exiting. \n" ); goto cleanup; } #endif Loading lib_com/ivas_prot.h +4 −4 Original line number Diff line number Diff line Loading @@ -4768,14 +4768,14 @@ void computeReferencePower_enc( ); #ifndef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER #ifdef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER ivas_error ivas_mono_dmx_renderer_open( Decoder_Struct *st_ivas /* i/o: IVAS decoder structure */ Decoder_Struct *st_ivas, /* i/o: IVAS decoder structure */ const int16_t do_proximity_mixing /* i : flag to enable proximity-based mixing */ ); #else /* I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER */ ivas_error ivas_mono_dmx_renderer_open( Decoder_Struct *st_ivas, /* i/o: IVAS decoder structure */ const int16_t do_proximity_mixing /* i : flag to enable proximity-based mixing */ Decoder_Struct *st_ivas /* i/o: IVAS decoder structure */ ); #endif /* I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER */ Loading lib_dec/ivas_init_dec.c +6 −6 Original line number Diff line number Diff line Loading @@ -584,11 +584,11 @@ ivas_error ivas_init_decoder_front( * Allocate and initialize Binaural Renderer configuration handle *--------------------------------------------------------------------*/ #ifndef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER if ( st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL || st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL_ROOM ) #else #ifdef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER if ( st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL || st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL_ROOM || st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_MONO ) #else if ( st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL || st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL_ROOM ) #endif { if ( ( error = ivas_render_config_open( &( st_ivas->hRenderConfig ) ) ) != IVAS_ERR_OK ) Loading Loading @@ -1249,10 +1249,10 @@ ivas_error ivas_init_decoder( } else if ( st_ivas->renderer_type == RENDERER_MONO_DOWNMIX ) { #ifndef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER if ( ( error = ivas_mono_dmx_renderer_open( st_ivas ) ) != IVAS_ERR_OK ) #else #ifdef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER if ( ( error = ivas_mono_dmx_renderer_open( st_ivas, st_ivas->hRenderConfig->roomAcoustics.do_proximity_mixing ) ) != IVAS_ERR_OK ) #else if ( ( error = ivas_mono_dmx_renderer_open( st_ivas ) ) != IVAS_ERR_OK ) #endif { return error; Loading lib_dec/ivas_mono_dmx_renderer.c +15 −14 Original line number Diff line number Diff line Loading @@ -61,14 +61,14 @@ const int16_t userLoc_prox_mix_test_const[MONO_DOWNMIX_RENDERER_MAX_INPUT_CHANS] * Open decoder downmix handle *-------------------------------------------------------------------------*/ #ifndef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER #ifdef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER ivas_error ivas_mono_dmx_renderer_open( Decoder_Struct *st_ivas /* i/o: IVAS decoder structure */ Decoder_Struct *st_ivas, /* i/o: IVAS decoder structure */ const int16_t do_proximity_mixing /* i : flag to enable proximity-based mixing */ ) #else /* I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER */ ivas_error ivas_mono_dmx_renderer_open( Decoder_Struct *st_ivas, /* i/o: IVAS decoder structure */ const int16_t do_proximity_mixing /* i : flag to enable proximity-based mixing */ Decoder_Struct *st_ivas /* i/o: IVAS decoder structure */ ) #endif /* I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER */ { Loading Loading @@ -176,16 +176,8 @@ void ivas_mono_downmix_render_passive( /* compute the input energy, proto energy after smoothing */ hDownmix->inputEnergy[0] *= DOWNMIX_ALPHA; hDownmix->protoEnergy[0] *= DOWNMIX_ALPHA; #ifndef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER for ( i = 0; i < output_frame; i++ ) { hDownmix->protoEnergy[0] += proto_signal[i] * proto_signal[i]; for ( j = 0; j < numInputChannels; j++ ) { hDownmix->inputEnergy[0] += ( output_f[j][i] * output_f[j][i] ); } } #else /* I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER */ #ifdef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER if ( hDownmix->do_proximity_mixing ) { for ( i = 0; i < output_frame; i++ ) Loading Loading @@ -215,6 +207,15 @@ void ivas_mono_downmix_render_passive( } } } #else /* I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER */ for ( i = 0; i < output_frame; i++ ) { hDownmix->protoEnergy[0] += proto_signal[i] * proto_signal[i]; for ( j = 0; j < numInputChannels; j++ ) { hDownmix->inputEnergy[0] += ( output_f[j][i] * output_f[j][i] ); } } #endif /* I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER */ /* compute the eq factor */ Loading Loading
apps/decoder.c +5 −5 Original line number Diff line number Diff line Loading @@ -425,16 +425,16 @@ int main( IVAS_RENDER_CONFIG_DATA renderConfig; /* sanity check */ #ifndef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER if ( arg.outputFormat != IVAS_DEC_OUTPUT_BINAURAL_ROOM ) #ifdef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER if ( arg.outputFormat != IVAS_DEC_OUTPUT_BINAURAL_ROOM && arg.outputFormat != IVAS_DEC_OUTPUT_MONO ) { fprintf( stderr, "\nExternal Renderer Config is supported only when BINAURAL_ROOM is used as output. Exiting. \n" ); fprintf( stderr, "\nExternal Renderer Config is supported only when BINAURAL_ROOM or MONO is used as output. Exiting. \n" ); goto cleanup; } #else if ( arg.outputFormat != IVAS_DEC_OUTPUT_BINAURAL_ROOM && arg.outputFormat != IVAS_DEC_OUTPUT_MONO ) if ( arg.outputFormat != IVAS_DEC_OUTPUT_BINAURAL_ROOM ) { fprintf( stderr, "\nExternal Renderer Config is supported only when BINAURAL_ROOM or MONO is used as output. Exiting. \n" ); fprintf( stderr, "\nExternal Renderer Config is supported only when BINAURAL_ROOM is used as output. Exiting. \n" ); goto cleanup; } #endif Loading
lib_com/ivas_prot.h +4 −4 Original line number Diff line number Diff line Loading @@ -4768,14 +4768,14 @@ void computeReferencePower_enc( ); #ifndef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER #ifdef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER ivas_error ivas_mono_dmx_renderer_open( Decoder_Struct *st_ivas /* i/o: IVAS decoder structure */ Decoder_Struct *st_ivas, /* i/o: IVAS decoder structure */ const int16_t do_proximity_mixing /* i : flag to enable proximity-based mixing */ ); #else /* I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER */ ivas_error ivas_mono_dmx_renderer_open( Decoder_Struct *st_ivas, /* i/o: IVAS decoder structure */ const int16_t do_proximity_mixing /* i : flag to enable proximity-based mixing */ Decoder_Struct *st_ivas /* i/o: IVAS decoder structure */ ); #endif /* I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER */ Loading
lib_dec/ivas_init_dec.c +6 −6 Original line number Diff line number Diff line Loading @@ -584,11 +584,11 @@ ivas_error ivas_init_decoder_front( * Allocate and initialize Binaural Renderer configuration handle *--------------------------------------------------------------------*/ #ifndef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER if ( st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL || st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL_ROOM ) #else #ifdef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER if ( st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL || st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL_ROOM || st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_MONO ) #else if ( st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL || st_ivas->hDecoderConfig->output_config == AUDIO_CONFIG_BINAURAL_ROOM ) #endif { if ( ( error = ivas_render_config_open( &( st_ivas->hRenderConfig ) ) ) != IVAS_ERR_OK ) Loading Loading @@ -1249,10 +1249,10 @@ ivas_error ivas_init_decoder( } else if ( st_ivas->renderer_type == RENDERER_MONO_DOWNMIX ) { #ifndef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER if ( ( error = ivas_mono_dmx_renderer_open( st_ivas ) ) != IVAS_ERR_OK ) #else #ifdef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER if ( ( error = ivas_mono_dmx_renderer_open( st_ivas, st_ivas->hRenderConfig->roomAcoustics.do_proximity_mixing ) ) != IVAS_ERR_OK ) #else if ( ( error = ivas_mono_dmx_renderer_open( st_ivas ) ) != IVAS_ERR_OK ) #endif { return error; Loading
lib_dec/ivas_mono_dmx_renderer.c +15 −14 Original line number Diff line number Diff line Loading @@ -61,14 +61,14 @@ const int16_t userLoc_prox_mix_test_const[MONO_DOWNMIX_RENDERER_MAX_INPUT_CHANS] * Open decoder downmix handle *-------------------------------------------------------------------------*/ #ifndef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER #ifdef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER ivas_error ivas_mono_dmx_renderer_open( Decoder_Struct *st_ivas /* i/o: IVAS decoder structure */ Decoder_Struct *st_ivas, /* i/o: IVAS decoder structure */ const int16_t do_proximity_mixing /* i : flag to enable proximity-based mixing */ ) #else /* I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER */ ivas_error ivas_mono_dmx_renderer_open( Decoder_Struct *st_ivas, /* i/o: IVAS decoder structure */ const int16_t do_proximity_mixing /* i : flag to enable proximity-based mixing */ Decoder_Struct *st_ivas /* i/o: IVAS decoder structure */ ) #endif /* I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER */ { Loading Loading @@ -176,16 +176,8 @@ void ivas_mono_downmix_render_passive( /* compute the input energy, proto energy after smoothing */ hDownmix->inputEnergy[0] *= DOWNMIX_ALPHA; hDownmix->protoEnergy[0] *= DOWNMIX_ALPHA; #ifndef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER for ( i = 0; i < output_frame; i++ ) { hDownmix->protoEnergy[0] += proto_signal[i] * proto_signal[i]; for ( j = 0; j < numInputChannels; j++ ) { hDownmix->inputEnergy[0] += ( output_f[j][i] * output_f[j][i] ); } } #else /* I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER */ #ifdef I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER if ( hDownmix->do_proximity_mixing ) { for ( i = 0; i < output_frame; i++ ) Loading Loading @@ -215,6 +207,15 @@ void ivas_mono_downmix_render_passive( } } } #else /* I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER */ for ( i = 0; i < output_frame; i++ ) { hDownmix->protoEnergy[0] += proto_signal[i] * proto_signal[i]; for ( j = 0; j < numInputChannels; j++ ) { hDownmix->inputEnergy[0] += ( output_f[j][i] * output_f[j][i] ); } } #endif /* I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER */ /* compute the eq factor */ Loading