summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--libmpdemux/demux_lavf.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/libmpdemux/demux_lavf.c b/libmpdemux/demux_lavf.c
index 8ad8ad076f..a7e8012159 100644
--- a/libmpdemux/demux_lavf.c
+++ b/libmpdemux/demux_lavf.c
@@ -196,6 +196,10 @@ static demuxer_t* demux_open_lavf(demuxer_t *demuxer){
register_protocol(&mp_protocol);
avfc = av_alloc_format_context();
+
+ if (correct_pts)
+ avfc->flags |= AVFMT_FLAG_GENPTS;
+
ap.prealloced_context = 1;
if(opt_probesize) {
double d = (double) opt_probesize;