147
147
See also the @ref{md5} muxer.
154
It accepts the following options:
158
Set the number of times to loop the output. Use @code{-1} for no loop, @code{0}
159
for looping indefinitely (default).
162
Force the delay (expressed in centiseconds) after the last frame. Each frame
163
ends with a delay until the next frame. The default is @code{-1}, which is a
164
special value to tell the muxer to re-use the previous delay. In case of a
165
loop, you might want to customize this value to mark a pause for instance.
168
For example, to encode a gif looping 10 times, with a 5 seconds delay between
171
ffmpeg -i INPUT -loop 10 -final_delay 500 out.gif
174
Note 1: if you wish to extract the frames in separate GIF files, you need to
175
force the @ref{image2} muxer:
177
ffmpeg -i INPUT -c:v gif -f image2 "out%d.gif"
180
Note 2: the GIF format has a very small time base: the delay between two frames
181
can not be smaller than one centi second.
152
186
Apple HTTP Live Streaming muxer that segments MPEG-TS according to
153
the HTTP Live Streaming specification.
187
the HTTP Live Streaming (HLS) specification.
155
189
It creates a playlist file and numbered segment files. The output
156
190
filename specifies the playlist filename; the segment filenames
157
191
receive the same basename as the playlist, a sequential number and
194
For example, to convert an input file with @command{ffmpeg}:
161
196
ffmpeg -i in.nut out.m3u8
199
See also the @ref{segment} muxer, which provides a more generic and
200
flexible implementation of a segmenter, and can be used to perform HLS
203
This muxer supports the following options:
165
@item -hls_time @var{seconds}
166
Set the segment length in seconds.
167
@item -hls_list_size @var{size}
168
Set the maximum number of playlist entries.
169
@item -hls_wrap @var{wrap}
170
Set the number after which index wraps.
171
@item -start_number @var{number}
172
Start the sequence from @var{number}.
206
@item hls_time @var{seconds}
207
Set the segment length in seconds. Default value is 2.
209
@item hls_list_size @var{size}
210
Set the maximum number of playlist entries. If set to 0 the list file
211
will contain all the segments. Default value is 5.
213
@item hls_wrap @var{wrap}
214
Set the number after which the segment filename number (the number
215
specified in each segment file) wraps. If set to 0 the number will be
216
never wrapped. Default value is 0.
218
This option is useful to avoid to fill the disk with many segment
219
files, and limits the maximum number of segment files written to disk
222
@item start_number @var{number}
223
Start the playlist sequence number from @var{number}. Default value is
226
Note that the playlist sequence number must be unique for each segment
227
and it is not to be confused with the segment filename sequence number
228
which can be cyclic, for example if the @option{wrap} option is
639
699
Optionally it can generate a list of the created segments, by setting
640
700
the option @var{segment_list}. The list type is specified by the
641
@var{segment_list_type} option.
701
@var{segment_list_type} option. The entry filenames in the segment
702
list are set by default to the basename of the corresponding segment
705
See also the @ref{hls} muxer, which provides a more specific
706
implementation for HLS segmentation.
643
708
The segment muxer supports the following options:
670
735
Allow live-friendly file generation.
673
Default value is @code{samp}.
675
738
@item segment_list_size @var{size}
676
739
Update the list file so that it contains at most the last @var{size}
677
740
segments. If 0 the list file will contain all the segments. Default
743
@item segment_list_entry_prefix @var{prefix}
744
Set @var{prefix} to prepend to the name of each entry filename. By
745
default no prefix is applied.
680
747
@item segment_list_type @var{type}
681
748
Specify the format for the segment list file.
849
916
The slave outputs are specified in the file name given to the muxer,
850
917
separated by '|'. If any of the slave name contains the '|' separator,
851
918
leading or trailing spaces or any special character, it must be
852
escaped (see the ``Quoting and escaping'' section in the ffmpeg-utils
919
escaped (see @ref{quoting_and_escaping,,the "Quoting and escaping"
920
section in the ffmpeg-utils(1) manual,ffmpeg-utils}).
855
922
Muxer options can be specified for each slave by prepending them as a list of
856
923
@var{key}=@var{value} pairs separated by ':', between square brackets. If
866
933
@item bsfs[/@var{spec}]
867
934
Specify a list of bitstream filters to apply to the specified
868
output. It is possible to specify to which streams a given bitstream
869
filter applies, by appending a stream specifier to the option
870
separated by @code{/}. If the stream specifier is not specified, the
937
It is possible to specify to which streams a given bitstream filter
938
applies, by appending a stream specifier to the option separated by
939
@code{/}. @var{spec} must be a stream specifier (see @ref{Format
940
stream specifiers}). If the stream specifier is not specified, the
871
941
bistream filters will be applied to all streams in the output.
873
943
Several bitstream filters can be specified, separated by ",".
899
969
ffmpeg -i ... -map 0 -flags +global_header -c:v libx264 -c:a aac -strict experimental
900
970
-f tee "[bsfs/v=dump_extra]out.ts|[movflags=+faststart]out.mp4|[select=a]out.aac"
974
As below, but select only stream @code{a:1} for the audio output. Note
975
that a second level escaping must be performed, as ":" is a special
976
character used to separate options.
978
ffmpeg -i ... -map 0 -flags +global_header -c:v libx264 -c:a aac -strict experimental
979
-f tee "[bsfs/v=dump_extra]out.ts|[movflags=+faststart]out.mp4|[select=\'a:1\']out.aac"
904
983
Note: some codecs may need different options depending on the output format;