From d9a9801171d53d12fd5e6df96ae6496056096f7c Mon Sep 17 00:00:00 2001 From: Thom Johansen Date: Tue, 6 Nov 2007 21:25:46 +0000 Subject: [PATCH] Smaller and more correctly sized statically allocated arrays in decoder state structs. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15500 a1c6a512-1295-4272-9138-f99709370657 --- apps/codecs/libspeex/nb_celp.h | 6 +++--- apps/codecs/libspeex/sb_celp.h | 10 +++++----- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/apps/codecs/libspeex/nb_celp.h b/apps/codecs/libspeex/nb_celp.h index 5442976cd2..805c43c950 100644 --- a/apps/codecs/libspeex/nb_celp.h +++ b/apps/codecs/libspeex/nb_celp.h @@ -142,14 +142,14 @@ typedef struct DecState { char *stack; /**< Pseudo-stack allocation for temporary memory */ /* Size calculated from maximum values of frameSize, max_pitch and - * subframeSize, being respectively 320, 144 and 80 (for uwb) */ - spx_word16_t excBuf[556]; /**< Excitation buffer */ + * subframeSize, being respectively 160, 144 and 40 */ + spx_word16_t excBuf[500]; /**< Excitation buffer */ spx_word16_t *exc; /**< Start of excitation frame */ spx_lsp_t old_qlsp[10]; /**< Quantized LSPs for previous frame */ spx_coef_t interp_qlpc[10]; /**< Interpolated quantized LPCs */ spx_mem_t mem_sp[10]; /**< Filter memory for synthesis signal */ spx_mem_t mem_hp[2]; /**< High-pass filter memory */ - spx_word32_t pi_gain[5]; /**< Gain of LPC filter at theta=pi (fe/2) */ + spx_word32_t pi_gain[4]; /**< Gain of LPC filter at theta=pi (fe/2) */ spx_word16_t *innov_save; /** If non-NULL, innovation is copied here */ spx_word16_t level; diff --git a/apps/codecs/libspeex/sb_celp.h b/apps/codecs/libspeex/sb_celp.h index da3545d943..1f9b4daae0 100644 --- a/apps/codecs/libspeex/sb_celp.h +++ b/apps/codecs/libspeex/sb_celp.h @@ -112,12 +112,12 @@ typedef struct SBDecState { spx_word16_t g0_mem[64], g1_mem[64]; spx_word16_t excBuf[80]; - spx_lsp_t old_qlsp[10]; - spx_coef_t interp_qlpc[10]; + spx_lsp_t old_qlsp[8]; + spx_coef_t interp_qlpc[8]; - spx_mem_t mem_sp[20]; - spx_word32_t pi_gain[5]; - spx_word16_t exc_rms[5]; + spx_mem_t mem_sp[16]; + spx_word32_t pi_gain[4]; + spx_word16_t exc_rms[4]; spx_word16_t *innov_save; /** If non-NULL, innovation is copied here */ spx_word16_t last_ener;