[FFmpeg-cvslog] lavf/segment: add segment_start_number option

Stefano Sabatini git at videolan.org
Thu Dec 13 21:40:57 CET 2012


ffmpeg | branch: master | Stefano Sabatini <stefasab at gmail.com> | Sun Dec  9 18:21:00 2012 +0100| [ddf6131a0ab9bf8aa4c5b8702509506d94a6f7b7] | committer: Stefano Sabatini

lavf/segment: add segment_start_number option

Consistent with the image2 muxer.

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=ddf6131a0ab9bf8aa4c5b8702509506d94a6f7b7
---

 doc/muxers.texi       |    3 +++
 libavformat/segment.c |    1 +
 libavformat/version.h |    2 +-
 3 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/doc/muxers.texi b/doc/muxers.texi
index 8ccd9cc..25cf565 100644
--- a/doc/muxers.texi
+++ b/doc/muxers.texi
@@ -602,6 +602,9 @@ separated duration specifications, in increasing order.
 @item segment_wrap @var{limit}
 Wrap around segment index once it reaches @var{limit}.
 
+ at item segment_start_number @var{number}
+Set the sequence number of the first segment. Defaults to @code{0}.
+
 @item reset_timestamps @var{1|0}
 Reset timestamps at the begin of each segment, so that each segment
 will start with near-zero timestamps. It is meant to ease the playback
diff --git a/libavformat/segment.c b/libavformat/segment.c
index dddf0ef..a1aa540 100644
--- a/libavformat/segment.c
+++ b/libavformat/segment.c
@@ -577,6 +577,7 @@ static const AVOption options[] = {
     { "segment_time_delta","set approximation value used for the segment times", OFFSET(time_delta_str), AV_OPT_TYPE_STRING, {.str = "0"}, 0, 0, E },
     { "segment_times",     "set segment split time points",              OFFSET(times_str),AV_OPT_TYPE_STRING,{.str = NULL},  0, 0,       E },
     { "segment_wrap",      "set number after which the index wraps",     OFFSET(segment_idx_wrap), AV_OPT_TYPE_INT, {.i64 = 0}, 0, INT_MAX, E },
+    { "segment_start_number", "set the sequence number of the first segment", OFFSET(segment_idx), AV_OPT_TYPE_INT, {.i64 = 0}, 0, INT_MAX, E },
 
     { "individual_header_trailer", "write header/trailer to each segment", OFFSET(individual_header_trailer), AV_OPT_TYPE_INT, {.i64 = 1}, 0, 1, E },
     { "write_header_trailer", "write a header to the first segment and a trailer to the last one", OFFSET(write_header_trailer), AV_OPT_TYPE_INT, {.i64 = 1}, 0, 1, E },
diff --git a/libavformat/version.h b/libavformat/version.h
index 3b2ba41..f2c0c11 100644
--- a/libavformat/version.h
+++ b/libavformat/version.h
@@ -31,7 +31,7 @@
 
 #define LIBAVFORMAT_VERSION_MAJOR 54
 #define LIBAVFORMAT_VERSION_MINOR 49
-#define LIBAVFORMAT_VERSION_MICRO 101
+#define LIBAVFORMAT_VERSION_MICRO 102
 
 #define LIBAVFORMAT_VERSION_INT AV_VERSION_INT(LIBAVFORMAT_VERSION_MAJOR, \
                                                LIBAVFORMAT_VERSION_MINOR, \



More information about the ffmpeg-cvslog mailing list