diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2012-03-08 02:28:40 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2012-03-08 02:51:45 +0100 |
commit | bf807a5e874442aa3fe1b475459cdd509e34bff4 (patch) | |
tree | f8067bfb5e99b8b8e2716a7ea8519a4aaa8ac60f /libavcodec/wma.c | |
parent | 4cda8aa1c5bc58f8a7f53a21a19b03e7379bbcdc (diff) | |
parent | 6eda85e15b38863a627fd0602098aa3250174698 (diff) | |
download | ffmpeg-bf807a5e874442aa3fe1b475459cdd509e34bff4.tar.gz |
Merge remote-tracking branch 'qatar/master'
* qatar/master: (29 commits)
sbrdsp.asm: convert all instructions to float/SSE ones.
dv: cosmetics.
dv: check buffer size before reading profile.
Revert "AAC SBR: group some writes."
udp: Print an error message if bind fails
cook: extend channel uncoupling tables so the full bit range is covered.
roqvideo: cosmetics.
roqvideo: convert to bytestream2 API.
dca: don't use av_clip_uintp2().
wmall: fix build with -DDEBUG enabled.
smc: port to bytestream2 API.
AAC SBR: group some writes.
dsputil: remove shift parameter from scalarproduct_int16
SBR DSP: unroll sum_square
rv34: remove dead code in intra availability check
rv34: clean a bit availability checks.
v4l2: update documentation
tgq: convert to bytestream2 API.
parser: remove forward declaration of MpegEncContext
dca: prevent accessing static arrays with invalid indexes.
...
Conflicts:
doc/indevs.texi
libavcodec/Makefile
libavcodec/dca.c
libavcodec/dvdata.c
libavcodec/eatgq.c
libavcodec/mmvideo.c
libavcodec/roqvideodec.c
libavcodec/smc.c
libswscale/output.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/wma.c')
-rw-r--r-- | libavcodec/wma.c | 41 |
1 files changed, 1 insertions, 40 deletions
diff --git a/libavcodec/wma.c b/libavcodec/wma.c index a7d5ef2841..1ff18e8be3 100644 --- a/libavcodec/wma.c +++ b/libavcodec/wma.c @@ -22,6 +22,7 @@ #include "avcodec.h" #include "sinewin.h" #include "wma.h" +#include "wma_common.h" #include "wmadata.h" #undef NDEBUG @@ -67,46 +68,6 @@ static void init_coef_vlc(VLC *vlc, uint16_t **prun_table, av_free(level_table); } -/** - *@brief Get the samples per frame for this stream. - *@param sample_rate output sample_rate - *@param version wma version - *@param decode_flags codec compression features - *@return log2 of the number of output samples per frame - */ -int av_cold ff_wma_get_frame_len_bits(int sample_rate, int version, - unsigned int decode_flags) -{ - - int frame_len_bits; - - if (sample_rate <= 16000) { - frame_len_bits = 9; - } else if (sample_rate <= 22050 || - (sample_rate <= 32000 && version == 1)) { - frame_len_bits = 10; - } else if (sample_rate <= 48000 || version < 3) { - frame_len_bits = 11; - } else if (sample_rate <= 96000) { - frame_len_bits = 12; - } else { - frame_len_bits = 13; - } - - if (version == 3) { - int tmp = decode_flags & 0x6; - if (tmp == 0x2) { - ++frame_len_bits; - } else if (tmp == 0x4) { - --frame_len_bits; - } else if (tmp == 0x6) { - frame_len_bits -= 2; - } - } - - return frame_len_bits; -} - int ff_wma_init(AVCodecContext *avctx, int flags2) { WMACodecContext *s = avctx->priv_data; |