diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2012-11-02 23:45:54 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2012-11-02 23:47:58 +0100 |
commit | d8aaec38fc89bb3b6e7e46d6fd30f939efb07456 (patch) | |
tree | 42b99dd1154f225122decace14d35271c3df59c7 /libavcodec/amrnbdec.c | |
parent | f58f600c6899bcfbc359b7db7b9d2fc50ae6961d (diff) | |
download | ffmpeg-d8aaec38fc89bb3b6e7e46d6fd30f939efb07456.tar.gz |
amrnbdec: allow sample rates other than 8khz
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/amrnbdec.c')
-rw-r--r-- | libavcodec/amrnbdec.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libavcodec/amrnbdec.c b/libavcodec/amrnbdec.c index 95deee63f2..a523a54ccb 100644 --- a/libavcodec/amrnbdec.c +++ b/libavcodec/amrnbdec.c @@ -169,7 +169,8 @@ static av_cold int amrnb_decode_init(AVCodecContext *avctx) avctx->channels = 1; avctx->channel_layout = AV_CH_LAYOUT_MONO; - avctx->sample_rate = 8000; + if (!avctx->sample_rate) + avctx->sample_rate = 8000; avctx->sample_fmt = AV_SAMPLE_FMT_FLT; // p->excitation always points to the same position in p->excitation_buf |