[FFmpeg-cvslog] r18779 - trunk/libavformat/mpegtsenc.c

bcoudurier subversion
Sun May 10 03:37:59 CEST 2009


Author: bcoudurier
Date: Sun May 10 03:37:58 2009
New Revision: 18779

Log:
do not write dts if pts is not set

Modified:
   trunk/libavformat/mpegtsenc.c

Modified: trunk/libavformat/mpegtsenc.c
==============================================================================
--- trunk/libavformat/mpegtsenc.c	Sun May 10 03:02:18 2009	(r18778)
+++ trunk/libavformat/mpegtsenc.c	Sun May 10 03:37:58 2009	(r18779)
@@ -597,7 +597,7 @@ static void mpegts_write_pes(AVFormatCon
                 header_len += 5;
                 flags |= 0x80;
             }
-            if (dts != AV_NOPTS_VALUE && dts != pts) {
+            if (dts != AV_NOPTS_VALUE && pts != AV_NOPTS_VALUE && dts != pts) {
                 header_len += 5;
                 flags |= 0x40;
             }
@@ -630,7 +630,7 @@ static void mpegts_write_pes(AVFormatCon
                 write_pts(q, flags >> 6, pts);
                 q += 5;
             }
-            if (dts != AV_NOPTS_VALUE && dts != pts) {
+            if (dts != AV_NOPTS_VALUE && pts != AV_NOPTS_VALUE && dts != pts) {
                 write_pts(q, 1, dts);
                 q += 5;
             }



More information about the ffmpeg-cvslog mailing list