diff options
| author | Tom Ross <midgey@rockbox.org> | 2008-12-20 06:40:46 +0000 |
|---|---|---|
| committer | Tom Ross <midgey@rockbox.org> | 2008-12-20 06:40:46 +0000 |
| commit | e7afeff072b322fb748b52829fe772570b2c711f (patch) | |
| tree | 281aeddbb88afd3b2ab515f406369c7ee59e0787 /apps | |
| parent | c3615119ba2e486006acbbe96875c6be0fb020df (diff) | |
| download | rockbox-e7afeff072b322fb748b52829fe772570b2c711f.zip rockbox-e7afeff072b322fb748b52829fe772570b2c711f.tar.gz rockbox-e7afeff072b322fb748b52829fe772570b2c711f.tar.bz2 rockbox-e7afeff072b322fb748b52829fe772570b2c711f.tar.xz | |
Sync some changes found in ffmpeg plus a spelling correction I forgot to commit.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19503 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps')
| -rw-r--r-- | apps/codecs/libwma/wmadec.h | 4 | ||||
| -rw-r--r-- | apps/codecs/libwma/wmadeci.c | 18 |
2 files changed, 11 insertions, 11 deletions
diff --git a/apps/codecs/libwma/wmadec.h b/apps/codecs/libwma/wmadec.h index cb49f61..aaa06ee 100644 --- a/apps/codecs/libwma/wmadec.h +++ b/apps/codecs/libwma/wmadec.h @@ -148,8 +148,8 @@ WMADecodeContext; int wma_decode_init(WMADecodeContext* s, asf_waveformatex_t *wfx); int wma_decode_superframe_init(WMADecodeContext* s, - uint8_t *buf, int buf_size); + const uint8_t *buf, int buf_size); int wma_decode_superframe_frame(WMADecodeContext* s, int32_t *samples, - uint8_t *buf, int buf_size); + const uint8_t *buf, int buf_size); #endif diff --git a/apps/codecs/libwma/wmadeci.c b/apps/codecs/libwma/wmadeci.c index eb29b12..9fac72f 100644 --- a/apps/codecs/libwma/wmadeci.c +++ b/apps/codecs/libwma/wmadeci.c @@ -987,12 +987,12 @@ static int wma_decode_block(WMADecodeContext *s, int32_t *scratch_buffer) if (s->nb_channels == 2) { - s->ms_stereo = get_bits(&s->gb, 1); + s->ms_stereo = get_bits1(&s->gb); } v = 0; for (ch = 0; ch < s->nb_channels; ++ch) { - a = get_bits(&s->gb, 1); + a = get_bits1(&s->gb); s->channel_coded[ch] = a; v |= a; } @@ -1048,7 +1048,7 @@ static int wma_decode_block(WMADecodeContext *s, int32_t *scratch_buffer) n = s->exponent_high_sizes[bsize]; for(i=0;i<n;++i) { - a = get_bits(&s->gb, 1); + a = get_bits1(&s->gb); s->high_band_coded[ch][i] = a; /* if noise coding, the coefficients are not transmitted */ if (a) @@ -1090,7 +1090,7 @@ static int wma_decode_block(WMADecodeContext *s, int32_t *scratch_buffer) } /* exponents can be reused in short blocks. */ - if ((s->block_len_bits == s->frame_len_bits) || get_bits(&s->gb, 1)) + if ((s->block_len_bits == s->frame_len_bits) || get_bits1(&s->gb)) { for(ch = 0; ch < s->nb_channels; ++ch) { @@ -1160,7 +1160,7 @@ static int wma_decode_block(WMADecodeContext *s, int32_t *scratch_buffer) run = run_table[code]; level = level_table[code]; } - sign = get_bits(&s->gb, 1); + sign = get_bits1(&s->gb); if (!sign) level = -level; ptr += run; @@ -1258,7 +1258,7 @@ static int wma_decode_block(WMADecodeContext *s, int32_t *scratch_buffer) e2 = 0; for(i = 0;i < n; ++i) { - /*v is noramlized later on so its fixed format is irrelevant*/ + /*v is normalized later on so its fixed format is irrelevant*/ v = exponents[i<<bsize>>esize]>>4; e2 += fixmul32(v, v)>>3; } @@ -1484,7 +1484,7 @@ static int wma_decode_frame(WMADecodeContext *s, int32_t *samples) /* Initialise the superframe decoding */ int wma_decode_superframe_init(WMADecodeContext* s, - uint8_t *buf, /*input*/ + const uint8_t *buf, /*input*/ int buf_size) { if (buf_size==0) @@ -1500,7 +1500,7 @@ int wma_decode_superframe_init(WMADecodeContext* s, if (s->use_bit_reservoir) { /* read super frame header */ - get_bits(&s->gb, 4); /* super frame index */ + skip_bits(&s->gb, 4); /* super frame index */ s->nb_frames = get_bits(&s->gb, 4); if (s->last_superframe_len == 0) @@ -1523,7 +1523,7 @@ int wma_decode_superframe_init(WMADecodeContext* s, int wma_decode_superframe_frame(WMADecodeContext* s, int32_t* samples, /*output*/ - uint8_t *buf, /*input*/ + const uint8_t *buf, /*input*/ int buf_size) { int pos, len; |