diff options
| author | Thom Johansen <thomj@rockbox.org> | 2007-11-14 00:55:05 +0000 |
|---|---|---|
| committer | Thom Johansen <thomj@rockbox.org> | 2007-11-14 00:55:05 +0000 |
| commit | 91f618f1ba1e507a9aa1cf7ee87eaf0370272b17 (patch) | |
| tree | 01e714dc8b41d5ee4332109c0c86720ae291bf96 /apps/codecs/libspeex/sb_celp.c | |
| parent | d75a5486e60d10a74049712d8bdf1fa2816038f8 (diff) | |
| download | rockbox-91f618f1ba1e507a9aa1cf7ee87eaf0370272b17.zip rockbox-91f618f1ba1e507a9aa1cf7ee87eaf0370272b17.tar.gz rockbox-91f618f1ba1e507a9aa1cf7ee87eaf0370272b17.tar.bz2 rockbox-91f618f1ba1e507a9aa1cf7ee87eaf0370272b17.tar.xz | |
Remove unneeded math wrappers. Clear state structs in decoder init. Start initial work at stripping away parts of Speex in preparation for its use as a statically linked voice UI codec.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15612 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/codecs/libspeex/sb_celp.c')
| -rw-r--r-- | apps/codecs/libspeex/sb_celp.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/apps/codecs/libspeex/sb_celp.c b/apps/codecs/libspeex/sb_celp.c index 1b648b8..3314f6b 100644 --- a/apps/codecs/libspeex/sb_celp.c +++ b/apps/codecs/libspeex/sb_celp.c @@ -755,7 +755,10 @@ int sb_encode(void *state, void *vin, SpeexBits *bits) static SBDecState global_decstate_wb IBSS_ATTR; +/* Do not include this for voice codec, files will never be UWB */ +#ifndef SPEEX_ROCKBOX_VOICE_CODEC static SBDecState global_decstate_uwb IBSS_ATTR; +#endif void *sb_decoder_init(const SpeexMode *m) { @@ -767,10 +770,13 @@ void *sb_decoder_init(const SpeexMode *m) if (!st) return NULL; */ +#ifndef ROCKBOX_VOICE_CODEC if (m->modeID == SPEEX_MODEID_UWB) st = &global_decstate_uwb; else +#endif st = &global_decstate_wb; + memset(st, 0, sizeof(*st)); st->mode = m; mode=(const SpeexSBMode*)m->mode; st->encode_submode = 1; |