summaryrefslogtreecommitdiff
path: root/apps/codecs
diff options
context:
space:
mode:
authorMichael Giacomelli <giac2000@hotmail.com>2008-12-20 01:49:27 +0000
committerMichael Giacomelli <giac2000@hotmail.com>2008-12-20 01:49:27 +0000
commitd909eee0cecb8645ff9b8ab3001505c9ac4cf87b (patch)
tree532a70e407531e5b0e62ab238afd49251f30ed6c /apps/codecs
parentc983e3b1d25503e71d0d7cba7c921b16c216770b (diff)
Commit fix by Tom Ross in FS#7488 wherein a silly mistake noise coding initialization is corrected. This sample alone has probably resulted in more WMA fixes then all other combined and I suspect there will still be at least one more.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19496 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/codecs')
-rw-r--r--apps/codecs/libwma/wmadeci.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/apps/codecs/libwma/wmadeci.c b/apps/codecs/libwma/wmadeci.c
index 4c06ad0e42..292794b907 100644
--- a/apps/codecs/libwma/wmadeci.c
+++ b/apps/codecs/libwma/wmadeci.c
@@ -1283,10 +1283,8 @@ static int wma_decode_block(WMADecodeContext *s, int32_t *scratch_buffer)
{
/* use noise with specified power */
fixed32 tmp = fixdiv32(exp_power[j],exp_power[last_high_band]);
- mult1 = (fixed64)fixsqrt32(tmp);
- /* XXX: use a table */
/*mult1 is 48.16, pow_table is 48.16*/
- mult1 = mult1 * pow_table[s->high_band_values[ch][j]+20] >> PRECISION;
+ mult1 = fixmul32(fixsqrt32(tmp),pow_table[s->high_band_values[ch][j]+20]) >> 16;
/*this step has a fairly high degree of error for some reason*/
mult1 = fixdiv64(mult1,fixmul32(s->max_exponent[ch],s->noise_mult));