Loading lib_dec/ivas_init_dec.c +0 −1 Original line number Diff line number Diff line Loading @@ -1647,7 +1647,6 @@ ivas_error ivas_init_decoder( #ifndef FIX_1419_MONO_STEREO_UMX /* already set now by renderer_select() */ st_ivas->intern_config = IVAS_AUDIO_CONFIG_STEREO; #endif st_ivas->nSCE = 0; st_ivas->nCPE = 1; /* in stereo, there is always only one CPE */ cpe_id = 0; Loading lib_dec/ivas_jbm_dec.c +17 −19 Original line number Diff line number Diff line Loading @@ -929,6 +929,10 @@ ivas_error ivas_jbm_dec_render( * Rendering *----------------------------------------------------------------*/ #ifdef FIX_1419_MONO_STEREO_UMX *nSamplesRendered = min( st_ivas->hTcBuffer->n_samples_available, nSamplesAskedLocal ); #endif if ( st_ivas->ivas_format == UNDEFINED_FORMAT ) { assert( 0 ); Loading @@ -943,10 +947,6 @@ ivas_error ivas_jbm_dec_render( else if ( st_ivas->ivas_format == STEREO_FORMAT ) #endif { #ifdef FIX_1419_MONO_STEREO_UMX *nSamplesRendered = min( st_ivas->hTcBuffer->n_samples_available, nSamplesAskedLocal ); #endif /* Rendering */ if ( st_ivas->renderer_type == RENDERER_MC ) { Loading @@ -957,13 +957,6 @@ ivas_error ivas_jbm_dec_render( } #ifdef FIX_1419_MONO_STEREO_UMX else if ( st_ivas->renderer_type == RENDERER_SBA_LINEAR_ENC ) { if ( st_ivas->ivas_format == MONO_FORMAT ) { /* routed to W */ ivas_jbm_dec_tc_buffer_playout( st_ivas, nSamplesAskedLocal, nSamplesRendered, p_output ); } else if ( st_ivas->ivas_format == STEREO_FORMAT ) { for ( n = 0; n < *nSamplesRendered; n++ ) { Loading @@ -973,7 +966,6 @@ ivas_error ivas_jbm_dec_render( p_output[1][n] = 0.5f * ( tmp - p_output[1][n] ); /* Y = 0.5 * ( L - R ) */ } } } #endif /* FIX_1419_MONO_STEREO_UMX */ } else if ( st_ivas->ivas_format == ISM_FORMAT ) Loading @@ -998,8 +990,9 @@ ivas_error ivas_jbm_dec_render( } else /* ISM_MODE_DISC */ { #ifndef FIX_1419_MONO_STEREO_UMX *nSamplesRendered = min( st_ivas->hTcBuffer->n_samples_available, nSamplesAskedLocal ); #endif /* Loudspeaker or Ambisonics rendering */ if ( st_ivas->renderer_type == RENDERER_TD_PANNING || st_ivas->renderer_type == RENDERER_BINAURAL_MIXER_CONV_ROOM ) { Loading Loading @@ -1116,8 +1109,9 @@ ivas_error ivas_jbm_dec_render( } else if ( st_ivas->renderer_type == RENDERER_OSBA_STEREO ) { #ifndef FIX_1419_MONO_STEREO_UMX *nSamplesRendered = min( st_ivas->hTcBuffer->n_samples_available, nSamplesAskedLocal ); #endif /* shift SBA channels to avoid overwrite by ISM upmix in 1 object case and non-TSM unified channel memory*/ if ( st_ivas->nchan_ism == 1 && st_ivas->hDecoderConfig->Opt_tsm == 0 ) { Loading Loading @@ -1200,7 +1194,9 @@ ivas_error ivas_jbm_dec_render( if ( st_ivas->mc_mode == MC_MODE_MCT ) { int16_t crendInPlaceRotation = FALSE; #ifndef FIX_1419_MONO_STEREO_UMX *nSamplesRendered = min( st_ivas->hTcBuffer->n_samples_available, nSamplesAskedLocal ); #endif if ( st_ivas->transport_config != st_ivas->intern_config && ( st_ivas->intern_config == IVAS_AUDIO_CONFIG_FOA || st_ivas->intern_config == IVAS_AUDIO_CONFIG_HOA2 || st_ivas->intern_config == IVAS_AUDIO_CONFIG_HOA3 ) ) { if ( ( st_ivas->hTransSetup.nchan_out_woLFE + st_ivas->hTransSetup.num_lfe ) < ( st_ivas->hIntSetup.nchan_out_woLFE + st_ivas->hIntSetup.num_lfe ) ) Loading Loading @@ -1234,7 +1230,9 @@ ivas_error ivas_jbm_dec_render( } else if ( st_ivas->renderer_type == RENDERER_MC ) { #ifndef FIX_1419_MONO_STEREO_UMX *nSamplesRendered = min( st_ivas->hTcBuffer->n_samples_available, nSamplesAskedLocal ); #endif ivas_ls_setup_conversion( st_ivas, st_ivas->nchan_transport, *nSamplesRendered, p_tc, p_output ); } else if ( st_ivas->renderer_type == RENDERER_SBA_LINEAR_ENC ) Loading lib_dec/ivas_output_config.c +21 −28 Original line number Diff line number Diff line Loading @@ -41,28 +41,6 @@ #endif #include "wmc_auto.h" #ifdef FIX_1419_MONO_STEREO_UMX static void ms_bin_upmix_renderer_select( const IVAS_FORMAT ivas_format, /* i : Decoder format */ IVAS_AUDIO_CONFIG *internal_config, /* o : Internal configuration for rendering */ RENDERER_TYPE *renderer_type /* o : Selected renderer type */ ) { *internal_config = ( ivas_format == MONO_FORMAT ) ? IVAS_AUDIO_CONFIG_MONO : IVAS_AUDIO_CONFIG_STEREO; if ( ivas_format == MONO_FORMAT ) { *renderer_type = RENDERER_NON_DIEGETIC_DOWNMIX; } else { *renderer_type = RENDERER_DISABLE; } return; } #endif /*-------------------------------------------------------------------------* * ivas_renderer_select() Loading Loading @@ -107,9 +85,16 @@ void ivas_renderer_select( #ifdef FIX_1419_MONO_STEREO_UMX if ( st_ivas->ivas_format == MONO_FORMAT || st_ivas->ivas_format == STEREO_FORMAT ) { ms_bin_upmix_renderer_select( st_ivas->ivas_format, internal_config, renderer_type ); if ( st_ivas->ivas_format == MONO_FORMAT ) { *renderer_type = RENDERER_NON_DIEGETIC_DOWNMIX; *internal_config = IVAS_AUDIO_CONFIG_MONO; } else { *renderer_type = RENDERER_DISABLE; *internal_config = IVAS_AUDIO_CONFIG_STEREO; } } else if ( st_ivas->ivas_format == ISM_FORMAT ) #else Loading Loading @@ -288,12 +273,20 @@ void ivas_renderer_select( else if ( st_ivas->ivas_format == MONO_FORMAT || st_ivas->ivas_format == STEREO_FORMAT ) { *internal_config = ( st_ivas->ivas_format == MONO_FORMAT ) ? IVAS_AUDIO_CONFIG_MONO : IVAS_AUDIO_CONFIG_STEREO; switch ( output_config ) { case IVAS_AUDIO_CONFIG_FOA: case IVAS_AUDIO_CONFIG_HOA2: case IVAS_AUDIO_CONFIG_HOA3: if ( st_ivas->ivas_format == MONO_FORMAT ) { *renderer_type = RENDERER_NON_DIEGETIC_DOWNMIX; } else { *renderer_type = RENDERER_SBA_LINEAR_ENC; } break; case IVAS_AUDIO_CONFIG_5_1: case IVAS_AUDIO_CONFIG_7_1: Loading @@ -304,14 +297,14 @@ void ivas_renderer_select( *renderer_type = RENDERER_MC; break; case IVAS_AUDIO_CONFIG_MONO: if ( *internal_config == IVAS_AUDIO_CONFIG_STEREO ) if ( st_ivas->ivas_format == STEREO_FORMAT ) { /* stereo to mono downmix */ *renderer_type = RENDERER_MC; } break; case IVAS_AUDIO_CONFIG_STEREO: if ( *internal_config == IVAS_AUDIO_CONFIG_MONO ) if ( st_ivas->ivas_format == MONO_FORMAT ) { /* mono to stereo upmix */ *renderer_type = RENDERER_NON_DIEGETIC_DOWNMIX; Loading Loading
lib_dec/ivas_init_dec.c +0 −1 Original line number Diff line number Diff line Loading @@ -1647,7 +1647,6 @@ ivas_error ivas_init_decoder( #ifndef FIX_1419_MONO_STEREO_UMX /* already set now by renderer_select() */ st_ivas->intern_config = IVAS_AUDIO_CONFIG_STEREO; #endif st_ivas->nSCE = 0; st_ivas->nCPE = 1; /* in stereo, there is always only one CPE */ cpe_id = 0; Loading
lib_dec/ivas_jbm_dec.c +17 −19 Original line number Diff line number Diff line Loading @@ -929,6 +929,10 @@ ivas_error ivas_jbm_dec_render( * Rendering *----------------------------------------------------------------*/ #ifdef FIX_1419_MONO_STEREO_UMX *nSamplesRendered = min( st_ivas->hTcBuffer->n_samples_available, nSamplesAskedLocal ); #endif if ( st_ivas->ivas_format == UNDEFINED_FORMAT ) { assert( 0 ); Loading @@ -943,10 +947,6 @@ ivas_error ivas_jbm_dec_render( else if ( st_ivas->ivas_format == STEREO_FORMAT ) #endif { #ifdef FIX_1419_MONO_STEREO_UMX *nSamplesRendered = min( st_ivas->hTcBuffer->n_samples_available, nSamplesAskedLocal ); #endif /* Rendering */ if ( st_ivas->renderer_type == RENDERER_MC ) { Loading @@ -957,13 +957,6 @@ ivas_error ivas_jbm_dec_render( } #ifdef FIX_1419_MONO_STEREO_UMX else if ( st_ivas->renderer_type == RENDERER_SBA_LINEAR_ENC ) { if ( st_ivas->ivas_format == MONO_FORMAT ) { /* routed to W */ ivas_jbm_dec_tc_buffer_playout( st_ivas, nSamplesAskedLocal, nSamplesRendered, p_output ); } else if ( st_ivas->ivas_format == STEREO_FORMAT ) { for ( n = 0; n < *nSamplesRendered; n++ ) { Loading @@ -973,7 +966,6 @@ ivas_error ivas_jbm_dec_render( p_output[1][n] = 0.5f * ( tmp - p_output[1][n] ); /* Y = 0.5 * ( L - R ) */ } } } #endif /* FIX_1419_MONO_STEREO_UMX */ } else if ( st_ivas->ivas_format == ISM_FORMAT ) Loading @@ -998,8 +990,9 @@ ivas_error ivas_jbm_dec_render( } else /* ISM_MODE_DISC */ { #ifndef FIX_1419_MONO_STEREO_UMX *nSamplesRendered = min( st_ivas->hTcBuffer->n_samples_available, nSamplesAskedLocal ); #endif /* Loudspeaker or Ambisonics rendering */ if ( st_ivas->renderer_type == RENDERER_TD_PANNING || st_ivas->renderer_type == RENDERER_BINAURAL_MIXER_CONV_ROOM ) { Loading Loading @@ -1116,8 +1109,9 @@ ivas_error ivas_jbm_dec_render( } else if ( st_ivas->renderer_type == RENDERER_OSBA_STEREO ) { #ifndef FIX_1419_MONO_STEREO_UMX *nSamplesRendered = min( st_ivas->hTcBuffer->n_samples_available, nSamplesAskedLocal ); #endif /* shift SBA channels to avoid overwrite by ISM upmix in 1 object case and non-TSM unified channel memory*/ if ( st_ivas->nchan_ism == 1 && st_ivas->hDecoderConfig->Opt_tsm == 0 ) { Loading Loading @@ -1200,7 +1194,9 @@ ivas_error ivas_jbm_dec_render( if ( st_ivas->mc_mode == MC_MODE_MCT ) { int16_t crendInPlaceRotation = FALSE; #ifndef FIX_1419_MONO_STEREO_UMX *nSamplesRendered = min( st_ivas->hTcBuffer->n_samples_available, nSamplesAskedLocal ); #endif if ( st_ivas->transport_config != st_ivas->intern_config && ( st_ivas->intern_config == IVAS_AUDIO_CONFIG_FOA || st_ivas->intern_config == IVAS_AUDIO_CONFIG_HOA2 || st_ivas->intern_config == IVAS_AUDIO_CONFIG_HOA3 ) ) { if ( ( st_ivas->hTransSetup.nchan_out_woLFE + st_ivas->hTransSetup.num_lfe ) < ( st_ivas->hIntSetup.nchan_out_woLFE + st_ivas->hIntSetup.num_lfe ) ) Loading Loading @@ -1234,7 +1230,9 @@ ivas_error ivas_jbm_dec_render( } else if ( st_ivas->renderer_type == RENDERER_MC ) { #ifndef FIX_1419_MONO_STEREO_UMX *nSamplesRendered = min( st_ivas->hTcBuffer->n_samples_available, nSamplesAskedLocal ); #endif ivas_ls_setup_conversion( st_ivas, st_ivas->nchan_transport, *nSamplesRendered, p_tc, p_output ); } else if ( st_ivas->renderer_type == RENDERER_SBA_LINEAR_ENC ) Loading
lib_dec/ivas_output_config.c +21 −28 Original line number Diff line number Diff line Loading @@ -41,28 +41,6 @@ #endif #include "wmc_auto.h" #ifdef FIX_1419_MONO_STEREO_UMX static void ms_bin_upmix_renderer_select( const IVAS_FORMAT ivas_format, /* i : Decoder format */ IVAS_AUDIO_CONFIG *internal_config, /* o : Internal configuration for rendering */ RENDERER_TYPE *renderer_type /* o : Selected renderer type */ ) { *internal_config = ( ivas_format == MONO_FORMAT ) ? IVAS_AUDIO_CONFIG_MONO : IVAS_AUDIO_CONFIG_STEREO; if ( ivas_format == MONO_FORMAT ) { *renderer_type = RENDERER_NON_DIEGETIC_DOWNMIX; } else { *renderer_type = RENDERER_DISABLE; } return; } #endif /*-------------------------------------------------------------------------* * ivas_renderer_select() Loading Loading @@ -107,9 +85,16 @@ void ivas_renderer_select( #ifdef FIX_1419_MONO_STEREO_UMX if ( st_ivas->ivas_format == MONO_FORMAT || st_ivas->ivas_format == STEREO_FORMAT ) { ms_bin_upmix_renderer_select( st_ivas->ivas_format, internal_config, renderer_type ); if ( st_ivas->ivas_format == MONO_FORMAT ) { *renderer_type = RENDERER_NON_DIEGETIC_DOWNMIX; *internal_config = IVAS_AUDIO_CONFIG_MONO; } else { *renderer_type = RENDERER_DISABLE; *internal_config = IVAS_AUDIO_CONFIG_STEREO; } } else if ( st_ivas->ivas_format == ISM_FORMAT ) #else Loading Loading @@ -288,12 +273,20 @@ void ivas_renderer_select( else if ( st_ivas->ivas_format == MONO_FORMAT || st_ivas->ivas_format == STEREO_FORMAT ) { *internal_config = ( st_ivas->ivas_format == MONO_FORMAT ) ? IVAS_AUDIO_CONFIG_MONO : IVAS_AUDIO_CONFIG_STEREO; switch ( output_config ) { case IVAS_AUDIO_CONFIG_FOA: case IVAS_AUDIO_CONFIG_HOA2: case IVAS_AUDIO_CONFIG_HOA3: if ( st_ivas->ivas_format == MONO_FORMAT ) { *renderer_type = RENDERER_NON_DIEGETIC_DOWNMIX; } else { *renderer_type = RENDERER_SBA_LINEAR_ENC; } break; case IVAS_AUDIO_CONFIG_5_1: case IVAS_AUDIO_CONFIG_7_1: Loading @@ -304,14 +297,14 @@ void ivas_renderer_select( *renderer_type = RENDERER_MC; break; case IVAS_AUDIO_CONFIG_MONO: if ( *internal_config == IVAS_AUDIO_CONFIG_STEREO ) if ( st_ivas->ivas_format == STEREO_FORMAT ) { /* stereo to mono downmix */ *renderer_type = RENDERER_MC; } break; case IVAS_AUDIO_CONFIG_STEREO: if ( *internal_config == IVAS_AUDIO_CONFIG_MONO ) if ( st_ivas->ivas_format == MONO_FORMAT ) { /* mono to stereo upmix */ *renderer_type = RENDERER_NON_DIEGETIC_DOWNMIX; Loading