# HG changeset patch # User michael # Date 1218816785 0 # Node ID 178cc6f9d5ec6576c88a165982426058eb54eb61 # Parent 81726233f9b371610783eb83df86ad478617f85f Add flag to mark demuxers that can output discontinuous timestamps. (could also be added to muxers if someone wants) diff -r 81726233f9b3 -r 178cc6f9d5ec avformat.h --- a/avformat.h Thu Aug 14 22:36:05 2008 +0000 +++ b/avformat.h Fri Aug 15 16:13:05 2008 +0000 @@ -187,6 +187,7 @@ #define AVFMT_GLOBALHEADER 0x0040 /**< format wants global header */ #define AVFMT_NOTIMESTAMPS 0x0080 /**< format does not need / have any timestamps */ #define AVFMT_GENERIC_INDEX 0x0100 /**< use generic index building code */ +#define AVFMT_TS_DISCONT 0x0200 /**< format allows timestamo discontinuities */ typedef struct AVOutputFormat { const char *name; diff -r 81726233f9b3 -r 178cc6f9d5ec mpeg.c --- a/mpeg.c Thu Aug 14 22:36:05 2008 +0000 +++ b/mpeg.c Fri Aug 15 16:13:05 2008 +0000 @@ -586,5 +586,5 @@ NULL, NULL, //mpegps_read_seek, mpegps_read_dts, - .flags = AVFMT_SHOW_IDS, + .flags = AVFMT_SHOW_IDS|AVFMT_TS_DISCONT, }; diff -r 81726233f9b3 -r 178cc6f9d5ec mpegts.c --- a/mpegts.c Thu Aug 14 22:36:05 2008 +0000 +++ b/mpegts.c Fri Aug 15 16:13:05 2008 +0000 @@ -1524,7 +1524,7 @@ mpegts_read_close, read_seek, mpegts_get_pcr, - .flags = AVFMT_SHOW_IDS, + .flags = AVFMT_SHOW_IDS|AVFMT_TS_DISCONT, }; AVInputFormat mpegtsraw_demuxer = { @@ -1537,5 +1537,5 @@ mpegts_read_close, read_seek, mpegts_get_pcr, - .flags = AVFMT_SHOW_IDS, + .flags = AVFMT_SHOW_IDS|AVFMT_TS_DISCONT, };