aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat
diff options
context:
space:
mode:
authorJohn-Paul Stewart <jpstewart@personalprojects.net>2021-12-18 15:46:28 -0500
committerPeter Ross <pross@xvid.org>2021-12-21 12:01:22 +1100
commit50bfd5e96e98e86df08cc7ffdf726f6ed6851ee7 (patch)
treee82057c10ece5e9f400d28e8b2f9456e52742b2f /libavformat
parent3c9ffbd009243b3e83ba20956ff6401918376073 (diff)
downloadffmpeg-50bfd5e96e98e86df08cc7ffdf726f6ed6851ee7.tar.gz
avformat/mvdec: explicitly set duration
Resolves a warning that duration is being innaccurately estimated based on bitrate. Signed-off-by: John-Paul Stewart <jpstewart@personalprojects.net> Reviewed-by: Peter Ross <pross@xvid.org>
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/mvdec.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/mvdec.c b/libavformat/mvdec.c
index a5c5b205a6..1a5012e507 100644
--- a/libavformat/mvdec.c
+++ b/libavformat/mvdec.c
@@ -319,7 +319,7 @@ static int mv_read_header(AVFormatContext *avctx)
avio_skip(pb, 4);
vst->codecpar->codec_type = AVMEDIA_TYPE_VIDEO;
vst->avg_frame_rate = fps;
- vst->nb_frames = avio_rb32(pb);
+ vst->duration = vst->nb_frames = avio_rb32(pb);
v = avio_rb32(pb);
switch (v) {
case 1: