From 194be1f43ea391eb986732707435176e579265aa Mon Sep 17 00:00:00 2001 From: Anton Khirnov Date: Sun, 18 May 2014 12:12:59 +0200 Subject: lavf: switch to AVStream.time_base as the hint for the muxer timebase Previously, AVStream.codec.time_base was used for that purpose, which was quite confusing for the callers. This change also opens the path for removing AVStream.codec. The change in the lavf-mkv test is due to the native timebase (1/1000) being used instead of the default one (1/90000), so the packets are now sent to the crc muxer in the same order in which they are demuxed (previously some of them got reordered because of inexact timestamp conversion). --- libavformat/riffenc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'libavformat/riffenc.c') diff --git a/libavformat/riffenc.c b/libavformat/riffenc.c index 8f0279628e..b83533a250 100644 --- a/libavformat/riffenc.c +++ b/libavformat/riffenc.c @@ -230,8 +230,8 @@ void ff_parse_specific_params(AVStream *st, int *au_rate, } else if (codec->codec_type == AVMEDIA_TYPE_VIDEO || codec->codec_type == AVMEDIA_TYPE_DATA || codec->codec_type == AVMEDIA_TYPE_SUBTITLE) { - *au_scale = codec->time_base.num; - *au_rate = codec->time_base.den; + *au_scale = st->time_base.num; + *au_rate = st->time_base.den; } else { *au_scale = codec->block_align ? codec->block_align * 8 : 8; *au_rate = codec->bit_rate ? codec->bit_rate : -- cgit v1.2.3