Lines Matching refs:mtab
74 const TwinVQModeTab *mtab = tctx->mtab; in eval_lpcenv() local
75 int size_s = mtab->size / mtab->fmode[TWINVQ_FT_SHORT].sub; in eval_lpcenv()
79 lpc[i] = eval_lpc_spectrum(cos_vals, cos_i, mtab->n_lsp); in eval_lpcenv()
80 lpc[size_s - i - 1] = eval_lpc_spectrum(cos_vals, -cos_i, mtab->n_lsp); in eval_lpcenv()
121 const TwinVQModeTab *mtab = tctx->mtab; in eval_lpcenv_or_interp() local
129 mtab->n_lsp); in eval_lpcenv_or_interp()
140 mtab->n_lsp); in eval_lpcenv_or_interp()
217 const TwinVQModeTab *mtab = tctx->mtab; in dec_gain() local
220 int sub = mtab->fmode[ftype].sub; in dec_gain()
266 const TwinVQModeTab *mtab = tctx->mtab; in decode_lsp() local
269 const float *cb = mtab->lspcodebook; in decode_lsp()
270 const float *cb2 = cb + (1 << mtab->lsp_bit1) * mtab->n_lsp; in decode_lsp()
271 const float *cb3 = cb2 + (1 << mtab->lsp_bit2) * mtab->n_lsp; in decode_lsp()
275 mtab->lsp_split == 4 ? -2 : 1, in decode_lsp()
276 mtab->lsp_split == 4 ? -2 : 1, in decode_lsp()
281 for (i = 0; i < mtab->lsp_split; i++) { in decode_lsp()
282 int chunk_end = ((i + 1) * mtab->n_lsp + funny_rounding[i]) / in decode_lsp()
283 mtab->lsp_split; in decode_lsp()
285 lsp[j] = cb[lpc_idx1 * mtab->n_lsp + j] + in decode_lsp()
286 cb2[lpc_idx2[i] * mtab->n_lsp + j]; in decode_lsp()
289 rearrange_lsp(mtab->n_lsp, lsp, 0.0001); in decode_lsp()
291 for (i = 0; i < mtab->n_lsp; i++) { in decode_lsp()
292 float tmp1 = 1.0 - cb3[lpc_hist_idx * mtab->n_lsp + i]; in decode_lsp()
293 float tmp2 = hist[i] * cb3[lpc_hist_idx * mtab->n_lsp + i]; in decode_lsp()
298 rearrange_lsp(mtab->n_lsp, lsp, 0.0001); in decode_lsp()
299 rearrange_lsp(mtab->n_lsp, lsp, 0.000095); in decode_lsp()
300 ff_sort_nearly_sorted_floats(lsp, mtab->n_lsp); in decode_lsp()
307 int size = tctx->mtab->size / tctx->mtab->fmode[ftype].sub; in dec_lpc_spectrum_inv()
309 for (i = 0; i < tctx->mtab->n_lsp; i++) in dec_lpc_spectrum_inv()
331 const TwinVQModeTab *mtab = tctx->mtab; in imdct_and_window() local
332 int bsize = mtab->size / mtab->fmode[ftype].sub; in imdct_and_window()
333 int size = mtab->size; in imdct_and_window()
336 float *out = tctx->curr_frame + 2 * ch * mtab->size; in imdct_and_window()
340 mtab->size / mtab->fmode[TWINVQ_FT_LONG].sub, in imdct_and_window()
341 mtab->size / mtab->fmode[TWINVQ_FT_MEDIUM].sub, in imdct_and_window()
342 mtab->size / (mtab->fmode[TWINVQ_FT_SHORT].sub * 2), in imdct_and_window()
349 for (j = 0; j < mtab->fmode[ftype].sub; j++) { in imdct_and_window()
354 else if (j == mtab->fmode[ftype].sub - 1 && wtype == 7) in imdct_and_window()
381 const TwinVQModeTab *mtab = tctx->mtab; in imdct_output() local
388 tctx->spectrum + i * mtab->size, in imdct_output()
389 prev_buf + 2 * i * mtab->size, in imdct_output()
396 size1 = mtab->size - size2; in imdct_output()
404 memcpy(out2, &prev_buf[2 * mtab->size], in imdct_output()
406 memcpy(out2 + size1, &tctx->curr_frame[2 * mtab->size], in imdct_output()
408 tctx->fdsp->butterflies_float(out1, out2, mtab->size); in imdct_output()
415 const TwinVQModeTab *mtab = tctx->mtab; in read_and_decode_spectrum() local
418 int sub = mtab->fmode[ftype].sub; in read_and_decode_spectrum()
419 int block_size = mtab->size / sub; in read_and_decode_spectrum()
426 mtab->fmode[ftype].cb0, mtab->fmode[ftype].cb1, in read_and_decode_spectrum()
427 mtab->fmode[ftype].cb_len_read); in read_and_decode_spectrum()
432 int cb_len_p = (tctx->n_div[3] + mtab->ppc_shape_len * channels - 1) / in read_and_decode_spectrum()
435 TWINVQ_FT_PPC, mtab->ppc_shape_cb, in read_and_decode_spectrum()
436 mtab->ppc_shape_cb + cb_len_p * TWINVQ_PPC_SHAPE_CB_SIZE, in read_and_decode_spectrum()
441 float *chunk = out + mtab->size * i; in read_and_decode_spectrum()
456 ppc_shape + i * mtab->ppc_shape_len, chunk); in read_and_decode_spectrum()
463 for (j = 0; j < mtab->fmode[ftype].sub; j++) { in read_and_decode_spectrum()
483 const TwinVQModeTab *mtab = tctx->mtab; in ff_twinvq_decode_frame() local
489 frame->nb_samples = mtab->size * tctx->frames_per_packet; in ff_twinvq_decode_frame()
511 tctx->cur_frame * mtab->size); in ff_twinvq_decode_frame()
536 const TwinVQModeTab *mtab = tctx->mtab; in init_mdct_win() local
537 int size_s = mtab->size / mtab->fmode[TWINVQ_FT_SHORT].sub; in init_mdct_win()
538 int size_m = mtab->size / mtab->fmode[TWINVQ_FT_MEDIUM].sub; in init_mdct_win()
541 int table_size = 2 * mtab->size * channels; in init_mdct_win()
544 int bsize = tctx->mtab->size / tctx->mtab->fmode[i].sub; in init_mdct_win()
550 if (!FF_ALLOC_TYPED_ARRAY(tctx->tmp_buf, mtab->size) || in init_mdct_win()
557 int m = 4 * mtab->size / mtab->fmode[i].sub; in init_mdct_win()
569 ff_init_ff_sine_windows(av_log2(mtab->size)); in init_mdct_win()
644 const TwinVQModeTab *mtab = tctx->mtab; in construct_perm_table() local
649 block_size = mtab->ppc_shape_len; in construct_perm_table()
651 size = tctx->avctx->channels * mtab->fmode[ftype].sub; in construct_perm_table()
652 block_size = mtab->size / mtab->fmode[ftype].sub; in construct_perm_table()
668 const TwinVQModeTab *mtab = tctx->mtab; in init_bitstream_params() local
670 int total_fr_bits = tctx->avctx->bit_rate * mtab->size / in init_bitstream_params()
673 int lsp_bits_per_block = n_ch * (mtab->lsp_bit0 + mtab->lsp_bit1 + in init_bitstream_params()
674 mtab->lsp_split * mtab->lsp_bit2); in init_bitstream_params()
676 int ppc_bits = n_ch * (mtab->pgain_bit + mtab->ppc_shape_bit + in init_bitstream_params()
677 mtab->ppc_period_bit); in init_bitstream_params()
685 (mtab->fmode[i].bark_n_coef * in init_bitstream_params()
686 mtab->fmode[i].bark_n_bit + 1); in init_bitstream_params()
695 mtab->fmode[i].sub * (bse_bits[i] + n_ch * TWINVQ_SUB_GAIN_BITS); in init_bitstream_params()
707 bit_size = n_ch * mtab->ppc_shape_bit; in init_bitstream_params()
708 vect_size = n_ch * mtab->ppc_shape_len; in init_bitstream_params()
711 vect_size = n_ch * mtab->size; in init_bitstream_params()