[FFmpeg-cvslog] amrwbdec: allow sample rates other than 16khz
Michael Niedermayer
git at videolan.org
Sat Nov 3 00:09:31 CET 2012
ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Fri Nov 2 23:46:19 2012 +0100| [2c1e9383a275a1591cc4d42fcdaa18b753800334] | committer: Michael Niedermayer
amrwbdec: allow sample rates other than 16khz
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=2c1e9383a275a1591cc4d42fcdaa18b753800334
---
libavcodec/amrwbdec.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/libavcodec/amrwbdec.c b/libavcodec/amrwbdec.c
index 79a9f14..a0e7cd6 100644
--- a/libavcodec/amrwbdec.c
+++ b/libavcodec/amrwbdec.c
@@ -105,7 +105,8 @@ static av_cold int amrwb_decode_init(AVCodecContext *avctx)
avctx->channels = 1;
avctx->channel_layout = AV_CH_LAYOUT_MONO;
- avctx->sample_rate = 16000;
+ if (!avctx->sample_rate)
+ avctx->sample_rate = 16000;
avctx->sample_fmt = AV_SAMPLE_FMT_FLT;
av_lfg_init(&ctx->prng, 1);
More information about the ffmpeg-cvslog
mailing list