From 7b827a029338ef8af689e84a352825797b286e26 Mon Sep 17 00:00:00 2001 From: Anton Khirnov Date: Wed, 5 Apr 2023 16:35:22 +0200 Subject: [PATCH] lavf/demux: treat streams with AVSTREAM_PARSE_FULL_RAW as having timestamps In this case the timestamps are set by the parser. Cf. a6b3471c44fd981d3b33ea9050f78a0bc9494c5e Required by the following commit. --- libavformat/demux.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavformat/demux.c b/libavformat/demux.c index b19ab86d08..06de71cd6e 100644 --- a/libavformat/demux.c +++ b/libavformat/demux.c @@ -2569,7 +2569,7 @@ int avformat_find_stream_info(AVFormatContext *ic, AVDictionary **options) extract_extradata_check(st)) break; if (sti->first_dts == AV_NOPTS_VALUE && - !(ic->iformat->flags & AVFMT_NOTIMESTAMPS) && + (!(ic->iformat->flags & AVFMT_NOTIMESTAMPS) || sti->need_parsing == AVSTREAM_PARSE_FULL_RAW) && sti->codec_info_nb_frames < ((st->disposition & AV_DISPOSITION_ATTACHED_PIC) ? 1 : ic->max_ts_probe) && (st->codecpar->codec_type == AVMEDIA_TYPE_VIDEO || st->codecpar->codec_type == AVMEDIA_TYPE_AUDIO))