OSDN Git Service

mpegts: Make the pat_period a double
authorDerek Buitenhuis <derek.buitenhuis@gmail.com>
Fri, 16 Oct 2015 19:09:19 +0000 (15:09 -0400)
committerDerek Buitenhuis <derek.buitenhuis@gmail.com>
Sat, 17 Oct 2015 19:02:06 +0000 (15:02 -0400)
Having it as a float didn't even allow enough precision to check
for INT_MAX/2.

Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
libavformat/mpegtsenc.c
libavformat/version.h

index 45bab1c..6c51c94 100644 (file)
@@ -102,7 +102,7 @@ typedef struct MpegTSWrite {
     int flags;
     int copyts;
     int tables_version;
-    float pat_period;
+    double pat_period;
     float sdt_period;
     int64_t last_pat_ts;
     int64_t last_sdt_ts;
@@ -1555,7 +1555,7 @@ static const AVOption options[] = {
       offsetof(MpegTSWrite, pcr_period), AV_OPT_TYPE_INT,
       { .i64 = PCR_RETRANS_TIME }, 0, INT_MAX, AV_OPT_FLAG_ENCODING_PARAM },
     { "pat_period", "PAT/PMT retransmission time limit in seconds",
-      offsetof(MpegTSWrite, pat_period), AV_OPT_TYPE_FLOAT,
+      offsetof(MpegTSWrite, pat_period), AV_OPT_TYPE_DOUBLE,
       { .dbl = INT_MAX }, 0, INT_MAX, AV_OPT_FLAG_ENCODING_PARAM },
     { "sdt_period", "SDT retransmission time limit in seconds",
       offsetof(MpegTSWrite, sdt_period), AV_OPT_TYPE_FLOAT,
index 5ded978..3b316f8 100644 (file)
@@ -31,7 +31,7 @@
 
 #define LIBAVFORMAT_VERSION_MAJOR  57
 #define LIBAVFORMAT_VERSION_MINOR   8
-#define LIBAVFORMAT_VERSION_MICRO 100
+#define LIBAVFORMAT_VERSION_MICRO 101
 
 #define LIBAVFORMAT_VERSION_INT AV_VERSION_INT(LIBAVFORMAT_VERSION_MAJOR, \
                                                LIBAVFORMAT_VERSION_MINOR, \