diff options
author | Thom Johansen <thomj@rockbox.org> | 2007-10-19 21:10:25 +0000 |
---|---|---|
committer | Thom Johansen <thomj@rockbox.org> | 2007-10-19 21:10:25 +0000 |
commit | 56db5597548d0e9b9733b556a5c14ab4e38547e6 (patch) | |
tree | 8846e7d3a15f264853e6ee238994e3522e3bcc5a /apps/codecs/libspeex/filters.c | |
parent | 6dc3a743addde6146b736ec5e1c71159c2150f95 (diff) | |
download | rockbox-56db5597548d0e9b9733b556a5c14ab4e38547e6.tar.gz rockbox-56db5597548d0e9b9733b556a5c14ab4e38547e6.zip |
Sync Speex to SVN. Add new header file to adapt to Speex' new way of doing wrapper functions.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15209 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/codecs/libspeex/filters.c')
-rw-r--r-- | apps/codecs/libspeex/filters.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/apps/codecs/libspeex/filters.c b/apps/codecs/libspeex/filters.c index fcb8ed4bac..a6a5f62d26 100644 --- a/apps/codecs/libspeex/filters.c +++ b/apps/codecs/libspeex/filters.c | |||
@@ -80,17 +80,16 @@ void sanitize_values32(spx_word32_t *vec, spx_word32_t min_val, spx_word32_t max | |||
80 | } | 80 | } |
81 | } | 81 | } |
82 | 82 | ||
83 | void highpass(const spx_word16_t *x, spx_word16_t *y, int len, int filtID, spx_mem_t *mem) | ||
84 | { | ||
85 | int i; | ||
83 | #ifdef FIXED_POINT | 86 | #ifdef FIXED_POINT |
84 | const spx_word16_t Pcoef[5][3] ICONST_ATTR = {{16384, -31313, 14991}, {16384, -31569, 15249}, {16384, -31677, 15328}, {16384, -32313, 15947}, {16384, -22446, 6537}}; | 87 | static const spx_word16_t Pcoef[5][3] ICONST_ATTR = {{16384, -31313, 14991}, {16384, -31569, 15249}, {16384, -31677, 15328}, {16384, -32313, 15947}, {16384, -22446, 6537}}; |
85 | const spx_word16_t Zcoef[5][3] ICONST_ATTR = {{15672, -31344, 15672}, {15802, -31601, 15802}, {15847, -31694, 15847}, {16162, -32322, 16162}, {14418, -28836, 14418}}; | 88 | static const spx_word16_t Zcoef[5][3] ICONST_ATTR = {{15672, -31344, 15672}, {15802, -31601, 15802}, {15847, -31694, 15847}, {16162, -32322, 16162}, {14418, -28836, 14418}}; |
86 | #else | 89 | #else |
87 | const spx_word16_t Pcoef[5][3] = {{1.00000f, -1.91120f, 0.91498f}, {1.00000f, -1.92683f, 0.93071f}, {1.00000f, -1.93338f, 0.93553f}, {1.00000f, -1.97226f, 0.97332f}, {1.00000f, -1.37000f, 0.39900f}}; | 90 | const spx_word16_t Pcoef[5][3] = {{1.00000f, -1.91120f, 0.91498f}, {1.00000f, -1.92683f, 0.93071f}, {1.00000f, -1.93338f, 0.93553f}, {1.00000f, -1.97226f, 0.97332f}, {1.00000f, -1.37000f, 0.39900f}}; |
88 | const spx_word16_t Zcoef[5][3] = {{0.95654f, -1.91309f, 0.95654f}, {0.96446f, -1.92879f, 0.96446f}, {0.96723f, -1.93445f, 0.96723f}, {0.98645f, -1.97277f, 0.98645f}, {0.88000f, -1.76000f, 0.88000f}}; | 91 | const spx_word16_t Zcoef[5][3] = {{0.95654f, -1.91309f, 0.95654f}, {0.96446f, -1.92879f, 0.96446f}, {0.96723f, -1.93445f, 0.96723f}, {0.98645f, -1.97277f, 0.98645f}, {0.88000f, -1.76000f, 0.88000f}}; |
89 | #endif | 92 | #endif |
90 | |||
91 | void highpass(const spx_word16_t *x, spx_word16_t *y, int len, int filtID, spx_mem_t *mem) | ||
92 | { | ||
93 | int i; | ||
94 | const spx_word16_t *den, *num; | 93 | const spx_word16_t *den, *num; |
95 | if (filtID>4) | 94 | if (filtID>4) |
96 | filtID=4; | 95 | filtID=4; |