Commit 720b8724 authored by vaclav's avatar vaclav
Browse files

accept SIMPLIFY_TD_BWE_RESET and REMOVE_ETOT_PROPAGATION

parent 46ac1b29
Loading
Loading
Loading
Loading
Loading
+0 −8
Original line number Diff line number Diff line
@@ -168,9 +168,6 @@ ivas_error pre_proc_front_ivas(
    const int16_t n,                                            /* i  : channel number                             */
    float old_inp_12k8[],                                       /* o  : buffer of old input signal                 */
    float old_inp_16k[],                                        /* o  : buffer of old input signal @16kHz          */
#ifndef REMOVE_ETOT_PROPAGATION
    float *Etot,                                                /* o  : total energy                               */
#endif
    float *ener,                                                /* o  : residual energy from Levinson-Durbin       */
    float *relE,                                                /* o  : frame relative energy                      */
    float A[NB_SUBFR16k * ( M + 1 )],                           /* o  : A(z) unquantized for the 4 subframes       */
@@ -411,9 +408,6 @@ ivas_error ivas_core_enc(
    const int16_t n_CoreChannels,                                            /* i  : number of core channels to be coded     */
    float old_inp_12k8[CPE_CHANNELS][L_INP_12k8],                            /* i  : buffer of old input signal              */
    float old_inp_16k[CPE_CHANNELS][L_INP],                                  /* i  : buffer of old input signal              */
#ifndef REMOVE_ETOT_PROPAGATION
    const float Etot[CPE_CHANNELS],                                          /* i  : total energy                            */
#endif
    float ener[CPE_CHANNELS],                                                /* i  : residual energy from Levinson-Durbin    */
    float A[CPE_CHANNELS][NB_SUBFR16k * ( M + 1 )],                          /* i  : A(z) unquantized for the 4 subframes    */
    float Aw[CPE_CHANNELS][NB_SUBFR16k * ( M + 1 )],                         /* i  : weighted A(z) unquantized for subframes */
@@ -1752,9 +1746,7 @@ void tdm_ol_pitch_comparison(

void tdm_configure_enc(
    CPE_ENC_HANDLE hCPE,                                        /* i  : CPE encoder structure                   */
#ifdef REMOVE_ETOT_PROPAGATION
    const float Etot_last[CPE_CHANNELS],                        /* i/o: Energy of last frame                    */
#endif
    const int16_t tdm_SM_or_LRTD_Pri,                           /* i  : channel combination scheme flag in TD stereo OR LRTD primary channel */
    const int16_t tdm_ratio_idx,                                /* i  : ratio index                             */
    const int16_t tdm_ratio_idx_SM,                             /* i  : ratio index in SM mode                  */
+0 −2
Original line number Diff line number Diff line
@@ -147,8 +147,6 @@
#define FIX_I59_DELAY_ROUNDING                          /* Issue 59: rounding in sample domain instead of nanosec for IVAS_ENC_GetDelay() and IVAS_DEC_GetDelay() */
#define FIX_FIX_I59                                     /* Issue 59:  small fix concerning LFE delay rounding */
#define MC_BITRATE_SWITCHING                            /* Issue 116: support bitrate switching in MC format  */
#define SIMPLIFY_TD_BWE_RESET                           /* Issue 250: Resolve "TB-BWE state memories reset simplification"  */
#define REMOVE_ETOT_PROPAGATION                         /* Issue 251: Do not propagate Etot parameter */
#define MC_JBM                                          /* FhG: extend JBM beyond mono for running IVAS in VoIP mode (contribution 19) */


+1 −6
Original line number Diff line number Diff line
@@ -2278,9 +2278,6 @@ void pre_proc(
    float old_inp_16k[],          /* i/o: buffer of old input signal @ 16kHz      */
    float **inp,                  /* o  : ptr. to inp. signal in the current frame*/
    float fr_bands[2 * NB_BANDS], /* i  : energy in frequency bands               */
#ifndef REMOVE_ETOT_PROPAGATION
    float *Etot, /* i  : total energy                            */
#endif
    float *ener,                  /* o  : residual energy from Levinson-Durbin    */
#ifndef FIX_I4_OL_PITCH
    int16_t pitch_orig[3], /* o  : open-loop pitch values for quantization */
@@ -2599,12 +2596,10 @@ void InitSWBencBuffer(
    TD_BWE_ENC_HANDLE hBWE_TD /* i/o: TD BWE data handle                      */
);

#ifdef SIMPLIFY_TD_BWE_RESET
void InitSWBencBufferStates(
    TD_BWE_ENC_HANDLE hBWE_TD, /* i/o: TD BWE data handle                   */
    float *shb_speech          /* o  : SHB target signal (6-14kHz) at 16kHz */
);
#endif

void swb_tbe_enc(
    Encoder_State *st,                    /* i/o: encoder state structure                 */
+0 −3
Original line number Diff line number Diff line
@@ -532,9 +532,6 @@ void amr_wb_enc(

    /* update main codec paramaters */
#ifdef MC_BITRATE_SWITCHING
#ifndef REMOVE_ETOT_PROPAGATION
    st->hNoiseEst->Etot_last = Etot;
#endif
    updt_enc_common( st );
#else
    updt_enc_common( st, Etot );
+0 −14
Original line number Diff line number Diff line
@@ -401,22 +401,8 @@ void core_switching_post_enc(
             ( st->last_core == HQ_CORE || st->L_frame != st->last_L_frame || ( st->last_extl != SWB_TBE && st->last_extl != FB_TBE && st->last_core != TCX_20_CORE && st->last_core != TCX_10_CORE ) ) )
        {
            set_f( st->hBWE_TD->state_ana_filt_shb, 0.0f, ( 2 * ALLPASSSECTIONS_STEEP + 1 ) );
#ifdef SIMPLIFY_TD_BWE_RESET
            InitSWBencBufferStates( st->hBWE_TD, NULL );
#else
            set_f( st->hBWE_TD->old_speech_shb, 0.0f, L_LOOK_16k + L_SUBFR16k );
            set_f( st->hBWE_TD->mem_shb_res, 0.0f, MAX_LEN_MA_FILTER );
            set_f( st->hBWE_TD->old_EnvSHBres, 0.0f, L_FRAME4k );
            st->hBWE_TD->old_mean_EnvSHBres = 0.0f;
            st->hBWE_TD->prev_enr_EnvSHBres = 1.0f;
            st->hBWE_TD->prev_shb_env_tilt = 0.0f;
            st->hBWE_TD->prev_pow_exc16kWhtnd = 1.0f;
            st->hBWE_TD->prev_mix_factor = 1.0f;
            st->hBWE_TD->prev_Env_error = 0.0f;
#endif

            swb_tbe_reset( st->hBWE_TD->mem_csfilt, st->hBWE_TD->mem_genSHBexc_filt_down_shb, st->hBWE_TD->state_lpc_syn, st->hBWE_TD->syn_overlap, st->hBWE_TD->state_syn_shbexc, &( st->hBWE_TD->tbe_demph ), &( st->hBWE_TD->tbe_premph ), st->hBWE_TD->mem_stp_swb, &( st->hBWE_TD->gain_prec_swb ) );

            set_f( st->hBWE_TD->dec_2_over_3_mem, 0.0f, L_FILT_2OVER3 );
            set_f( st->hBWE_TD->dec_2_over_3_mem_lp, 0.0f, L_FILT_2OVER3_LP );
        }
Loading