FreeCalypso > hg > gsm-codec-lib
changeset 95:f80a3202c8ff
libgsmefr: implement main decoder wrapper
author | Mychaela Falconia <falcon@freecalypso.org> |
---|---|
date | Sat, 26 Nov 2022 18:58:56 +0000 |
parents | d80e9f12a1d1 |
children | 9cf1355bc071 |
files | libgsmefr/Makefile libgsmefr/dec_wrap.c |
diffstat | 2 files changed, 20 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/libgsmefr/Makefile Sat Nov 26 18:52:49 2022 +0000 +++ b/libgsmefr/Makefile Sat Nov 26 18:58:56 2022 +0000 @@ -2,9 +2,9 @@ CFLAGS= -O2 OBJS= agc.o autocorr.o az_lsp.o basicop2.o c1035pf.o cod_12k2.o convolve.o \ d1035pf.o d_gains.o d_homing.o d_plsf_5.o dec_12k2.o dec_create.o \ - dec_lag6.o dec_main.o dtx.o e_homing.o enc_create.o enc_lag6.o \ - frame2params.o g_code.o g_pitch.o int_lpc.o inter_6.o inv_sqrt.o \ - lag_wind.o levinson.o log2.o lsp_az.o lsp_lsf.o oper_32b.o \ + dec_lag6.o dec_main.o dec_wrap.o dtx.o e_homing.o enc_create.o \ + enc_lag6.o frame2params.o g_code.o g_pitch.o int_lpc.o inter_6.o \ + inv_sqrt.o lag_wind.o levinson.o log2.o lsp_az.o lsp_lsf.o oper_32b.o \ params2frame.o pitch_f6.o pitch_ol.o pow2.o pre_proc.o pred_lt6.o \ preemph.o pstfilt2.o q_gains.o q_plsf_5.o reorder.o residu.o \ sid_class.o sid_insert.o syn_filt.o tls_flags.o weight_a.o
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/libgsmefr/dec_wrap.c Sat Nov 26 18:58:56 2022 +0000 @@ -0,0 +1,17 @@ +/* + * This module contains our EFR_decode_frame() function, which is the primary + * (most common, most useful) interface to our EFR decoder. + */ + +#include "gsm_efr.h" + +void EFR_decode_frame(struct EFR_decoder_state *st, const uint8_t *frame, + int bfi, int taf, int16_t *pcm_out) +{ + int16_t params[EFR_NUM_PARAMS]; + int sid; + + EFR_frame2params(frame, params); + sid = EFR_sid_classify(frame); + EFR_decode_params(st, params, bfi, sid, taf, pcm_out); +}