FreeCalypso > hg > gsm-codec-lib
view libgsmefr/lag_wind.tab @ 477:4c9222d95647
libtwamr encoder: always emit frame->mode = mode;
In the original implementation of amr_encode_frame(), the 'mode' member
of the output struct was set to 0xFF if the output frame type is TX_NO_DATA.
This design was made to mimic the mode field (16-bit word) being set to
0xFFFF (or -1) in 3GPP test sequence format - but nothing actually depends
on this struct member being set in any way, and amr_frame_to_tseq()
generates the needed 0xFFFF on its own, based on frame->type being equal
to TX_NO_DATA.
It is simpler and more efficient to always set frame->mode to the actual
encoding mode in amr_encode_frame(), and this new behavior has already
been documented in doc/AMR-library-API description in anticipation of
the present change.
author | Mychaela Falconia <falcon@freecalypso.org> |
---|---|
date | Sat, 18 May 2024 22:30:42 +0000 |
parents | 37e39cad5838 |
children |
line wrap: on
line source
/*-----------------------------------------------------* | Table of lag_window for autocorrelation. | | noise floor = 1.0001 = (0.9999 on r[1] ..r[10]) | | Bandwitdh expansion = 60 Hz | | | | | | lag_wind[0] = 1.00000000 (not stored) | | lag_wind[1] = 0.99879038 | | lag_wind[2] = 0.99546897 | | lag_wind[3] = 0.98995781 | | lag_wind[4] = 0.98229337 | | lag_wind[5] = 0.97252619 | | lag_wind[6] = 0.96072036 | | lag_wind[7] = 0.94695264 | | lag_wind[8] = 0.93131179 | | lag_wind[9] = 0.91389757 | | lag_wind[10]= 0.89481968 | -----------------------------------------------------*/ static const Word16 lag_h[10] = { 32728, 32619, 32438, 32187, 31867, 31480, 31029, 30517, 29946, 29321 }; static const Word16 lag_l[10] = { 11904, 17280, 30720, 25856, 24192, 28992, 24384, 7360, 19520, 14784 };