Exemplo n.º 1
0
void init_decod_ld8a(struct dec_state_t * state)
{
  /* Initialize static pointer */

  state->exc = state->old_exc + PIT_MAX + L_INTERPOL;

  /* Static vectors to zero */

  set_zero(state->old_exc, PIT_MAX+L_INTERPOL);
  set_zero(state->mem_syn, M);

  state->sharp  = SHARPMIN;
  state->old_t0 = 60;
  state->gain_code = (F)0.0;
  state->gain_pitch = (F)0.0;

  lsp_decw_reset(&state->lsp_s);

  init_exc_err(state->cng_s.exc_err); // ?

  copy(lsp_reset, state->lsp_old, M);

  /* for G.729B */
  state->seed_fer = 21845;
  state->past_ftyp = 1;
  state->seed = INIT_SEED;
  state->sid_sav = (F)0.;
  init_lsfq_noise(&state->cng_s.lsfq_s); // ?

  gain_past_reset(&state->gain_s);

  state->bad_lsf = 0;          /* Initialize bad LSF indicator */
}
Exemplo n.º 2
0
/*--------------------------------------------------------------------------
 * init_decod_ld8k - Initialization of variables for the decoder section.
 *--------------------------------------------------------------------------
 */
void init_decod_ld8k(void)
{
    /* Initialize static pointer */
    exc    = old_exc + PIT_MAX + L_INTERPOL;

    /* Static vectors to zero */
    set_zero(old_exc,PIT_MAX + L_INTERPOL);
    set_zero(mem_syn, M);

    sharp = SHARPMIN;
    old_t0 = 60;
    gain_code = (F)0.;
    gain_pitch = (F)0.;

    lsp_decw_reset();

    return;
}