summaryrefslogtreecommitdiff
path: root/libavformat/mpegts.c
diff options
context:
space:
mode:
authorwm4 <nfxjfg@googlemail.com>2017-05-23 13:36:38 +0200
committerwm4 <nfxjfg@googlemail.com>2017-06-07 11:08:06 +0200
commit66cf78e932956eaa7d5a9dab8766efbfc1431e55 (patch)
tree6fb2a32d50643c5b00d5c7a149d2bba21a7f8142 /libavformat/mpegts.c
parent34c52005605d68f7cd1957b169b6732c7d2447d9 (diff)
lavf: consider codec framerate for framerate detection
Fixes detection of some TV sample as 24.5 FPS. With the patch applied, it's detected as 25 FPS. This is enabled for mpegts only.
Diffstat (limited to 'libavformat/mpegts.c')
-rw-r--r--libavformat/mpegts.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libavformat/mpegts.c b/libavformat/mpegts.c
index 3eff1522bd..4d2f5c6802 100644
--- a/libavformat/mpegts.c
+++ b/libavformat/mpegts.c
@@ -2616,6 +2616,8 @@ static int mpegts_read_header(AVFormatContext *s)
int len;
int64_t pos, probesize = s->probesize;
+ s->internal->prefer_codec_framerate = 1;
+
if (ffio_ensure_seekback(pb, probesize) < 0)
av_log(s, AV_LOG_WARNING, "Failed to allocate buffers for seekback\n");