diff options
author | Clément Bœsch <u@pkh.me> | 2017-04-17 13:57:08 +0200 |
---|---|---|
committer | Clément Bœsch <u@pkh.me> | 2017-04-17 13:57:08 +0200 |
commit | b5a42c7f098a0eaee9cb08ce8b26b0c9a307d9c4 (patch) | |
tree | da9b5eb8a99dfa90d03512d539e1c644be737fb9 /libavcodec | |
parent | 5eba94a8c392be44a868183cdacff9a38fe55448 (diff) | |
parent | 0309ddcfb25fd44883bfcdb07509eb4907576b97 (diff) | |
download | ffmpeg-b5a42c7f098a0eaee9cb08ce8b26b0c9a307d9c4.tar.gz |
Merge commit '0309ddcfb25fd44883bfcdb07509eb4907576b97'
* commit '0309ddcfb25fd44883bfcdb07509eb4907576b97':
lavc: handle MP3 in get_audio_frame_duration()
Merged-by: Clément Bœsch <u@pkh.me>
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/utils.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/libavcodec/utils.c b/libavcodec/utils.c index ae245c833e..56e58cc426 100644 --- a/libavcodec/utils.c +++ b/libavcodec/utils.c @@ -1691,6 +1691,9 @@ static int get_audio_frame_duration(enum AVCodecID id, int sr, int ch, int ba, if (id == AV_CODEC_ID_BINKAUDIO_DCT) return (480 << (sr / 22050)) / ch; } + + if (id == AV_CODEC_ID_MP3) + return sr <= 24000 ? 576 : 1152; } if (ba > 0) { |