1FFMPEG-FORMATS(1)                                            FFMPEG-FORMATS(1)
2
3
4

NAME

6       ffmpeg-formats - FFmpeg formats
7

DESCRIPTION

9       This document describes the supported formats (muxers and demuxers)
10       provided by the libavformat library.
11

FORMAT OPTIONS

13       The libavformat library provides some generic global options, which can
14       be set on all the muxers and demuxers. In addition each muxer or
15       demuxer may support so-called private options, which are specific for
16       that component.
17
18       Options may be set by specifying -option value in the FFmpeg tools, or
19       by setting the value explicitly in the "AVFormatContext" options or
20       using the libavutil/opt.h API for programmatic use.
21
22       The list of supported options follows:
23
24       avioflags flags (input/output)
25           Possible values:
26
27           direct
28               Reduce buffering.
29
30       probesize integer (input)
31           Set probing size in bytes, i.e. the size of the data to analyze to
32           get stream information. A higher value will enable detecting more
33           information in case it is dispersed into the stream, but will
34           increase latency. Must be an integer not lesser than 32. It is
35           5000000 by default.
36
37       max_probe_packets integer (input)
38           Set the maximum number of buffered packets when probing a codec.
39           Default is 2500 packets.
40
41       packetsize integer (output)
42           Set packet size.
43
44       fflags flags
45           Set format flags. Some are implemented for a limited number of
46           formats.
47
48           Possible values for input files:
49
50           discardcorrupt
51               Discard corrupted packets.
52
53           fastseek
54               Enable fast, but inaccurate seeks for some formats.
55
56           genpts
57               Generate missing PTS if DTS is present.
58
59           igndts
60               Ignore DTS if PTS is set. Inert when nofillin is set.
61
62           ignidx
63               Ignore index.
64
65           nobuffer
66               Reduce the latency introduced by buffering during initial input
67               streams analysis.
68
69           nofillin
70               Do not fill in missing values in packet fields that can be
71               exactly calculated.
72
73           noparse
74               Disable AVParsers, this needs "+nofillin" too.
75
76           sortdts
77               Try to interleave output packets by DTS. At present, available
78               only for AVIs with an index.
79
80           Possible values for output files:
81
82           autobsf
83               Automatically apply bitstream filters as required by the output
84               format. Enabled by default.
85
86           bitexact
87               Only write platform-, build- and time-independent data.  This
88               ensures that file and data checksums are reproducible and match
89               between platforms. Its primary use is for regression testing.
90
91           flush_packets
92               Write out packets immediately.
93
94           shortest
95               Stop muxing at the end of the shortest stream.  It may be
96               needed to increase max_interleave_delta to avoid flushing the
97               longer streams before EOF.
98
99       seek2any integer (input)
100           Allow seeking to non-keyframes on demuxer level when supported if
101           set to 1.  Default is 0.
102
103       analyzeduration integer (input)
104           Specify how many microseconds are analyzed to probe the input. A
105           higher value will enable detecting more accurate information, but
106           will increase latency. It defaults to 5,000,000 microseconds = 5
107           seconds.
108
109       cryptokey hexadecimal string (input)
110           Set decryption key.
111
112       indexmem integer (input)
113           Set max memory used for timestamp index (per stream).
114
115       rtbufsize integer (input)
116           Set max memory used for buffering real-time frames.
117
118       fdebug flags (input/output)
119           Print specific debug info.
120
121           Possible values:
122
123           ts
124       max_delay integer (input/output)
125           Set maximum muxing or demuxing delay in microseconds.
126
127       fpsprobesize integer (input)
128           Set number of frames used to probe fps.
129
130       audio_preload integer (output)
131           Set microseconds by which audio packets should be interleaved
132           earlier.
133
134       chunk_duration integer (output)
135           Set microseconds for each chunk.
136
137       chunk_size integer (output)
138           Set size in bytes for each chunk.
139
140       err_detect, f_err_detect flags (input)
141           Set error detection flags. "f_err_detect" is deprecated and should
142           be used only via the ffmpeg tool.
143
144           Possible values:
145
146           crccheck
147               Verify embedded CRCs.
148
149           bitstream
150               Detect bitstream specification deviations.
151
152           buffer
153               Detect improper bitstream length.
154
155           explode
156               Abort decoding on minor error detection.
157
158           careful
159               Consider things that violate the spec and have not been seen in
160               the wild as errors.
161
162           compliant
163               Consider all spec non compliancies as errors.
164
165           aggressive
166               Consider things that a sane encoder should not do as an error.
167
168       max_interleave_delta integer (output)
169           Set maximum buffering duration for interleaving. The duration is
170           expressed in microseconds, and defaults to 10000000 (10 seconds).
171
172           To ensure all the streams are interleaved correctly, libavformat
173           will wait until it has at least one packet for each stream before
174           actually writing any packets to the output file. When some streams
175           are "sparse" (i.e. there are large gaps between successive
176           packets), this can result in excessive buffering.
177
178           This field specifies the maximum difference between the timestamps
179           of the first and the last packet in the muxing queue, above which
180           libavformat will output a packet regardless of whether it has
181           queued a packet for all the streams.
182
183           If set to 0, libavformat will continue buffering packets until it
184           has a packet for each stream, regardless of the maximum timestamp
185           difference between the buffered packets.
186
187       use_wallclock_as_timestamps integer (input)
188           Use wallclock as timestamps if set to 1. Default is 0.
189
190       avoid_negative_ts integer (output)
191           Possible values:
192
193           make_non_negative
194               Shift timestamps to make them non-negative.  Also note that
195               this affects only leading negative timestamps, and not non-
196               monotonic negative timestamps.
197
198           make_zero
199               Shift timestamps so that the first timestamp is 0.
200
201           auto (default)
202               Enables shifting when required by the target format.
203
204           disabled
205               Disables shifting of timestamp.
206
207           When shifting is enabled, all output timestamps are shifted by the
208           same amount. Audio, video, and subtitles desynching and relative
209           timestamp differences are preserved compared to how they would have
210           been without shifting.
211
212       skip_initial_bytes integer (input)
213           Set number of bytes to skip before reading header and frames if set
214           to 1.  Default is 0.
215
216       correct_ts_overflow integer (input)
217           Correct single timestamp overflows if set to 1. Default is 1.
218
219       flush_packets integer (output)
220           Flush the underlying I/O stream after each packet. Default is -1
221           (auto), which means that the underlying protocol will decide, 1
222           enables it, and has the effect of reducing the latency, 0 disables
223           it and may increase IO throughput in some cases.
224
225       output_ts_offset offset (output)
226           Set the output time offset.
227
228           offset must be a time duration specification, see the Time duration
229           section in the ffmpeg-utils(1) manual.
230
231           The offset is added by the muxer to the output timestamps.
232
233           Specifying a positive offset means that the corresponding streams
234           are delayed bt the time duration specified in offset. Default value
235           is 0 (meaning that no offset is applied).
236
237       format_whitelist list (input)
238           "," separated list of allowed demuxers. By default all are allowed.
239
240       dump_separator string (input)
241           Separator used to separate the fields printed on the command line
242           about the Stream parameters.  For example, to separate the fields
243           with newlines and indentation:
244
245                   ffprobe -dump_separator "
246                                             "  -i ~/videos/matrixbench_mpeg2.mpg
247
248       max_streams integer (input)
249           Specifies the maximum number of streams. This can be used to reject
250           files that would require too many resources due to a large number
251           of streams.
252
253       skip_estimate_duration_from_pts bool (input)
254           Skip estimation of input duration when calculated using PTS.  At
255           present, applicable for MPEG-PS and MPEG-TS.
256
257       strict, f_strict integer (input/output)
258           Specify how strictly to follow the standards. "f_strict" is
259           deprecated and should be used only via the ffmpeg tool.
260
261           Possible values:
262
263           very
264               strictly conform to an older more strict version of the spec or
265               reference software
266
267           strict
268               strictly conform to all the things in the spec no matter what
269               consequences
270
271           normal
272           unofficial
273               allow unofficial extensions
274
275           experimental
276               allow non standardized experimental things, experimental
277               (unfinished/work in progress/not well tested) decoders and
278               encoders.  Note: experimental decoders can pose a security
279               risk, do not use this for decoding untrusted input.
280
281   Format stream specifiers
282       Format stream specifiers allow selection of one or more streams that
283       match specific properties.
284
285       The exact semantics of stream specifiers is defined by the
286       avformat_match_stream_specifier() function declared in the
287       libavformat/avformat.h header and documented in the Stream specifiers
288       section in the ffmpeg(1) manual.
289

DEMUXERS

291       Demuxers are configured elements in FFmpeg that can read the multimedia
292       streams from a particular type of file.
293
294       When you configure your FFmpeg build, all the supported demuxers are
295       enabled by default. You can list all available ones using the configure
296       option "--list-demuxers".
297
298       You can disable all the demuxers using the configure option
299       "--disable-demuxers", and selectively enable a single demuxer with the
300       option "--enable-demuxer=DEMUXER", or disable it with the option
301       "--disable-demuxer=DEMUXER".
302
303       The option "-demuxers" of the ff* tools will display the list of
304       enabled demuxers. Use "-formats" to view a combined list of enabled
305       demuxers and muxers.
306
307       The description of some of the currently available demuxers follows.
308
309   aa
310       Audible Format 2, 3, and 4 demuxer.
311
312       This demuxer is used to demux Audible Format 2, 3, and 4 (.aa) files.
313
314   aac
315       Raw Audio Data Transport Stream AAC demuxer.
316
317       This demuxer is used to demux an ADTS input containing a single AAC
318       stream alongwith any ID3v1/2 or APE tags in it.
319
320   apng
321       Animated Portable Network Graphics demuxer.
322
323       This demuxer is used to demux APNG files.  All headers, but the PNG
324       signature, up to (but not including) the first fcTL chunk are
325       transmitted as extradata.  Frames are then split as being all the
326       chunks between two fcTL ones, or between the last fcTL and IEND chunks.
327
328       -ignore_loop bool
329           Ignore the loop variable in the file if set. Default is enabled.
330
331       -max_fps int
332           Maximum framerate in frames per second. Default of 0 imposes no
333           limit.
334
335       -default_fps int
336           Default framerate in frames per second when none is specified in
337           the file (0 meaning as fast as possible). Default is 15.
338
339   asf
340       Advanced Systems Format demuxer.
341
342       This demuxer is used to demux ASF files and MMS network streams.
343
344       -no_resync_search bool
345           Do not try to resynchronize by looking for a certain optional start
346           code.
347
348   concat
349       Virtual concatenation script demuxer.
350
351       This demuxer reads a list of files and other directives from a text
352       file and demuxes them one after the other, as if all their packets had
353       been muxed together.
354
355       The timestamps in the files are adjusted so that the first file starts
356       at 0 and each next file starts where the previous one finishes. Note
357       that it is done globally and may cause gaps if all streams do not have
358       exactly the same length.
359
360       All files must have the same streams (same codecs, same time base,
361       etc.).
362
363       The duration of each file is used to adjust the timestamps of the next
364       file: if the duration is incorrect (because it was computed using the
365       bit-rate or because the file is truncated, for example), it can cause
366       artifacts. The "duration" directive can be used to override the
367       duration stored in each file.
368
369       Syntax
370
371       The script is a text file in extended-ASCII, with one directive per
372       line.  Empty lines, leading spaces and lines starting with '#' are
373       ignored. The following directive is recognized:
374
375       "file path"
376           Path to a file to read; special characters and spaces must be
377           escaped with backslash or single quotes.
378
379           All subsequent file-related directives apply to that file.
380
381       "ffconcat version 1.0"
382           Identify the script type and version.
383
384           To make FFmpeg recognize the format automatically, this directive
385           must appear exactly as is (no extra space or byte-order-mark) on
386           the very first line of the script.
387
388       "duration dur"
389           Duration of the file. This information can be specified from the
390           file; specifying it here may be more efficient or help if the
391           information from the file is not available or accurate.
392
393           If the duration is set for all files, then it is possible to seek
394           in the whole concatenated video.
395
396       "inpoint timestamp"
397           In point of the file. When the demuxer opens the file it instantly
398           seeks to the specified timestamp. Seeking is done so that all
399           streams can be presented successfully at In point.
400
401           This directive works best with intra frame codecs, because for non-
402           intra frame ones you will usually get extra packets before the
403           actual In point and the decoded content will most likely contain
404           frames before In point too.
405
406           For each file, packets before the file In point will have
407           timestamps less than the calculated start timestamp of the file
408           (negative in case of the first file), and the duration of the files
409           (if not specified by the "duration" directive) will be reduced
410           based on their specified In point.
411
412           Because of potential packets before the specified In point, packet
413           timestamps may overlap between two concatenated files.
414
415       "outpoint timestamp"
416           Out point of the file. When the demuxer reaches the specified
417           decoding timestamp in any of the streams, it handles it as an end
418           of file condition and skips the current and all the remaining
419           packets from all streams.
420
421           Out point is exclusive, which means that the demuxer will not
422           output packets with a decoding timestamp greater or equal to Out
423           point.
424
425           This directive works best with intra frame codecs and formats where
426           all streams are tightly interleaved. For non-intra frame codecs you
427           will usually get additional packets with presentation timestamp
428           after Out point therefore the decoded content will most likely
429           contain frames after Out point too. If your streams are not tightly
430           interleaved you may not get all the packets from all streams before
431           Out point and you may only will be able to decode the earliest
432           stream until Out point.
433
434           The duration of the files (if not specified by the "duration"
435           directive) will be reduced based on their specified Out point.
436
437       "file_packet_metadata key=value"
438           Metadata of the packets of the file. The specified metadata will be
439           set for each file packet. You can specify this directive multiple
440           times to add multiple metadata entries.  This directive is
441           deprecated, use "file_packet_meta" instead.
442
443       "file_packet_meta key value"
444           Metadata of the packets of the file. The specified metadata will be
445           set for each file packet. You can specify this directive multiple
446           times to add multiple metadata entries.
447
448       "option key value"
449           Option to access, open and probe the file.  Can be present multiple
450           times.
451
452       "stream"
453           Introduce a stream in the virtual file.  All subsequent stream-
454           related directives apply to the last introduced stream.  Some
455           streams properties must be set in order to allow identifying the
456           matching streams in the subfiles.  If no streams are defined in the
457           script, the streams from the first file are copied.
458
459       "exact_stream_id id"
460           Set the id of the stream.  If this directive is given, the string
461           with the corresponding id in the subfiles will be used.  This is
462           especially useful for MPEG-PS (VOB) files, where the order of the
463           streams is not reliable.
464
465       "stream_meta key value"
466           Metadata for the stream.  Can be present multiple times.
467
468       "stream_codec value"
469           Codec for the stream.
470
471       "stream_extradata hex_string"
472           Extradata for the string, encoded in hexadecimal.
473
474       "chapter id start end"
475           Add a chapter. id is an unique identifier, possibly small and
476           consecutive.
477
478       Options
479
480       This demuxer accepts the following option:
481
482       safe
483           If set to 1, reject unsafe file paths and directives.  A file path
484           is considered safe if it does not contain a protocol specification
485           and is relative and all components only contain characters from the
486           portable character set (letters, digits, period, underscore and
487           hyphen) and have no period at the beginning of a component.
488
489           If set to 0, any file name is accepted.
490
491           The default is 1.
492
493       auto_convert
494           If set to 1, try to perform automatic conversions on packet data to
495           make the streams concatenable.  The default is 1.
496
497           Currently, the only conversion is adding the h264_mp4toannexb
498           bitstream filter to H.264 streams in MP4 format. This is necessary
499           in particular if there are resolution changes.
500
501       segment_time_metadata
502           If set to 1, every packet will contain the lavf.concat.start_time
503           and the lavf.concat.duration packet metadata values which are the
504           start_time and the duration of the respective file segments in the
505           concatenated output expressed in microseconds. The duration
506           metadata is only set if it is known based on the concat file.  The
507           default is 0.
508
509       Examples
510
511       •   Use absolute filenames and include some comments:
512
513                   # my first filename
514                   file /mnt/share/file-1.wav
515                   # my second filename including whitespace
516                   file '/mnt/share/file 2.wav'
517                   # my third filename including whitespace plus single quote
518                   file '/mnt/share/file 3'\''.wav'
519
520       •   Allow for input format auto-probing, use safe filenames and set the
521           duration of the first file:
522
523                   ffconcat version 1.0
524
525                   file file-1.wav
526                   duration 20.0
527
528                   file subdir/file-2.wav
529
530   dash
531       Dynamic Adaptive Streaming over HTTP demuxer.
532
533       This demuxer presents all AVStreams found in the manifest.  By setting
534       the discard flags on AVStreams the caller can decide which streams to
535       actually receive.  Each stream mirrors the "id" and "bandwidth"
536       properties from the "<Representation>" as metadata keys named "id" and
537       "variant_bitrate" respectively.
538
539       Options
540
541       This demuxer accepts the following option:
542
543       cenc_decryption_key
544           16-byte key, in hex, to decrypt files encrypted using ISO Common
545           Encryption (CENC/AES-128 CTR; ISO/IEC 23001-7).
546
547   ea
548       Electronic Arts Multimedia format demuxer.
549
550       This format is used by various Electronic Arts games.
551
552       Options
553
554       merge_alpha bool
555           Normally the VP6 alpha channel (if exists) is returned as a
556           secondary video stream, by setting this option you can make the
557           demuxer return a single video stream which contains the alpha
558           channel in addition to the ordinary video.
559
560   imf
561       Interoperable Master Format demuxer.
562
563       This demuxer presents audio and video streams found in an IMF
564       Composition.
565
566   flv, live_flv, kux
567       Adobe Flash Video Format demuxer.
568
569       This demuxer is used to demux FLV files and RTMP network streams. In
570       case of live network streams, if you force format, you may use live_flv
571       option instead of flv to survive timestamp discontinuities.  KUX is a
572       flv variant used on the Youku platform.
573
574               ffmpeg -f flv -i myfile.flv ...
575               ffmpeg -f live_flv -i rtmp://<any.server>/anything/key ....
576
577       -flv_metadata bool
578           Allocate the streams according to the onMetaData array content.
579
580       -flv_ignore_prevtag bool
581           Ignore the size of previous tag value.
582
583       -flv_full_metadata bool
584           Output all context of the onMetadata.
585
586   gif
587       Animated GIF demuxer.
588
589       It accepts the following options:
590
591       min_delay
592           Set the minimum valid delay between frames in hundredths of
593           seconds.  Range is 0 to 6000. Default value is 2.
594
595       max_gif_delay
596           Set the maximum valid delay between frames in hundredth of seconds.
597           Range is 0 to 65535. Default value is 65535 (nearly eleven
598           minutes), the maximum value allowed by the specification.
599
600       default_delay
601           Set the default delay between frames in hundredths of seconds.
602           Range is 0 to 6000. Default value is 10.
603
604       ignore_loop
605           GIF files can contain information to loop a certain number of times
606           (or infinitely). If ignore_loop is set to 1, then the loop setting
607           from the input will be ignored and looping will not occur. If set
608           to 0, then looping will occur and will cycle the number of times
609           according to the GIF. Default value is 1.
610
611       For example, with the overlay filter, place an infinitely looping GIF
612       over another video:
613
614               ffmpeg -i input.mp4 -ignore_loop 0 -i input.gif -filter_complex overlay=shortest=1 out.mkv
615
616       Note that in the above example the shortest option for overlay filter
617       is used to end the output video at the length of the shortest input
618       file, which in this case is input.mp4 as the GIF in this example loops
619       infinitely.
620
621   hls
622       HLS demuxer
623
624       Apple HTTP Live Streaming demuxer.
625
626       This demuxer presents all AVStreams from all variant streams.  The id
627       field is set to the bitrate variant index number. By setting the
628       discard flags on AVStreams (by pressing 'a' or 'v' in ffplay), the
629       caller can decide which variant streams to actually receive.  The total
630       bitrate of the variant that the stream belongs to is available in a
631       metadata key named "variant_bitrate".
632
633       It accepts the following options:
634
635       live_start_index
636           segment index to start live streams at (negative values are from
637           the end).
638
639       prefer_x_start
640           prefer to use #EXT-X-START if it's in playlist instead of
641           live_start_index.
642
643       allowed_extensions
644           ',' separated list of file extensions that hls is allowed to
645           access.
646
647       max_reload
648           Maximum number of times a insufficient list is attempted to be
649           reloaded.  Default value is 1000.
650
651       m3u8_hold_counters
652           The maximum number of times to load m3u8 when it refreshes without
653           new segments.  Default value is 1000.
654
655       http_persistent
656           Use persistent HTTP connections. Applicable only for HTTP streams.
657           Enabled by default.
658
659       http_multiple
660           Use multiple HTTP connections for downloading HTTP segments.
661           Enabled by default for HTTP/1.1 servers.
662
663       http_seekable
664           Use HTTP partial requests for downloading HTTP segments.  0 =
665           disable, 1 = enable, -1 = auto, Default is auto.
666
667       seg_format_options
668           Set options for the demuxer of media segments using a list of
669           key=value pairs separated by ":".
670
671       seg_max_retry
672           Maximum number of times to reload a segment on error, useful when
673           segment skip on network error is not desired.  Default value is 0.
674
675   image2
676       Image file demuxer.
677
678       This demuxer reads from a list of image files specified by a pattern.
679       The syntax and meaning of the pattern is specified by the option
680       pattern_type.
681
682       The pattern may contain a suffix which is used to automatically
683       determine the format of the images contained in the files.
684
685       The size, the pixel format, and the format of each image must be the
686       same for all the files in the sequence.
687
688       This demuxer accepts the following options:
689
690       framerate
691           Set the frame rate for the video stream. It defaults to 25.
692
693       loop
694           If set to 1, loop over the input. Default value is 0.
695
696       pattern_type
697           Select the pattern type used to interpret the provided filename.
698
699           pattern_type accepts one of the following values.
700
701           none
702               Disable pattern matching, therefore the video will only contain
703               the specified image. You should use this option if you do not
704               want to create sequences from multiple images and your
705               filenames may contain special pattern characters.
706
707           sequence
708               Select a sequence pattern type, used to specify a sequence of
709               files indexed by sequential numbers.
710
711               A sequence pattern may contain the string "%d" or "%0Nd", which
712               specifies the position of the characters representing a
713               sequential number in each filename matched by the pattern. If
714               the form "%d0Nd" is used, the string representing the number in
715               each filename is 0-padded and N is the total number of 0-padded
716               digits representing the number. The literal character '%' can
717               be specified in the pattern with the string "%%".
718
719               If the sequence pattern contains "%d" or "%0Nd", the first
720               filename of the file list specified by the pattern must contain
721               a number inclusively contained between start_number and
722               start_number+start_number_range-1, and all the following
723               numbers must be sequential.
724
725               For example the pattern "img-%03d.bmp" will match a sequence of
726               filenames of the form img-001.bmp, img-002.bmp, ...,
727               img-010.bmp, etc.; the pattern "i%%m%%g-%d.jpg" will match a
728               sequence of filenames of the form i%m%g-1.jpg, i%m%g-2.jpg,
729               ..., i%m%g-10.jpg, etc.
730
731               Note that the pattern must not necessarily contain "%d" or
732               "%0Nd", for example to convert a single image file img.jpeg you
733               can employ the command:
734
735                       ffmpeg -i img.jpeg img.png
736
737           glob
738               Select a glob wildcard pattern type.
739
740               The pattern is interpreted like a glob() pattern. This is only
741               selectable if libavformat was compiled with globbing support.
742
743           glob_sequence (deprecated, will be removed)
744               Select a mixed glob wildcard/sequence pattern.
745
746               If your version of libavformat was compiled with globbing
747               support, and the provided pattern contains at least one glob
748               meta character among "%*?[]{}" that is preceded by an unescaped
749               "%", the pattern is interpreted like a glob() pattern,
750               otherwise it is interpreted like a sequence pattern.
751
752               All glob special characters "%*?[]{}" must be prefixed with
753               "%". To escape a literal "%" you shall use "%%".
754
755               For example the pattern "foo-%*.jpeg" will match all the
756               filenames prefixed by "foo-" and terminating with ".jpeg", and
757               "foo-%?%?%?.jpeg" will match all the filenames prefixed with
758               "foo-", followed by a sequence of three characters, and
759               terminating with ".jpeg".
760
761               This pattern type is deprecated in favor of glob and sequence.
762
763           Default value is glob_sequence.
764
765       pixel_format
766           Set the pixel format of the images to read. If not specified the
767           pixel format is guessed from the first image file in the sequence.
768
769       start_number
770           Set the index of the file matched by the image file pattern to
771           start to read from. Default value is 0.
772
773       start_number_range
774           Set the index interval range to check when looking for the first
775           image file in the sequence, starting from start_number. Default
776           value is 5.
777
778       ts_from_file
779           If set to 1, will set frame timestamp to modification time of image
780           file. Note that monotonity of timestamps is not provided: images go
781           in the same order as without this option. Default value is 0.  If
782           set to 2, will set frame timestamp to the modification time of the
783           image file in nanosecond precision.
784
785       video_size
786           Set the video size of the images to read. If not specified the
787           video size is guessed from the first image file in the sequence.
788
789       export_path_metadata
790           If set to 1, will add two extra fields to the metadata found in
791           input, making them also available for other filters (see drawtext
792           filter for examples). Default value is 0. The extra fields are
793           described below:
794
795           lavf.image2dec.source_path
796               Corresponds to the full path to the input file being read.
797
798           lavf.image2dec.source_basename
799               Corresponds to the name of the file being read.
800
801       Examples
802
803       •   Use ffmpeg for creating a video from the images in the file
804           sequence img-001.jpeg, img-002.jpeg, ..., assuming an input frame
805           rate of 10 frames per second:
806
807                   ffmpeg -framerate 10 -i 'img-%03d.jpeg' out.mkv
808
809       •   As above, but start by reading from a file with index 100 in the
810           sequence:
811
812                   ffmpeg -framerate 10 -start_number 100 -i 'img-%03d.jpeg' out.mkv
813
814       •   Read images matching the "*.png" glob pattern , that is all the
815           files terminating with the ".png" suffix:
816
817                   ffmpeg -framerate 10 -pattern_type glob -i "*.png" out.mkv
818
819   libgme
820       The Game Music Emu library is a collection of video game music file
821       emulators.
822
823       See <https://bitbucket.org/mpyne/game-music-emu/overview> for more
824       information.
825
826       It accepts the following options:
827
828       track_index
829           Set the index of which track to demux. The demuxer can only export
830           one track.  Track indexes start at 0. Default is to pick the first
831           track. Number of tracks is exported as tracks metadata entry.
832
833       sample_rate
834           Set the sampling rate of the exported track. Range is 1000 to
835           999999. Default is 44100.
836
837       max_size (bytes)
838           The demuxer buffers the entire file into memory. Adjust this value
839           to set the maximum buffer size, which in turn, acts as a ceiling
840           for the size of files that can be read.  Default is 50 MiB.
841
842   libmodplug
843       ModPlug based module demuxer
844
845       See <https://github.com/Konstanty/libmodplug>
846
847       It will export one 2-channel 16-bit 44.1 kHz audio stream.  Optionally,
848       a "pal8" 16-color video stream can be exported with or without printed
849       metadata.
850
851       It accepts the following options:
852
853       noise_reduction
854           Apply a simple low-pass filter. Can be 1 (on) or 0 (off). Default
855           is 0.
856
857       reverb_depth
858           Set amount of reverb. Range 0-100. Default is 0.
859
860       reverb_delay
861           Set delay in ms, clamped to 40-250 ms. Default is 0.
862
863       bass_amount
864           Apply bass expansion a.k.a. XBass or megabass. Range is 0 (quiet)
865           to 100 (loud). Default is 0.
866
867       bass_range
868           Set cutoff i.e. upper-bound for bass frequencies. Range is 10-100
869           Hz. Default is 0.
870
871       surround_depth
872           Apply a Dolby Pro-Logic surround effect. Range is 0 (quiet) to 100
873           (heavy). Default is 0.
874
875       surround_delay
876           Set surround delay in ms, clamped to 5-40 ms. Default is 0.
877
878       max_size
879           The demuxer buffers the entire file into memory. Adjust this value
880           to set the maximum buffer size, which in turn, acts as a ceiling
881           for the size of files that can be read. Range is 0 to 100 MiB.  0
882           removes buffer size limit (not recommended). Default is 5 MiB.
883
884       video_stream_expr
885           String which is evaluated using the eval API to assign colors to
886           the generated video stream.  Variables which can be used are "x",
887           "y", "w", "h", "t", "speed", "tempo", "order", "pattern" and "row".
888
889       video_stream
890           Generate video stream. Can be 1 (on) or 0 (off). Default is 0.
891
892       video_stream_w
893           Set video frame width in 'chars' where one char indicates 8 pixels.
894           Range is 20-512. Default is 30.
895
896       video_stream_h
897           Set video frame height in 'chars' where one char indicates 8
898           pixels. Range is 20-512. Default is 30.
899
900       video_stream_ptxt
901           Print metadata on video stream. Includes "speed", "tempo", "order",
902           "pattern", "row" and "ts" (time in ms). Can be 1 (on) or 0 (off).
903           Default is 1.
904
905   libopenmpt
906       libopenmpt based module demuxer
907
908       See <https://lib.openmpt.org/libopenmpt/> for more information.
909
910       Some files have multiple subsongs (tracks) this can be set with the
911       subsong option.
912
913       It accepts the following options:
914
915       subsong
916           Set the subsong index. This can be either  'all', 'auto', or the
917           index of the subsong. Subsong indexes start at 0. The default is
918           'auto'.
919
920           The default value is to let libopenmpt choose.
921
922       layout
923           Set the channel layout. Valid values are 1, 2, and 4 channel
924           layouts.  The default value is STEREO.
925
926       sample_rate
927           Set the sample rate for libopenmpt to output.  Range is from 1000
928           to INT_MAX. The value default is 48000.
929
930   mov/mp4/3gp
931       Demuxer for Quicktime File Format & ISO/IEC Base Media File Format
932       (ISO/IEC 14496-12 or MPEG-4 Part 12, ISO/IEC 15444-12 or JPEG 2000 Part
933       12).
934
935       Registered extensions: mov, mp4, m4a, 3gp, 3g2, mj2, psp, m4b, ism,
936       ismv, isma, f4v
937
938       Options
939
940       This demuxer accepts the following options:
941
942       enable_drefs
943           Enable loading of external tracks, disabled by default.  Enabling
944           this can theoretically leak information in some use cases.
945
946       use_absolute_path
947           Allows loading of external tracks via absolute paths, disabled by
948           default.  Enabling this poses a security risk. It should only be
949           enabled if the source is known to be non-malicious.
950
951       seek_streams_individually
952           When seeking, identify the closest point in each stream
953           individually and demux packets in that stream from identified
954           point. This can lead to a different sequence of packets compared to
955           demuxing linearly from the beginning. Default is true.
956
957       ignore_editlist
958           Ignore any edit list atoms. The demuxer, by default, modifies the
959           stream index to reflect the timeline described by the edit list.
960           Default is false.
961
962       advanced_editlist
963           Modify the stream index to reflect the timeline described by the
964           edit list. "ignore_editlist" must be set to false for this option
965           to be effective.  If both "ignore_editlist" and this option are set
966           to false, then only the start of the stream index is modified to
967           reflect initial dwell time or starting timestamp described by the
968           edit list. Default is true.
969
970       ignore_chapters
971           Don't parse chapters. This includes GoPro 'HiLight' tags/moments.
972           Note that chapters are only parsed when input is seekable. Default
973           is false.
974
975       use_mfra_for
976           For seekable fragmented input, set fragment's starting timestamp
977           from media fragment random access box, if present.
978
979           Following options are available:
980
981           auto
982               Auto-detect whether to set mfra timestamps as PTS or DTS
983               (default)
984
985           dts Set mfra timestamps as DTS
986
987           pts Set mfra timestamps as PTS
988
989           0   Don't use mfra box to set timestamps
990
991       use_tfdt
992           For fragmented input, set fragment's starting timestamp to
993           "baseMediaDecodeTime" from the "tfdt" box.  Default is enabled,
994           which will prefer to use the "tfdt" box to set DTS. Disable to use
995           the "earliest_presentation_time" from the "sidx" box.  In either
996           case, the timestamp from the "mfra" box will be used if it's
997           available and "use_mfra_for" is set to pts or dts.
998
999       export_all
1000           Export unrecognized boxes within the udta box as metadata entries.
1001           The first four characters of the box type are set as the key.
1002           Default is false.
1003
1004       export_xmp
1005           Export entire contents of XMP_ box and uuid box as a string with
1006           key "xmp". Note that if "export_all" is set and this option isn't,
1007           the contents of XMP_ box are still exported but with key "XMP_".
1008           Default is false.
1009
1010       activation_bytes
1011           4-byte key required to decrypt Audible AAX and AAX+ files. See
1012           Audible AAX subsection below.
1013
1014       audible_fixed_key
1015           Fixed key used for handling Audible AAX/AAX+ files. It has been
1016           pre-set so should not be necessary to specify.
1017
1018       decryption_key
1019           16-byte key, in hex, to decrypt files encrypted using ISO Common
1020           Encryption (CENC/AES-128 CTR; ISO/IEC 23001-7).
1021
1022       max_stts_delta
1023           Very high sample deltas written in a trak's stts box may
1024           occasionally be intended but usually they are written in error or
1025           used to store a negative value for dts correction when treated as
1026           signed 32-bit integers. This option lets the user set an upper
1027           limit, beyond which the delta is clamped to 1. Values greater than
1028           the limit if negative when cast to int32 are used to adjust onward
1029           dts.
1030
1031           Unit is the track time scale. Range is 0 to UINT_MAX. Default is
1032           "UINT_MAX - 48000*10" which allows upto a 10 second dts correction
1033           for 48 kHz audio streams while accommodating 99.9% of "uint32"
1034           range.
1035
1036       Audible AAX
1037
1038       Audible AAX files are encrypted M4B files, and they can be decrypted by
1039       specifying a 4 byte activation secret.
1040
1041               ffmpeg -activation_bytes 1CEB00DA -i test.aax -vn -c:a copy output.mp4
1042
1043   mpegts
1044       MPEG-2 transport stream demuxer.
1045
1046       This demuxer accepts the following options:
1047
1048       resync_size
1049           Set size limit for looking up a new synchronization. Default value
1050           is 65536.
1051
1052       skip_unknown_pmt
1053           Skip PMTs for programs not defined in the PAT. Default value is 0.
1054
1055       fix_teletext_pts
1056           Override teletext packet PTS and DTS values with the timestamps
1057           calculated from the PCR of the first program which the teletext
1058           stream is part of and is not discarded. Default value is 1, set
1059           this option to 0 if you want your teletext packet PTS and DTS
1060           values untouched.
1061
1062       ts_packetsize
1063           Output option carrying the raw packet size in bytes.  Show the
1064           detected raw packet size, cannot be set by the user.
1065
1066       scan_all_pmts
1067           Scan and combine all PMTs. The value is an integer with value from
1068           -1 to 1 (-1 means automatic setting, 1 means enabled, 0 means
1069           disabled). Default value is -1.
1070
1071       merge_pmt_versions
1072           Re-use existing streams when a PMT's version is updated and
1073           elementary streams move to different PIDs. Default value is 0.
1074
1075       max_packet_size
1076           Set maximum size, in bytes, of packet emitted by the demuxer.
1077           Payloads above this size are split across multiple packets. Range
1078           is 1 to INT_MAX/2. Default is 204800 bytes.
1079
1080   mpjpeg
1081       MJPEG encapsulated in multi-part MIME demuxer.
1082
1083       This demuxer allows reading of MJPEG, where each frame is represented
1084       as a part of multipart/x-mixed-replace stream.
1085
1086       strict_mime_boundary
1087           Default implementation applies a relaxed standard to multi-part
1088           MIME boundary detection, to prevent regression with numerous
1089           existing endpoints not generating a proper MIME MJPEG stream.
1090           Turning this option on by setting it to 1 will result in a stricter
1091           check of the boundary value.
1092
1093   rawvideo
1094       Raw video demuxer.
1095
1096       This demuxer allows one to read raw video data. Since there is no
1097       header specifying the assumed video parameters, the user must specify
1098       them in order to be able to decode the data correctly.
1099
1100       This demuxer accepts the following options:
1101
1102       framerate
1103           Set input video frame rate. Default value is 25.
1104
1105       pixel_format
1106           Set the input video pixel format. Default value is "yuv420p".
1107
1108       video_size
1109           Set the input video size. This value must be specified explicitly.
1110
1111       For example to read a rawvideo file input.raw with ffplay, assuming a
1112       pixel format of "rgb24", a video size of "320x240", and a frame rate of
1113       10 images per second, use the command:
1114
1115               ffplay -f rawvideo -pixel_format rgb24 -video_size 320x240 -framerate 10 input.raw
1116
1117   sbg
1118       SBaGen script demuxer.
1119
1120       This demuxer reads the script language used by SBaGen
1121       <http://uazu.net/sbagen/> to generate binaural beats sessions. A SBG
1122       script looks like that:
1123
1124               -SE
1125               a: 300-2.5/3 440+4.5/0
1126               b: 300-2.5/0 440+4.5/3
1127               off: -
1128               NOW      == a
1129               +0:07:00 == b
1130               +0:14:00 == a
1131               +0:21:00 == b
1132               +0:30:00    off
1133
1134       A SBG script can mix absolute and relative timestamps. If the script
1135       uses either only absolute timestamps (including the script start time)
1136       or only relative ones, then its layout is fixed, and the conversion is
1137       straightforward. On the other hand, if the script mixes both kind of
1138       timestamps, then the NOW reference for relative timestamps will be
1139       taken from the current time of day at the time the script is read, and
1140       the script layout will be frozen according to that reference. That
1141       means that if the script is directly played, the actual times will
1142       match the absolute timestamps up to the sound controller's clock
1143       accuracy, but if the user somehow pauses the playback or seeks, all
1144       times will be shifted accordingly.
1145
1146   tedcaptions
1147       JSON captions used for <http://www.ted.com/>.
1148
1149       TED does not provide links to the captions, but they can be guessed
1150       from the page. The file tools/bookmarklets.html from the FFmpeg source
1151       tree contains a bookmarklet to expose them.
1152
1153       This demuxer accepts the following option:
1154
1155       start_time
1156           Set the start time of the TED talk, in milliseconds. The default is
1157           15000 (15s). It is used to sync the captions with the downloadable
1158           videos, because they include a 15s intro.
1159
1160       Example: convert the captions to a format most players understand:
1161
1162               ffmpeg -i http://www.ted.com/talks/subtitles/id/1/lang/en talk1-en.srt
1163
1164   vapoursynth
1165       Vapoursynth wrapper.
1166
1167       Due to security concerns, Vapoursynth scripts will not be autodetected
1168       so the input format has to be forced. For ff* CLI tools, add "-f
1169       vapoursynth" before the input "-i yourscript.vpy".
1170
1171       This demuxer accepts the following option:
1172
1173       max_script_size
1174           The demuxer buffers the entire script into memory. Adjust this
1175           value to set the maximum buffer size, which in turn, acts as a
1176           ceiling for the size of scripts that can be read.  Default is 1
1177           MiB.
1178

MUXERS

1180       Muxers are configured elements in FFmpeg which allow writing multimedia
1181       streams to a particular type of file.
1182
1183       When you configure your FFmpeg build, all the supported muxers are
1184       enabled by default. You can list all available muxers using the
1185       configure option "--list-muxers".
1186
1187       You can disable all the muxers with the configure option
1188       "--disable-muxers" and selectively enable / disable single muxers with
1189       the options "--enable-muxer=MUXER" / "--disable-muxer=MUXER".
1190
1191       The option "-muxers" of the ff* tools will display the list of enabled
1192       muxers. Use "-formats" to view a combined list of enabled demuxers and
1193       muxers.
1194
1195       A description of some of the currently available muxers follows.
1196
1197   a64
1198       A64 muxer for Commodore 64 video. Accepts a single "a64_multi" or
1199       "a64_multi5" codec video stream.
1200
1201   adts
1202       Audio Data Transport Stream muxer. It accepts a single AAC stream.
1203
1204       Options
1205
1206       It accepts the following options:
1207
1208       write_id3v2 bool
1209           Enable to write ID3v2.4 tags at the start of the stream. Default is
1210           disabled.
1211
1212       write_apetag bool
1213           Enable to write APE tags at the end of the stream. Default is
1214           disabled.
1215
1216       write_mpeg2 bool
1217           Enable to set MPEG version bit in the ADTS frame header to 1 which
1218           indicates MPEG-2. Default is 0, which indicates MPEG-4.
1219
1220   aiff
1221       Audio Interchange File Format muxer.
1222
1223       Options
1224
1225       It accepts the following options:
1226
1227       write_id3v2
1228           Enable ID3v2 tags writing when set to 1. Default is 0 (disabled).
1229
1230       id3v2_version
1231           Select ID3v2 version to write. Currently only version 3 and 4 (aka.
1232           ID3v2.3 and ID3v2.4) are supported. The default is version 4.
1233
1234   alp
1235       Muxer for audio of High Voltage Software's Lego Racers game. It accepts
1236       a single ADPCM_IMA_ALP stream with no more than 2 channels nor a sample
1237       rate greater than 44100 Hz.
1238
1239       Extensions: tun, pcm
1240
1241       Options
1242
1243       It accepts the following options:
1244
1245       type type
1246           Set file type.
1247
1248           tun Set file type as music. Must have a sample rate of 22050 Hz.
1249
1250           pcm Set file type as sfx.
1251
1252           auto
1253               Set file type as per output file extension. ".pcm" results in
1254               type "pcm" else type "tun" is set. (default)
1255
1256   asf
1257       Advanced Systems Format muxer.
1258
1259       Note that Windows Media Audio (wma) and Windows Media Video (wmv) use
1260       this muxer too.
1261
1262       Options
1263
1264       It accepts the following options:
1265
1266       packet_size
1267           Set the muxer packet size. By tuning this setting you may reduce
1268           data fragmentation or muxer overhead depending on your source.
1269           Default value is 3200, minimum is 100, maximum is 64k.
1270
1271   avi
1272       Audio Video Interleaved muxer.
1273
1274       Options
1275
1276       It accepts the following options:
1277
1278       reserve_index_space
1279           Reserve the specified amount of bytes for the OpenDML master index
1280           of each stream within the file header. By default additional master
1281           indexes are embedded within the data packets if there is no space
1282           left in the first master index and are linked together as a chain
1283           of indexes. This index structure can cause problems for some use
1284           cases, e.g. third-party software strictly relying on the OpenDML
1285           index specification or when file seeking is slow. Reserving enough
1286           index space in the file header avoids these problems.
1287
1288           The required index space depends on the output file size and should
1289           be about 16 bytes per gigabyte. When this option is omitted or set
1290           to zero the necessary index space is guessed.
1291
1292       write_channel_mask
1293           Write the channel layout mask into the audio stream header.
1294
1295           This option is enabled by default. Disabling the channel mask can
1296           be useful in specific scenarios, e.g. when merging multiple audio
1297           streams into one for compatibility with software that only supports
1298           a single audio stream in AVI (see the "amerge" section in the
1299           ffmpeg-filters manual).
1300
1301       flipped_raw_rgb
1302           If set to true, store positive height for raw RGB bitmaps, which
1303           indicates bitmap is stored bottom-up. Note that this option does
1304           not flip the bitmap which has to be done manually beforehand, e.g.
1305           by using the vflip filter.  Default is false and indicates bitmap
1306           is stored top down.
1307
1308   chromaprint
1309       Chromaprint fingerprinter.
1310
1311       This muxer feeds audio data to the Chromaprint library, which generates
1312       a fingerprint for the provided audio data. See
1313       <https://acoustid.org/chromaprint>
1314
1315       It takes a single signed native-endian 16-bit raw audio stream of at
1316       most 2 channels.
1317
1318       Options
1319
1320       silence_threshold
1321           Threshold for detecting silence. Range is from -1 to 32767, where
1322           -1 disables silence detection. Silence detection can only be used
1323           with version 3 of the algorithm.  Silence detection must be
1324           disabled for use with the AcoustID service. Default is -1.
1325
1326       algorithm
1327           Version of algorithm to fingerprint with. Range is 0 to 4.  Version
1328           3 enables silence detection. Default is 1.
1329
1330       fp_format
1331           Format to output the fingerprint as. Accepts the following options:
1332
1333           raw Binary raw fingerprint
1334
1335           compressed
1336               Binary compressed fingerprint
1337
1338           base64
1339               Base64 compressed fingerprint (default)
1340
1341   crc
1342       CRC (Cyclic Redundancy Check) testing format.
1343
1344       This muxer computes and prints the Adler-32 CRC of all the input audio
1345       and video frames. By default audio frames are converted to signed
1346       16-bit raw audio and video frames to raw video before computing the
1347       CRC.
1348
1349       The output of the muxer consists of a single line of the form:
1350       CRC=0xCRC, where CRC is a hexadecimal number 0-padded to 8 digits
1351       containing the CRC for all the decoded input frames.
1352
1353       See also the framecrc muxer.
1354
1355       Examples
1356
1357       For example to compute the CRC of the input, and store it in the file
1358       out.crc:
1359
1360               ffmpeg -i INPUT -f crc out.crc
1361
1362       You can print the CRC to stdout with the command:
1363
1364               ffmpeg -i INPUT -f crc -
1365
1366       You can select the output format of each frame with ffmpeg by
1367       specifying the audio and video codec and format. For example to compute
1368       the CRC of the input audio converted to PCM unsigned 8-bit and the
1369       input video converted to MPEG-2 video, use the command:
1370
1371               ffmpeg -i INPUT -c:a pcm_u8 -c:v mpeg2video -f crc -
1372
1373   dash
1374       Dynamic Adaptive Streaming over HTTP (DASH) muxer that creates segments
1375       and manifest files according to the MPEG-DASH standard ISO/IEC
1376       23009-1:2014.
1377
1378       For more information see:
1379
1380       •   ISO DASH Specification:
1381           <http://standards.iso.org/ittf/PubliclyAvailableStandards/c065274_ISO_IEC_23009-1_2014.zip>
1382
1383       •   WebM DASH Specification:
1384           <https://sites.google.com/a/webmproject.org/wiki/adaptive-streaming/webm-dash-specification>
1385
1386       It creates a MPD manifest file and segment files for each stream.
1387
1388       The segment filename might contain pre-defined identifiers used with
1389       SegmentTemplate as defined in section 5.3.9.4.4 of the standard.
1390       Available identifiers are "$RepresentationID$", "$Number$",
1391       "$Bandwidth$" and "$Time$".  In addition to the standard identifiers,
1392       an ffmpeg-specific "$ext$" identifier is also supported.  When
1393       specified ffmpeg will replace $ext$ in the file name with muxing
1394       format's extensions such as mp4, webm etc.,
1395
1396               ffmpeg -re -i <input> -map 0 -map 0 -c:a libfdk_aac -c:v libx264 \
1397               -b:v:0 800k -b:v:1 300k -s:v:1 320x170 -profile:v:1 baseline \
1398               -profile:v:0 main -bf 1 -keyint_min 120 -g 120 -sc_threshold 0 \
1399               -b_strategy 0 -ar:a:1 22050 -use_timeline 1 -use_template 1 \
1400               -window_size 5 -adaptation_sets "id=0,streams=v id=1,streams=a" \
1401               -f dash /path/to/out.mpd
1402
1403       seg_duration duration
1404           Set the segment length in seconds (fractional value can be set).
1405           The value is treated as average segment duration when use_template
1406           is enabled and use_timeline is disabled and as minimum segment
1407           duration for all the other use cases.
1408
1409       frag_duration duration
1410           Set the length in seconds of fragments within segments (fractional
1411           value can be set).
1412
1413       frag_type type
1414           Set the type of interval for fragmentation.
1415
1416       window_size size
1417           Set the maximum number of segments kept in the manifest.
1418
1419       extra_window_size size
1420           Set the maximum number of segments kept outside of the manifest
1421           before removing from disk.
1422
1423       remove_at_exit remove
1424           Enable (1) or disable (0) removal of all segments when finished.
1425
1426       use_template template
1427           Enable (1) or disable (0) use of SegmentTemplate instead of
1428           SegmentList.
1429
1430       use_timeline timeline
1431           Enable (1) or disable (0) use of SegmentTimeline in
1432           SegmentTemplate.
1433
1434       single_file single_file
1435           Enable (1) or disable (0) storing all segments in one file,
1436           accessed using byte ranges.
1437
1438       single_file_name file_name
1439           DASH-templated name to be used for baseURL. Implies single_file set
1440           to "1". In the template, "$ext$" is replaced with the file name
1441           extension specific for the segment format.
1442
1443       init_seg_name init_name
1444           DASH-templated name to used for the initialization segment. Default
1445           is "init-stream$RepresentationID$.$ext$". "$ext$" is replaced with
1446           the file name extension specific for the segment format.
1447
1448       media_seg_name segment_name
1449           DASH-templated name to used for the media segments. Default is
1450           "chunk-stream$RepresentationID$-$Number%05d$.$ext$". "$ext$" is
1451           replaced with the file name extension specific for the segment
1452           format.
1453
1454       utc_timing_url utc_url
1455           URL of the page that will return the UTC timestamp in ISO format.
1456           Example: "https://time.akamai.com/?iso"
1457
1458       method method
1459           Use the given HTTP method to create output files. Generally set to
1460           PUT or POST.
1461
1462       http_user_agent user_agent
1463           Override User-Agent field in HTTP header. Applicable only for HTTP
1464           output.
1465
1466       http_persistent http_persistent
1467           Use persistent HTTP connections. Applicable only for HTTP output.
1468
1469       hls_playlist hls_playlist
1470           Generate HLS playlist files as well. The master playlist is
1471           generated with the filename hls_master_name.  One media playlist
1472           file is generated for each stream with filenames media_0.m3u8,
1473           media_1.m3u8, etc.
1474
1475       hls_master_name file_name
1476           HLS master playlist name. Default is "master.m3u8".
1477
1478       streaming streaming
1479           Enable (1) or disable (0) chunk streaming mode of output. In chunk
1480           streaming mode, each frame will be a moof fragment which forms a
1481           chunk.
1482
1483       adaptation_sets adaptation_sets
1484           Assign streams to AdaptationSets. Syntax is "id=x,streams=a,b,c
1485           id=y,streams=d,e" with x and y being the IDs of the adaptation sets
1486           and a,b,c,d and e are the indices of the mapped streams.
1487
1488           To map all video (or audio) streams to an AdaptationSet, "v" (or
1489           "a") can be used as stream identifier instead of IDs.
1490
1491           When no assignment is defined, this defaults to an AdaptationSet
1492           for each stream.
1493
1494           Optional syntax is
1495           "id=x,seg_duration=x,frag_duration=x,frag_type=type,descriptor=descriptor_string,streams=a,b,c
1496           id=y,seg_duration=y,frag_type=type,streams=d,e" and so on,
1497           descriptor is useful to the scheme defined by ISO/IEC
1498           23009-1:2014/Amd.2:2015.  For example, -adaptation_sets
1499           "id=0,descriptor=<SupplementalProperty
1500           schemeIdUri=\"urn:mpeg:dash:srd:2014\"
1501           value=\"0,0,0,1,1,2,2\"/>,streams=v".  Please note that descriptor
1502           string should be a self-closing xml tag.  seg_duration,
1503           frag_duration and frag_type override the global option values for
1504           each adaptation set.  For example, -adaptation_sets
1505           "id=0,seg_duration=2,frag_duration=1,frag_type=duration,streams=v
1506           id=1,seg_duration=2,frag_type=none,streams=a" type_id marks an
1507           adaptation set as containing streams meant to be used for Trick
1508           Mode for the referenced adaptation set.  For example,
1509           -adaptation_sets "id=0,seg_duration=2,frag_type=none,streams=0
1510           id=1,seg_duration=10,frag_type=none,trick_id=0,streams=1"
1511
1512       timeout timeout
1513           Set timeout for socket I/O operations. Applicable only for HTTP
1514           output.
1515
1516       index_correction index_correction
1517           Enable (1) or Disable (0) segment index correction logic.
1518           Applicable only when use_template is enabled and use_timeline is
1519           disabled.
1520
1521           When enabled, the logic monitors the flow of segment indexes. If a
1522           streams's segment index value is not at the expected real time
1523           position, then the logic corrects that index value.
1524
1525           Typically this logic is needed in live streaming use cases. The
1526           network bandwidth fluctuations are common during long run
1527           streaming. Each fluctuation can cause the segment indexes fall
1528           behind the expected real time position.
1529
1530       format_options options_list
1531           Set container format (mp4/webm) options using a ":" separated list
1532           of key=value parameters. Values containing ":" special characters
1533           must be escaped.
1534
1535       global_sidx global_sidx
1536           Write global SIDX atom. Applicable only for single file, mp4
1537           output, non-streaming mode.
1538
1539       dash_segment_type dash_segment_type
1540           Possible values:
1541
1542           auto
1543               If this flag is set, the dash segment files format will be
1544               selected based on the stream codec. This is the default mode.
1545
1546           mp4 If this flag is set, the dash segment files will be in in
1547               ISOBMFF format.
1548
1549           webm
1550               If this flag is set, the dash segment files will be in in WebM
1551               format.
1552
1553       ignore_io_errors ignore_io_errors
1554           Ignore IO errors during open and write. Useful for long-duration
1555           runs with network output.
1556
1557       lhls lhls
1558           Enable Low-latency HLS(LHLS). Adds #EXT-X-PREFETCH tag with current
1559           segment's URI.  hls.js player folks are trying to standardize an
1560           open LHLS spec. The draft spec is available in
1561           https://github.com/video-dev/hlsjs-rfcs/blob/lhls-spec/proposals/0001-lhls.md
1562           This option tries to comply with the above open spec.  It enables
1563           streaming and hls_playlist options automatically.  This is an
1564           experimental feature.
1565
1566           Note: This is not Apple's version LHLS. See
1567           <https://datatracker.ietf.org/doc/html/draft-pantos-hls-rfc8216bis>
1568
1569       ldash ldash
1570           Enable Low-latency Dash by constraining the presence and values of
1571           some elements.
1572
1573       master_m3u8_publish_rate master_m3u8_publish_rate
1574           Publish master playlist repeatedly every after specified number of
1575           segment intervals.
1576
1577       write_prft write_prft
1578           Write Producer Reference Time elements on supported streams. This
1579           also enables writing prft boxes in the underlying muxer. Applicable
1580           only when the utc_url option is enabled.  It's set to auto by
1581           default, in which case the muxer will attempt to enable it only in
1582           modes that require it.
1583
1584       mpd_profile mpd_profile
1585           Set one or more manifest profiles.
1586
1587       http_opts http_opts
1588           A :-separated list of key=value options to pass to the underlying
1589           HTTP protocol. Applicable only for HTTP output.
1590
1591       target_latency target_latency
1592           Set an intended target latency in seconds (fractional value can be
1593           set) for serving. Applicable only when streaming and write_prft
1594           options are enabled.  This is an informative fields clients can use
1595           to measure the latency of the service.
1596
1597       min_playback_rate min_playback_rate
1598           Set the minimum playback rate indicated as appropriate for the
1599           purposes of automatically adjusting playback latency and buffer
1600           occupancy during normal playback by clients.
1601
1602       max_playback_rate max_playback_rate
1603           Set the maximum playback rate indicated as appropriate for the
1604           purposes of automatically adjusting playback latency and buffer
1605           occupancy during normal playback by clients.
1606
1607       update_period update_period
1608            Set the mpd update period ,for dynamic content.
1609            The unit is second.
1610
1611   fifo
1612       The fifo pseudo-muxer allows the separation of encoding and muxing by
1613       using first-in-first-out queue and running the actual muxer in a
1614       separate thread. This is especially useful in combination with the tee
1615       muxer and can be used to send data to several destinations with
1616       different reliability/writing speed/latency.
1617
1618       API users should be aware that callback functions (interrupt_callback,
1619       io_open and io_close) used within its AVFormatContext must be thread-
1620       safe.
1621
1622       The behavior of the fifo muxer if the queue fills up or if the output
1623       fails is selectable,
1624
1625       •   output can be transparently restarted with configurable delay
1626           between retries based on real time or time of the processed stream.
1627
1628       •   encoding can be blocked during temporary failure, or continue
1629           transparently dropping packets in case fifo queue fills up.
1630
1631       fifo_format
1632           Specify the format name. Useful if it cannot be guessed from the
1633           output name suffix.
1634
1635       queue_size
1636           Specify size of the queue (number of packets). Default value is 60.
1637
1638       format_opts
1639           Specify format options for the underlying muxer. Muxer options can
1640           be specified as a list of key=value pairs separated by ':'.
1641
1642       drop_pkts_on_overflow bool
1643           If set to 1 (true), in case the fifo queue fills up, packets will
1644           be dropped rather than blocking the encoder. This makes it possible
1645           to continue streaming without delaying the input, at the cost of
1646           omitting part of the stream. By default this option is set to 0
1647           (false), so in such cases the encoder will be blocked until the
1648           muxer processes some of the packets and none of them is lost.
1649
1650       attempt_recovery bool
1651           If failure occurs, attempt to recover the output. This is
1652           especially useful when used with network output, since it makes it
1653           possible to restart streaming transparently.  By default this
1654           option is set to 0 (false).
1655
1656       max_recovery_attempts
1657           Sets maximum number of successive unsuccessful recovery attempts
1658           after which the output fails permanently. By default this option is
1659           set to 0 (unlimited).
1660
1661       recovery_wait_time duration
1662           Waiting time before the next recovery attempt after previous
1663           unsuccessful recovery attempt. Default value is 5 seconds.
1664
1665       recovery_wait_streamtime bool
1666           If set to 0 (false), the real time is used when waiting for the
1667           recovery attempt (i.e. the recovery will be attempted after at
1668           least recovery_wait_time seconds).  If set to 1 (true), the time of
1669           the processed stream is taken into account instead (i.e. the
1670           recovery will be attempted after at least recovery_wait_time
1671           seconds of the stream is omitted).  By default, this option is set
1672           to 0 (false).
1673
1674       recover_any_error bool
1675           If set to 1 (true), recovery will be attempted regardless of type
1676           of the error causing the failure. By default this option is set to
1677           0 (false) and in case of certain (usually permanent) errors the
1678           recovery is not attempted even when attempt_recovery is set to 1.
1679
1680       restart_with_keyframe bool
1681           Specify whether to wait for the keyframe after recovering from
1682           queue overflow or failure. This option is set to 0 (false) by
1683           default.
1684
1685       timeshift duration
1686           Buffer the specified amount of packets and delay writing the
1687           output. Note that queue_size must be big enough to store the
1688           packets for timeshift. At the end of the input the fifo buffer is
1689           flushed at realtime speed.
1690
1691       Examples
1692
1693       •   Stream something to rtmp server, continue processing the stream at
1694           real-time rate even in case of temporary failure (network outage)
1695           and attempt to recover streaming every second indefinitely.
1696
1697                   ffmpeg -re -i ... -c:v libx264 -c:a aac -f fifo -fifo_format flv -map 0:v -map 0:a
1698                     -drop_pkts_on_overflow 1 -attempt_recovery 1 -recovery_wait_time 1 rtmp://example.com/live/stream_name
1699
1700   flv
1701       Adobe Flash Video Format muxer.
1702
1703       This muxer accepts the following options:
1704
1705       flvflags flags
1706           Possible values:
1707
1708           aac_seq_header_detect
1709               Place AAC sequence header based on audio stream data.
1710
1711           no_sequence_end
1712               Disable sequence end tag.
1713
1714           no_metadata
1715               Disable metadata tag.
1716
1717           no_duration_filesize
1718               Disable duration and filesize in metadata when they are equal
1719               to zero at the end of stream. (Be used to non-seekable living
1720               stream).
1721
1722           add_keyframe_index
1723               Used to facilitate seeking; particularly for HTTP pseudo
1724               streaming.
1725
1726   framecrc
1727       Per-packet CRC (Cyclic Redundancy Check) testing format.
1728
1729       This muxer computes and prints the Adler-32 CRC for each audio and
1730       video packet. By default audio frames are converted to signed 16-bit
1731       raw audio and video frames to raw video before computing the CRC.
1732
1733       The output of the muxer consists of a line for each audio and video
1734       packet of the form:
1735
1736               <stream_index>, <packet_dts>, <packet_pts>, <packet_duration>, <packet_size>, 0x<CRC>
1737
1738       CRC is a hexadecimal number 0-padded to 8 digits containing the CRC of
1739       the packet.
1740
1741       Examples
1742
1743       For example to compute the CRC of the audio and video frames in INPUT,
1744       converted to raw audio and video packets, and store it in the file
1745       out.crc:
1746
1747               ffmpeg -i INPUT -f framecrc out.crc
1748
1749       To print the information to stdout, use the command:
1750
1751               ffmpeg -i INPUT -f framecrc -
1752
1753       With ffmpeg, you can select the output format to which the audio and
1754       video frames are encoded before computing the CRC for each packet by
1755       specifying the audio and video codec. For example, to compute the CRC
1756       of each decoded input audio frame converted to PCM unsigned 8-bit and
1757       of each decoded input video frame converted to MPEG-2 video, use the
1758       command:
1759
1760               ffmpeg -i INPUT -c:a pcm_u8 -c:v mpeg2video -f framecrc -
1761
1762       See also the crc muxer.
1763
1764   framehash
1765       Per-packet hash testing format.
1766
1767       This muxer computes and prints a cryptographic hash for each audio and
1768       video packet. This can be used for packet-by-packet equality checks
1769       without having to individually do a binary comparison on each.
1770
1771       By default audio frames are converted to signed 16-bit raw audio and
1772       video frames to raw video before computing the hash, but the output of
1773       explicit conversions to other codecs can also be used. It uses the
1774       SHA-256 cryptographic hash function by default, but supports several
1775       other algorithms.
1776
1777       The output of the muxer consists of a line for each audio and video
1778       packet of the form:
1779
1780               <stream_index>, <packet_dts>, <packet_pts>, <packet_duration>, <packet_size>, <hash>
1781
1782       hash is a hexadecimal number representing the computed hash for the
1783       packet.
1784
1785       hash algorithm
1786           Use the cryptographic hash function specified by the string
1787           algorithm.  Supported values include "MD5", "murmur3", "RIPEMD128",
1788           "RIPEMD160", "RIPEMD256", "RIPEMD320", "SHA160", "SHA224", "SHA256"
1789           (default), "SHA512/224", "SHA512/256", "SHA384", "SHA512", "CRC32"
1790           and "adler32".
1791
1792       Examples
1793
1794       To compute the SHA-256 hash of the audio and video frames in INPUT,
1795       converted to raw audio and video packets, and store it in the file
1796       out.sha256:
1797
1798               ffmpeg -i INPUT -f framehash out.sha256
1799
1800       To print the information to stdout, using the MD5 hash function, use
1801       the command:
1802
1803               ffmpeg -i INPUT -f framehash -hash md5 -
1804
1805       See also the hash muxer.
1806
1807   framemd5
1808       Per-packet MD5 testing format.
1809
1810       This is a variant of the framehash muxer. Unlike that muxer, it
1811       defaults to using the MD5 hash function.
1812
1813       Examples
1814
1815       To compute the MD5 hash of the audio and video frames in INPUT,
1816       converted to raw audio and video packets, and store it in the file
1817       out.md5:
1818
1819               ffmpeg -i INPUT -f framemd5 out.md5
1820
1821       To print the information to stdout, use the command:
1822
1823               ffmpeg -i INPUT -f framemd5 -
1824
1825       See also the framehash and md5 muxers.
1826
1827   gif
1828       Animated GIF muxer.
1829
1830       It accepts the following options:
1831
1832       loop
1833           Set the number of times to loop the output. Use -1 for no loop, 0
1834           for looping indefinitely (default).
1835
1836       final_delay
1837           Force the delay (expressed in centiseconds) after the last frame.
1838           Each frame ends with a delay until the next frame. The default is
1839           -1, which is a special value to tell the muxer to re-use the
1840           previous delay. In case of a loop, you might want to customize this
1841           value to mark a pause for instance.
1842
1843       For example, to encode a gif looping 10 times, with a 5 seconds delay
1844       between the loops:
1845
1846               ffmpeg -i INPUT -loop 10 -final_delay 500 out.gif
1847
1848       Note 1: if you wish to extract the frames into separate GIF files, you
1849       need to force the image2 muxer:
1850
1851               ffmpeg -i INPUT -c:v gif -f image2 "out%d.gif"
1852
1853       Note 2: the GIF format has a very large time base: the delay between
1854       two frames can therefore not be smaller than one centi second.
1855
1856   hash
1857       Hash testing format.
1858
1859       This muxer computes and prints a cryptographic hash of all the input
1860       audio and video frames. This can be used for equality checks without
1861       having to do a complete binary comparison.
1862
1863       By default audio frames are converted to signed 16-bit raw audio and
1864       video frames to raw video before computing the hash, but the output of
1865       explicit conversions to other codecs can also be used. Timestamps are
1866       ignored. It uses the SHA-256 cryptographic hash function by default,
1867       but supports several other algorithms.
1868
1869       The output of the muxer consists of a single line of the form:
1870       algo=hash, where algo is a short string representing the hash function
1871       used, and hash is a hexadecimal number representing the computed hash.
1872
1873       hash algorithm
1874           Use the cryptographic hash function specified by the string
1875           algorithm.  Supported values include "MD5", "murmur3", "RIPEMD128",
1876           "RIPEMD160", "RIPEMD256", "RIPEMD320", "SHA160", "SHA224", "SHA256"
1877           (default), "SHA512/224", "SHA512/256", "SHA384", "SHA512", "CRC32"
1878           and "adler32".
1879
1880       Examples
1881
1882       To compute the SHA-256 hash of the input converted to raw audio and
1883       video, and store it in the file out.sha256:
1884
1885               ffmpeg -i INPUT -f hash out.sha256
1886
1887       To print an MD5 hash to stdout use the command:
1888
1889               ffmpeg -i INPUT -f hash -hash md5 -
1890
1891       See also the framehash muxer.
1892
1893   hls
1894       Apple HTTP Live Streaming muxer that segments MPEG-TS according to the
1895       HTTP Live Streaming (HLS) specification.
1896
1897       It creates a playlist file, and one or more segment files. The output
1898       filename specifies the playlist filename.
1899
1900       By default, the muxer creates a file for each segment produced. These
1901       files have the same name as the playlist, followed by a sequential
1902       number and a .ts extension.
1903
1904       Make sure to require a closed GOP when encoding and to set the GOP size
1905       to fit your segment time constraint.
1906
1907       For example, to convert an input file with ffmpeg:
1908
1909               ffmpeg -i in.mkv -c:v h264 -flags +cgop -g 30 -hls_time 1 out.m3u8
1910
1911       This example will produce the playlist, out.m3u8, and segment files:
1912       out0.ts, out1.ts, out2.ts, etc.
1913
1914       See also the segment muxer, which provides a more generic and flexible
1915       implementation of a segmenter, and can be used to perform HLS
1916       segmentation.
1917
1918       Options
1919
1920       This muxer supports the following options:
1921
1922       hls_init_time duration
1923           Set the initial target segment length. Default value is 0.
1924
1925           duration must be a time duration specification, see the Time
1926           duration section in the ffmpeg-utils(1) manual.
1927
1928           Segment will be cut on the next key frame after this time has
1929           passed on the first m3u8 list.  After the initial playlist is
1930           filled ffmpeg will cut segments at duration equal to "hls_time"
1931
1932       hls_time duration
1933           Set the target segment length. Default value is 2.
1934
1935           duration must be a time duration specification, see the Time
1936           duration section in the ffmpeg-utils(1) manual.  Segment will be
1937           cut on the next key frame after this time has passed.
1938
1939       hls_list_size size
1940           Set the maximum number of playlist entries. If set to 0 the list
1941           file will contain all the segments. Default value is 5.
1942
1943       hls_delete_threshold size
1944           Set the number of unreferenced segments to keep on disk before
1945           "hls_flags delete_segments" deletes them. Increase this to allow
1946           continue clients to download segments which were recently
1947           referenced in the playlist. Default value is 1, meaning segments
1948           older than "hls_list_size+1" will be deleted.
1949
1950       hls_start_number_source
1951           Start the playlist sequence number ("#EXT-X-MEDIA-SEQUENCE")
1952           according to the specified source.  Unless "hls_flags single_file"
1953           is set, it also specifies source of starting sequence numbers of
1954           segment and subtitle filenames. In any case, if "hls_flags
1955           append_list" is set and read playlist sequence number is greater
1956           than the specified start sequence number, then that value will be
1957           used as start value.
1958
1959           It accepts the following values:
1960
1961           generic (default)
1962               Set the starting sequence numbers according to start_number
1963               option value.
1964
1965           epoch
1966               The start number will be the seconds since epoch (1970-01-01
1967               00:00:00)
1968
1969           epoch_us
1970               The start number will be the microseconds since epoch
1971               (1970-01-01 00:00:00)
1972
1973           datetime
1974               The start number will be based on the current date/time as
1975               YYYYmmddHHMMSS. e.g. 20161231235759.
1976
1977       start_number number
1978           Start the playlist sequence number ("#EXT-X-MEDIA-SEQUENCE") from
1979           the specified number when hls_start_number_source value is generic.
1980           (This is the default case.)  Unless "hls_flags single_file" is set,
1981           it also specifies starting sequence numbers of segment and subtitle
1982           filenames.  Default value is 0.
1983
1984       hls_allow_cache allowcache
1985           Explicitly set whether the client MAY (1) or MUST NOT (0) cache
1986           media segments.
1987
1988       hls_base_url baseurl
1989           Append baseurl to every entry in the playlist.  Useful to generate
1990           playlists with absolute paths.
1991
1992           Note that the playlist sequence number must be unique for each
1993           segment and it is not to be confused with the segment filename
1994           sequence number which can be cyclic, for example if the wrap option
1995           is specified.
1996
1997       hls_segment_filename filename
1998           Set the segment filename. Unless "hls_flags single_file" is set,
1999           filename is used as a string format with the segment number:
2000
2001                   ffmpeg -i in.nut -hls_segment_filename 'file%03d.ts' out.m3u8
2002
2003           This example will produce the playlist, out.m3u8, and segment
2004           files: file000.ts, file001.ts, file002.ts, etc.
2005
2006           filename may contain full path or relative path specification, but
2007           only the file name part without any path info will be contained in
2008           the m3u8 segment list.  Should a relative path be specified, the
2009           path of the created segment files will be relative to the current
2010           working directory.  When strftime_mkdir is set, the whole expanded
2011           value of filename will be written into the m3u8 segment list.
2012
2013           When "var_stream_map" is set with two or more variant streams, the
2014           filename pattern must contain the string "%v", this string
2015           specifies the position of variant stream index in the generated
2016           segment file names.
2017
2018                   ffmpeg -i in.ts -b:v:0 1000k -b:v:1 256k -b:a:0 64k -b:a:1 32k \
2019                     -map 0:v -map 0:a -map 0:v -map 0:a -f hls -var_stream_map "v:0,a:0 v:1,a:1" \
2020                     -hls_segment_filename 'file_%v_%03d.ts' out_%v.m3u8
2021
2022           This example will produce the playlists segment file sets:
2023           file_0_000.ts, file_0_001.ts, file_0_002.ts, etc. and
2024           file_1_000.ts, file_1_001.ts, file_1_002.ts, etc.
2025
2026           The string "%v" may be present in the filename or in the last
2027           directory name containing the file, but only in one of them.
2028           (Additionally, %v may appear multiple times in the last sub-
2029           directory or filename.) If the string %v is present in the
2030           directory name, then sub-directories are created after expanding
2031           the directory name pattern. This enables creation of segments
2032           corresponding to different variant streams in subdirectories.
2033
2034                   ffmpeg -i in.ts -b:v:0 1000k -b:v:1 256k -b:a:0 64k -b:a:1 32k \
2035                     -map 0:v -map 0:a -map 0:v -map 0:a -f hls -var_stream_map "v:0,a:0 v:1,a:1" \
2036                     -hls_segment_filename 'vs%v/file_%03d.ts' vs%v/out.m3u8
2037
2038           This example will produce the playlists segment file sets:
2039           vs0/file_000.ts, vs0/file_001.ts, vs0/file_002.ts, etc. and
2040           vs1/file_000.ts, vs1/file_001.ts, vs1/file_002.ts, etc.
2041
2042       strftime
2043           Use strftime() on filename to expand the segment filename with
2044           localtime.  The segment number is also available in this mode, but
2045           to use it, you need to specify second_level_segment_index hls_flag
2046           and %%d will be the specifier.
2047
2048                   ffmpeg -i in.nut -strftime 1 -hls_segment_filename 'file-%Y%m%d-%s.ts' out.m3u8
2049
2050           This example will produce the playlist, out.m3u8, and segment
2051           files: file-20160215-1455569023.ts, file-20160215-1455569024.ts,
2052           etc.  Note: On some systems/environments, the %s specifier is not
2053           available. See
2054             strftime() documentation.
2055
2056                   ffmpeg -i in.nut -strftime 1 -hls_flags second_level_segment_index -hls_segment_filename 'file-%Y%m%d-%%04d.ts' out.m3u8
2057
2058           This example will produce the playlist, out.m3u8, and segment
2059           files: file-20160215-0001.ts, file-20160215-0002.ts, etc.
2060
2061       strftime_mkdir
2062           Used together with -strftime_mkdir, it will create all
2063           subdirectories which is expanded in filename.
2064
2065                   ffmpeg -i in.nut -strftime 1 -strftime_mkdir 1 -hls_segment_filename '%Y%m%d/file-%Y%m%d-%s.ts' out.m3u8
2066
2067           This example will create a directory 201560215 (if it does not
2068           exist), and then produce the playlist, out.m3u8, and segment files:
2069           20160215/file-20160215-1455569023.ts,
2070           20160215/file-20160215-1455569024.ts, etc.
2071
2072                   ffmpeg -i in.nut -strftime 1 -strftime_mkdir 1 -hls_segment_filename '%Y/%m/%d/file-%Y%m%d-%s.ts' out.m3u8
2073
2074           This example will create a directory hierarchy 2016/02/15 (if any
2075           of them do not exist), and then produce the playlist, out.m3u8, and
2076           segment files: 2016/02/15/file-20160215-1455569023.ts,
2077           2016/02/15/file-20160215-1455569024.ts, etc.
2078
2079       hls_segment_options options_list
2080           Set output format options using a :-separated list of key=value
2081           parameters. Values containing ":" special characters must be
2082           escaped.
2083
2084       hls_key_info_file key_info_file
2085           Use the information in key_info_file for segment encryption. The
2086           first line of key_info_file specifies the key URI written to the
2087           playlist. The key URL is used to access the encryption key during
2088           playback. The second line specifies the path to the key file used
2089           to obtain the key during the encryption process. The key file is
2090           read as a single packed array of 16 octets in binary format. The
2091           optional third line specifies the initialization vector (IV) as a
2092           hexadecimal string to be used instead of the segment sequence
2093           number (default) for encryption. Changes to key_info_file will
2094           result in segment encryption with the new key/IV and an entry in
2095           the playlist for the new key URI/IV if "hls_flags periodic_rekey"
2096           is enabled.
2097
2098           Key info file format:
2099
2100                   <key URI>
2101                   <key file path>
2102                   <IV> (optional)
2103
2104           Example key URIs:
2105
2106                   http://server/file.key
2107                   /path/to/file.key
2108                   file.key
2109
2110           Example key file paths:
2111
2112                   file.key
2113                   /path/to/file.key
2114
2115           Example IV:
2116
2117                   0123456789ABCDEF0123456789ABCDEF
2118
2119           Key info file example:
2120
2121                   http://server/file.key
2122                   /path/to/file.key
2123                   0123456789ABCDEF0123456789ABCDEF
2124
2125           Example shell script:
2126
2127                   #!/bin/sh
2128                   BASE_URL=${1:-'.'}
2129                   openssl rand 16 > file.key
2130                   echo $BASE_URL/file.key > file.keyinfo
2131                   echo file.key >> file.keyinfo
2132                   echo $(openssl rand -hex 16) >> file.keyinfo
2133                   ffmpeg -f lavfi -re -i testsrc -c:v h264 -hls_flags delete_segments \
2134                     -hls_key_info_file file.keyinfo out.m3u8
2135
2136       -hls_enc enc
2137           Enable (1) or disable (0) the AES128 encryption.  When enabled
2138           every segment generated is encrypted and the encryption key is
2139           saved as playlist name.key.
2140
2141       -hls_enc_key key
2142           16-octet key to encrypt the segments, by default it is randomly
2143           generated.
2144
2145       -hls_enc_key_url keyurl
2146           If set, keyurl is prepended instead of baseurl to the key filename
2147           in the playlist.
2148
2149       -hls_enc_iv iv
2150           16-octet initialization vector for every segment instead of the
2151           autogenerated ones.
2152
2153       hls_segment_type flags
2154           Possible values:
2155
2156           mpegts
2157               Output segment files in MPEG-2 Transport Stream format. This is
2158               compatible with all HLS versions.
2159
2160           fmp4
2161               Output segment files in fragmented MP4 format, similar to MPEG-
2162               DASH.  fmp4 files may be used in HLS version 7 and above.
2163
2164       hls_fmp4_init_filename filename
2165           Set filename to the fragment files header file, default filename is
2166           init.mp4.
2167
2168           Use "-strftime 1" on filename to expand the segment filename with
2169           localtime.
2170
2171                   ffmpeg -i in.nut  -hls_segment_type fmp4 -strftime 1 -hls_fmp4_init_filename "%s_init.mp4" out.m3u8
2172
2173           This will produce init like this 1602678741_init.mp4
2174
2175       hls_fmp4_init_resend
2176           Resend init file after m3u8 file refresh every time, default is 0.
2177
2178           When "var_stream_map" is set with two or more variant streams, the
2179           filename pattern must contain the string "%v", this string
2180           specifies the position of variant stream index in the generated
2181           init file names.  The string "%v" may be present in the filename or
2182           in the last directory name containing the file. If the string is
2183           present in the directory name, then sub-directories are created
2184           after expanding the directory name pattern. This enables creation
2185           of init files corresponding to different variant streams in
2186           subdirectories.
2187
2188       hls_flags flags
2189           Possible values:
2190
2191           single_file
2192               If this flag is set, the muxer will store all segments in a
2193               single MPEG-TS file, and will use byte ranges in the playlist.
2194               HLS playlists generated with this way will have the version
2195               number 4.  For example:
2196
2197                       ffmpeg -i in.nut -hls_flags single_file out.m3u8
2198
2199               Will produce the playlist, out.m3u8, and a single segment file,
2200               out.ts.
2201
2202           delete_segments
2203               Segment files removed from the playlist are deleted after a
2204               period of time equal to the duration of the segment plus the
2205               duration of the playlist.
2206
2207           append_list
2208               Append new segments into the end of old segment list, and
2209               remove the "#EXT-X-ENDLIST" from the old segment list.
2210
2211           round_durations
2212               Round the duration info in the playlist file segment info to
2213               integer values, instead of using floating point.  If there are
2214               no other features requiring higher HLS versions be used, then
2215               this will allow ffmpeg to output a HLS version 2 m3u8.
2216
2217           discont_start
2218               Add the "#EXT-X-DISCONTINUITY" tag to the playlist, before the
2219               first segment's information.
2220
2221           omit_endlist
2222               Do not append the "EXT-X-ENDLIST" tag at the end of the
2223               playlist.
2224
2225           periodic_rekey
2226               The file specified by "hls_key_info_file" will be checked
2227               periodically and detect updates to the encryption info. Be sure
2228               to replace this file atomically, including the file containing
2229               the AES encryption key.
2230
2231           independent_segments
2232               Add the "#EXT-X-INDEPENDENT-SEGMENTS" to playlists that has
2233               video segments and when all the segments of that playlist are
2234               guaranteed to start with a Key frame.
2235
2236           iframes_only
2237               Add the "#EXT-X-I-FRAMES-ONLY" to playlists that has video
2238               segments and can play only I-frames in the "#EXT-X-BYTERANGE"
2239               mode.
2240
2241           split_by_time
2242               Allow segments to start on frames other than keyframes. This
2243               improves behavior on some players when the time between
2244               keyframes is inconsistent, but may make things worse on others,
2245               and can cause some oddities during seeking. This flag should be
2246               used with the "hls_time" option.
2247
2248           program_date_time
2249               Generate "EXT-X-PROGRAM-DATE-TIME" tags.
2250
2251           second_level_segment_index
2252               Makes it possible to use segment indexes as %%d in
2253               hls_segment_filename expression besides date/time values when
2254               strftime is on.  To get fixed width numbers with trailing
2255               zeroes, %%0xd format is available where x is the required
2256               width.
2257
2258           second_level_segment_size
2259               Makes it possible to use segment sizes (counted in bytes) as
2260               %%s in hls_segment_filename expression besides date/time values
2261               when strftime is on.  To get fixed width numbers with trailing
2262               zeroes, %%0xs format is available where x is the required
2263               width.
2264
2265           second_level_segment_duration
2266               Makes it possible to use segment duration (calculated  in
2267               microseconds) as %%t in hls_segment_filename expression besides
2268               date/time values when strftime is on.  To get fixed width
2269               numbers with trailing zeroes, %%0xt format is available where x
2270               is the required width.
2271
2272                       ffmpeg -i sample.mpeg \
2273                          -f hls -hls_time 3 -hls_list_size 5 \
2274                          -hls_flags second_level_segment_index+second_level_segment_size+second_level_segment_duration \
2275                          -strftime 1 -strftime_mkdir 1 -hls_segment_filename "segment_%Y%m%d%H%M%S_%%04d_%%08s_%%013t.ts" stream.m3u8
2276
2277               This will produce segments like this:
2278               segment_20170102194334_0003_00122200_0000003000000.ts,
2279               segment_20170102194334_0004_00120072_0000003000000.ts etc.
2280
2281           temp_file
2282               Write segment data to filename.tmp and rename to filename only
2283               once the segment is complete. A webserver serving up segments
2284               can be configured to reject requests to *.tmp to prevent access
2285               to in-progress segments before they have been added to the m3u8
2286               playlist. This flag also affects how m3u8 playlist files are
2287               created.  If this flag is set, all playlist files will written
2288               into temporary file and renamed after they are complete,
2289               similarly as segments are handled.  But playlists with "file"
2290               protocol and with type ("hls_playlist_type") other than "vod"
2291               are always written into temporary file regardless of this flag.
2292               Master playlist files ("master_pl_name"), if any, with "file"
2293               protocol, are always written into temporary file regardless of
2294               this flag if "master_pl_publish_rate" value is other than zero.
2295
2296       hls_playlist_type event
2297           Emit "#EXT-X-PLAYLIST-TYPE:EVENT" in the m3u8 header. Forces
2298           hls_list_size to 0; the playlist can only be appended to.
2299
2300       hls_playlist_type vod
2301           Emit "#EXT-X-PLAYLIST-TYPE:VOD" in the m3u8 header. Forces
2302           hls_list_size to 0; the playlist must not change.
2303
2304       method
2305           Use the given HTTP method to create the hls files.
2306
2307                   ffmpeg -re -i in.ts -f hls -method PUT http://example.com/live/out.m3u8
2308
2309           This example will upload all the mpegts segment files to the HTTP
2310           server using the HTTP PUT method, and update the m3u8 files every
2311           "refresh" times using the same method.  Note that the HTTP server
2312           must support the given method for uploading files.
2313
2314       http_user_agent
2315           Override User-Agent field in HTTP header. Applicable only for HTTP
2316           output.
2317
2318       var_stream_map
2319           Map string which specifies how to group the audio, video and
2320           subtitle streams into different variant streams. The variant stream
2321           groups are separated by space.  Expected string format is like this
2322           "a:0,v:0 a:1,v:1 ....". Here a:, v:, s: are the keys to specify
2323           audio, video and subtitle streams respectively.  Allowed values are
2324           0 to 9 (limited just based on practical usage).
2325
2326           When there are two or more variant streams, the output filename
2327           pattern must contain the string "%v", this string specifies the
2328           position of variant stream index in the output media playlist
2329           filenames. The string "%v" may be present in the filename or in the
2330           last directory name containing the file. If the string is present
2331           in the directory name, then sub-directories are created after
2332           expanding the directory name pattern. This enables creation of
2333           variant streams in subdirectories.
2334
2335                   ffmpeg -re -i in.ts -b:v:0 1000k -b:v:1 256k -b:a:0 64k -b:a:1 32k \
2336                     -map 0:v -map 0:a -map 0:v -map 0:a -f hls -var_stream_map "v:0,a:0 v:1,a:1" \
2337                     http://example.com/live/out_%v.m3u8
2338
2339           This example creates two hls variant streams. The first variant
2340           stream will contain video stream of bitrate 1000k and audio stream
2341           of bitrate 64k and the second variant stream will contain video
2342           stream of bitrate 256k and audio stream of bitrate 32k. Here, two
2343           media playlist with file names out_0.m3u8 and out_1.m3u8 will be
2344           created. If you want something meaningful text instead of indexes
2345           in result names, you may specify names for each or some of the
2346           variants as in the following example.
2347
2348                   ffmpeg -re -i in.ts -b:v:0 1000k -b:v:1 256k -b:a:0 64k -b:a:1 32k \
2349                     -map 0:v -map 0:a -map 0:v -map 0:a -f hls -var_stream_map "v:0,a:0,name:my_hd v:1,a:1,name:my_sd" \
2350                     http://example.com/live/out_%v.m3u8
2351
2352           This example creates two hls variant streams as in the previous
2353           one.  But here, the two media playlist with file names
2354           out_my_hd.m3u8 and out_my_sd.m3u8 will be created.
2355
2356                   ffmpeg -re -i in.ts -b:v:0 1000k -b:v:1 256k -b:a:0 64k \
2357                     -map 0:v -map 0:a -map 0:v -f hls -var_stream_map "v:0 a:0 v:1" \
2358                     http://example.com/live/out_%v.m3u8
2359
2360           This example creates three hls variant streams. The first variant
2361           stream will be a video only stream with video bitrate 1000k, the
2362           second variant stream will be an audio only stream with bitrate 64k
2363           and the third variant stream will be a video only stream with
2364           bitrate 256k. Here, three media playlist with file names
2365           out_0.m3u8, out_1.m3u8 and out_2.m3u8 will be created.
2366
2367                   ffmpeg -re -i in.ts -b:v:0 1000k -b:v:1 256k -b:a:0 64k -b:a:1 32k \
2368                     -map 0:v -map 0:a -map 0:v -map 0:a -f hls -var_stream_map "v:0,a:0 v:1,a:1" \
2369                     http://example.com/live/vs_%v/out.m3u8
2370
2371           This example creates the variant streams in subdirectories. Here,
2372           the first media playlist is created at
2373           http://example.com/live/vs_0/out.m3u8 and the second one at
2374           http://example.com/live/vs_1/out.m3u8.
2375
2376                   ffmpeg -re -i in.ts -b:a:0 32k -b:a:1 64k -b:v:0 1000k -b:v:1 3000k  \
2377                     -map 0:a -map 0:a -map 0:v -map 0:v -f hls \
2378                     -var_stream_map "a:0,agroup:aud_low a:1,agroup:aud_high v:0,agroup:aud_low v:1,agroup:aud_high" \
2379                     -master_pl_name master.m3u8 \
2380                     http://example.com/live/out_%v.m3u8
2381
2382           This example creates two audio only and two video only variant
2383           streams. In addition to the #EXT-X-STREAM-INF tag for each variant
2384           stream in the master playlist, #EXT-X-MEDIA tag is also added for
2385           the two audio only variant streams and they are mapped to the two
2386           video only variant streams with audio group names 'aud_low' and
2387           'aud_high'.
2388
2389           By default, a single hls variant containing all the encoded streams
2390           is created.
2391
2392                   ffmpeg -re -i in.ts -b:a:0 32k -b:a:1 64k -b:v:0 1000k \
2393                     -map 0:a -map 0:a -map 0:v -f hls \
2394                     -var_stream_map "a:0,agroup:aud_low,default:yes a:1,agroup:aud_low v:0,agroup:aud_low" \
2395                     -master_pl_name master.m3u8 \
2396                     http://example.com/live/out_%v.m3u8
2397
2398           This example creates two audio only and one video only variant
2399           streams. In addition to the #EXT-X-STREAM-INF tag for each variant
2400           stream in the master playlist, #EXT-X-MEDIA tag is also added for
2401           the two audio only variant streams and they are mapped to the one
2402           video only variant streams with audio group name 'aud_low', and the
2403           audio group have default stat is NO or YES.
2404
2405           By default, a single hls variant containing all the encoded streams
2406           is created.
2407
2408                   ffmpeg -re -i in.ts -b:a:0 32k -b:a:1 64k -b:v:0 1000k \
2409                     -map 0:a -map 0:a -map 0:v -f hls \
2410                     -var_stream_map "a:0,agroup:aud_low,default:yes,language:ENG a:1,agroup:aud_low,language:CHN v:0,agroup:aud_low" \
2411                     -master_pl_name master.m3u8 \
2412                     http://example.com/live/out_%v.m3u8
2413
2414           This example creates two audio only and one video only variant
2415           streams. In addition to the #EXT-X-STREAM-INF tag for each variant
2416           stream in the master playlist, #EXT-X-MEDIA tag is also added for
2417           the two audio only variant streams and they are mapped to the one
2418           video only variant streams with audio group name 'aud_low', and the
2419           audio group have default stat is NO or YES, and one audio have and
2420           language is named ENG, the other audio language is named CHN.
2421
2422           By default, a single hls variant containing all the encoded streams
2423           is created.
2424
2425                   ffmpeg -y -i input_with_subtitle.mkv \
2426                    -b:v:0 5250k -c:v h264 -pix_fmt yuv420p -profile:v main -level 4.1 \
2427                    -b:a:0 256k \
2428                    -c:s webvtt -c:a mp2 -ar 48000 -ac 2 -map 0:v -map 0:a:0 -map 0:s:0 \
2429                    -f hls -var_stream_map "v:0,a:0,s:0,sgroup:subtitle" \
2430                    -master_pl_name master.m3u8 -t 300 -hls_time 10 -hls_init_time 4 -hls_list_size \
2431                    10 -master_pl_publish_rate 10  -hls_flags \
2432                    delete_segments+discont_start+split_by_time ./tmp/video.m3u8
2433
2434           This example adds "#EXT-X-MEDIA" tag with "TYPE=SUBTITLES" in the
2435           master playlist with webvtt subtitle group name 'subtitle'. Please
2436           make sure the input file has one text subtitle stream at least.
2437
2438       cc_stream_map
2439           Map string which specifies different closed captions groups and
2440           their attributes. The closed captions stream groups are separated
2441           by space.  Expected string format is like this "ccgroup:<group
2442           name>,instreamid:<INSTREAM-ID>,language:<language code> ....".
2443           'ccgroup' and 'instreamid' are mandatory attributes. 'language' is
2444           an optional attribute.  The closed captions groups configured using
2445           this option are mapped to different variant streams by providing
2446           the same 'ccgroup' name in the "var_stream_map" string. If
2447           "var_stream_map" is not set, then the first available ccgroup in
2448           "cc_stream_map" is mapped to the output variant stream. The
2449           examples for these two use cases are given below.
2450
2451                   ffmpeg -re -i in.ts -b:v 1000k -b:a 64k -a53cc 1 -f hls \
2452                     -cc_stream_map "ccgroup:cc,instreamid:CC1,language:en" \
2453                     -master_pl_name master.m3u8 \
2454                     http://example.com/live/out.m3u8
2455
2456           This example adds "#EXT-X-MEDIA" tag with "TYPE=CLOSED-CAPTIONS" in
2457           the master playlist with group name 'cc', language 'en' (english)
2458           and INSTREAM-ID 'CC1'. Also, it adds "CLOSED-CAPTIONS" attribute
2459           with group name 'cc' for the output variant stream.
2460
2461                   ffmpeg -re -i in.ts -b:v:0 1000k -b:v:1 256k -b:a:0 64k -b:a:1 32k \
2462                     -a53cc:0 1 -a53cc:1 1\
2463                     -map 0:v -map 0:a -map 0:v -map 0:a -f hls \
2464                     -cc_stream_map "ccgroup:cc,instreamid:CC1,language:en ccgroup:cc,instreamid:CC2,language:sp" \
2465                     -var_stream_map "v:0,a:0,ccgroup:cc v:1,a:1,ccgroup:cc" \
2466                     -master_pl_name master.m3u8 \
2467                     http://example.com/live/out_%v.m3u8
2468
2469           This example adds two "#EXT-X-MEDIA" tags with
2470           "TYPE=CLOSED-CAPTIONS" in the master playlist for the INSTREAM-IDs
2471           'CC1' and 'CC2'. Also, it adds "CLOSED-CAPTIONS" attribute with
2472           group name 'cc' for the two output variant streams.
2473
2474       master_pl_name
2475           Create HLS master playlist with the given name.
2476
2477                   ffmpeg -re -i in.ts -f hls -master_pl_name master.m3u8 http://example.com/live/out.m3u8
2478
2479           This example creates HLS master playlist with name master.m3u8 and
2480           it is published at http://example.com/live/
2481
2482       master_pl_publish_rate
2483           Publish master play list repeatedly every after specified number of
2484           segment intervals.
2485
2486                   ffmpeg -re -i in.ts -f hls -master_pl_name master.m3u8 \
2487                   -hls_time 2 -master_pl_publish_rate 30 http://example.com/live/out.m3u8
2488
2489           This example creates HLS master playlist with name master.m3u8 and
2490           keep publishing it repeatedly every after 30 segments i.e. every
2491           after 60s.
2492
2493       http_persistent
2494           Use persistent HTTP connections. Applicable only for HTTP output.
2495
2496       timeout
2497           Set timeout for socket I/O operations. Applicable only for HTTP
2498           output.
2499
2500       -ignore_io_errors
2501           Ignore IO errors during open, write and delete. Useful for long-
2502           duration runs with network output.
2503
2504       headers
2505           Set custom HTTP headers, can override built in default headers.
2506           Applicable only for HTTP output.
2507
2508   ico
2509       ICO file muxer.
2510
2511       Microsoft's icon file format (ICO) has some strict limitations that
2512       should be noted:
2513
2514       •   Size cannot exceed 256 pixels in any dimension
2515
2516       •   Only BMP and PNG images can be stored
2517
2518       •   If a BMP image is used, it must be one of the following pixel
2519           formats:
2520
2521                   BMP Bit Depth      FFmpeg Pixel Format
2522                   1bit               pal8
2523                   4bit               pal8
2524                   8bit               pal8
2525                   16bit              rgb555le
2526                   24bit              bgr24
2527                   32bit              bgra
2528
2529       •   If a BMP image is used, it must use the BITMAPINFOHEADER DIB header
2530
2531       •   If a PNG image is used, it must use the rgba pixel format
2532
2533   image2
2534       Image file muxer.
2535
2536       The image file muxer writes video frames to image files.
2537
2538       The output filenames are specified by a pattern, which can be used to
2539       produce sequentially numbered series of files.  The pattern may contain
2540       the string "%d" or "%0Nd", this string specifies the position of the
2541       characters representing a numbering in the filenames. If the form
2542       "%0Nd" is used, the string representing the number in each filename is
2543       0-padded to N digits. The literal character '%' can be specified in the
2544       pattern with the string "%%".
2545
2546       If the pattern contains "%d" or "%0Nd", the first filename of the file
2547       list specified will contain the number 1, all the following numbers
2548       will be sequential.
2549
2550       The pattern may contain a suffix which is used to automatically
2551       determine the format of the image files to write.
2552
2553       For example the pattern "img-%03d.bmp" will specify a sequence of
2554       filenames of the form img-001.bmp, img-002.bmp, ..., img-010.bmp, etc.
2555       The pattern "img%%-%d.jpg" will specify a sequence of filenames of the
2556       form img%-1.jpg, img%-2.jpg, ..., img%-10.jpg, etc.
2557
2558       The image muxer supports the .Y.U.V image file format. This format is
2559       special in that that each image frame consists of three files, for each
2560       of the YUV420P components. To read or write this image file format,
2561       specify the name of the '.Y' file. The muxer will automatically open
2562       the '.U' and '.V' files as required.
2563
2564       Options
2565
2566       frame_pts
2567           If set to 1, expand the filename with pts from pkt->pts.  Default
2568           value is 0.
2569
2570       start_number
2571           Start the sequence from the specified number. Default value is 1.
2572
2573       update
2574           If set to 1, the filename will always be interpreted as just a
2575           filename, not a pattern, and the corresponding file will be
2576           continuously overwritten with new images. Default value is 0.
2577
2578       strftime
2579           If set to 1, expand the filename with date and time information
2580           from strftime(). Default value is 0.
2581
2582       atomic_writing
2583           Write output to a temporary file, which is renamed to target
2584           filename once writing is completed. Default is disabled.
2585
2586       protocol_opts options_list
2587           Set protocol options as a :-separated list of key=value parameters.
2588           Values containing the ":" special character must be escaped.
2589
2590       Examples
2591
2592       The following example shows how to use ffmpeg for creating a sequence
2593       of files img-001.jpeg, img-002.jpeg, ..., taking one image every second
2594       from the input video:
2595
2596               ffmpeg -i in.avi -vsync cfr -r 1 -f image2 'img-%03d.jpeg'
2597
2598       Note that with ffmpeg, if the format is not specified with the "-f"
2599       option and the output filename specifies an image file format, the
2600       image2 muxer is automatically selected, so the previous command can be
2601       written as:
2602
2603               ffmpeg -i in.avi -vsync cfr -r 1 'img-%03d.jpeg'
2604
2605       Note also that the pattern must not necessarily contain "%d" or "%0Nd",
2606       for example to create a single image file img.jpeg from the start of
2607       the input video you can employ the command:
2608
2609               ffmpeg -i in.avi -f image2 -frames:v 1 img.jpeg
2610
2611       The strftime option allows you to expand the filename with date and
2612       time information. Check the documentation of the strftime() function
2613       for the syntax.
2614
2615       For example to generate image files from the strftime()
2616       "%Y-%m-%d_%H-%M-%S" pattern, the following ffmpeg command can be used:
2617
2618               ffmpeg -f v4l2 -r 1 -i /dev/video0 -f image2 -strftime 1 "%Y-%m-%d_%H-%M-%S.jpg"
2619
2620       You can set the file name with current frame's PTS:
2621
2622               ffmpeg -f v4l2 -r 1 -i /dev/video0 -copyts -f image2 -frame_pts true %d.jpg"
2623
2624       A more complex example is to publish contents of your desktop directly
2625       to a WebDAV server every second:
2626
2627               ffmpeg -f x11grab -framerate 1 -i :0.0 -q:v 6 -update 1 -protocol_opts method=PUT http://example.com/desktop.jpg
2628
2629   matroska
2630       Matroska container muxer.
2631
2632       This muxer implements the matroska and webm container specs.
2633
2634       Metadata
2635
2636       The recognized metadata settings in this muxer are:
2637
2638       title
2639           Set title name provided to a single track. This gets mapped to the
2640           FileDescription element for a stream written as attachment.
2641
2642       language
2643           Specify the language of the track in the Matroska languages form.
2644
2645           The language can be either the 3 letters bibliographic ISO-639-2
2646           (ISO 639-2/B) form (like "fre" for French), or a language code
2647           mixed with a country code for specialities in languages (like "fre-
2648           ca" for Canadian French).
2649
2650       stereo_mode
2651           Set stereo 3D video layout of two views in a single video track.
2652
2653           The following values are recognized:
2654
2655           mono
2656               video is not stereo
2657
2658           left_right
2659               Both views are arranged side by side, Left-eye view is on the
2660               left
2661
2662           bottom_top
2663               Both views are arranged in top-bottom orientation, Left-eye
2664               view is at bottom
2665
2666           top_bottom
2667               Both views are arranged in top-bottom orientation, Left-eye
2668               view is on top
2669
2670           checkerboard_rl
2671               Each view is arranged in a checkerboard interleaved pattern,
2672               Left-eye view being first
2673
2674           checkerboard_lr
2675               Each view is arranged in a checkerboard interleaved pattern,
2676               Right-eye view being first
2677
2678           row_interleaved_rl
2679               Each view is constituted by a row based interleaving, Right-eye
2680               view is first row
2681
2682           row_interleaved_lr
2683               Each view is constituted by a row based interleaving, Left-eye
2684               view is first row
2685
2686           col_interleaved_rl
2687               Both views are arranged in a column based interleaving manner,
2688               Right-eye view is first column
2689
2690           col_interleaved_lr
2691               Both views are arranged in a column based interleaving manner,
2692               Left-eye view is first column
2693
2694           anaglyph_cyan_red
2695               All frames are in anaglyph format viewable through red-cyan
2696               filters
2697
2698           right_left
2699               Both views are arranged side by side, Right-eye view is on the
2700               left
2701
2702           anaglyph_green_magenta
2703               All frames are in anaglyph format viewable through green-
2704               magenta filters
2705
2706           block_lr
2707               Both eyes laced in one Block, Left-eye view is first
2708
2709           block_rl
2710               Both eyes laced in one Block, Right-eye view is first
2711
2712       For example a 3D WebM clip can be created using the following command
2713       line:
2714
2715               ffmpeg -i sample_left_right_clip.mpg -an -c:v libvpx -metadata stereo_mode=left_right -y stereo_clip.webm
2716
2717       Options
2718
2719       This muxer supports the following options:
2720
2721       reserve_index_space
2722           By default, this muxer writes the index for seeking (called cues in
2723           Matroska terms) at the end of the file, because it cannot know in
2724           advance how much space to leave for the index at the beginning of
2725           the file. However for some use cases -- e.g.  streaming where
2726           seeking is possible but slow -- it is useful to put the index at
2727           the beginning of the file.
2728
2729           If this option is set to a non-zero value, the muxer will reserve a
2730           given amount of space in the file header and then try to write the
2731           cues there when the muxing finishes. If the reserved space does not
2732           suffice, no Cues will be written, the file will be finalized and
2733           writing the trailer will return an error.  A safe size for most use
2734           cases should be about 50kB per hour of video.
2735
2736           Note that cues are only written if the output is seekable and this
2737           option will have no effect if it is not.
2738
2739       cues_to_front
2740           If set, the muxer will write the index at the beginning of the file
2741           by shifting the main data if necessary. This can be combined with
2742           reserve_index_space in which case the data is only shifted if the
2743           initially reserved space turns out to be insufficient.
2744
2745           This option is ignored if the output is unseekable.
2746
2747       default_mode
2748           This option controls how the FlagDefault of the output tracks will
2749           be set.  It influences which tracks players should play by default.
2750           The default mode is passthrough.
2751
2752           infer
2753               Every track with disposition default will have the FlagDefault
2754               set.  Additionally, for each type of track (audio, video or
2755               subtitle), if no track with disposition default of this type
2756               exists, then the first track of this type will be marked as
2757               default (if existing). This ensures that the default flag is
2758               set in a sensible way even if the input originated from
2759               containers that lack the concept of default tracks.
2760
2761           infer_no_subs
2762               This mode is the same as infer except that if no subtitle track
2763               with disposition default exists, no subtitle track will be
2764               marked as default.
2765
2766           passthrough
2767               In this mode the FlagDefault is set if and only if the
2768               AV_DISPOSITION_DEFAULT flag is set in the disposition of the
2769               corresponding stream.
2770
2771       flipped_raw_rgb
2772           If set to true, store positive height for raw RGB bitmaps, which
2773           indicates bitmap is stored bottom-up. Note that this option does
2774           not flip the bitmap which has to be done manually beforehand, e.g.
2775           by using the vflip filter.  Default is false and indicates bitmap
2776           is stored top down.
2777
2778   md5
2779       MD5 testing format.
2780
2781       This is a variant of the hash muxer. Unlike that muxer, it defaults to
2782       using the MD5 hash function.
2783
2784       Examples
2785
2786       To compute the MD5 hash of the input converted to raw audio and video,
2787       and store it in the file out.md5:
2788
2789               ffmpeg -i INPUT -f md5 out.md5
2790
2791       You can print the MD5 to stdout with the command:
2792
2793               ffmpeg -i INPUT -f md5 -
2794
2795       See also the hash and framemd5 muxers.
2796
2797   mov, mp4, ismv
2798       MOV/MP4/ISMV (Smooth Streaming) muxer.
2799
2800       The mov/mp4/ismv muxer supports fragmentation. Normally, a MOV/MP4 file
2801       has all the metadata about all packets stored in one location (written
2802       at the end of the file, it can be moved to the start for better
2803       playback by adding faststart to the movflags, or using the qt-faststart
2804       tool). A fragmented file consists of a number of fragments, where
2805       packets and metadata about these packets are stored together. Writing a
2806       fragmented file has the advantage that the file is decodable even if
2807       the writing is interrupted (while a normal MOV/MP4 is undecodable if it
2808       is not properly finished), and it requires less memory when writing
2809       very long files (since writing normal MOV/MP4 files stores info about
2810       every single packet in memory until the file is closed). The downside
2811       is that it is less compatible with other applications.
2812
2813       Options
2814
2815       Fragmentation is enabled by setting one of the AVOptions that define
2816       how to cut the file into fragments:
2817
2818       -moov_size bytes
2819           Reserves space for the moov atom at the beginning of the file
2820           instead of placing the moov atom at the end. If the space reserved
2821           is insufficient, muxing will fail.
2822
2823       -movflags frag_keyframe
2824           Start a new fragment at each video keyframe.
2825
2826       -frag_duration duration
2827           Create fragments that are duration microseconds long.
2828
2829       -frag_size size
2830           Create fragments that contain up to size bytes of payload data.
2831
2832       -movflags frag_custom
2833           Allow the caller to manually choose when to cut fragments, by
2834           calling "av_write_frame(ctx, NULL)" to write a fragment with the
2835           packets written so far. (This is only useful with other
2836           applications integrating libavformat, not from ffmpeg.)
2837
2838       -min_frag_duration duration
2839           Don't create fragments that are shorter than duration microseconds
2840           long.
2841
2842       If more than one condition is specified, fragments are cut when one of
2843       the specified conditions is fulfilled. The exception to this is
2844       "-min_frag_duration", which has to be fulfilled for any of the other
2845       conditions to apply.
2846
2847       Additionally, the way the output file is written can be adjusted
2848       through a few other options:
2849
2850       -movflags empty_moov
2851           Write an initial moov atom directly at the start of the file,
2852           without describing any samples in it. Generally, an mdat/moov pair
2853           is written at the start of the file, as a normal MOV/MP4 file,
2854           containing only a short portion of the file. With this option set,
2855           there is no initial mdat atom, and the moov atom only describes the
2856           tracks but has a zero duration.
2857
2858           This option is implicitly set when writing ismv (Smooth Streaming)
2859           files.
2860
2861       -movflags separate_moof
2862           Write a separate moof (movie fragment) atom for each track.
2863           Normally, packets for all tracks are written in a moof atom (which
2864           is slightly more efficient), but with this option set, the muxer
2865           writes one moof/mdat pair for each track, making it easier to
2866           separate tracks.
2867
2868           This option is implicitly set when writing ismv (Smooth Streaming)
2869           files.
2870
2871       -movflags skip_sidx
2872           Skip writing of sidx atom. When bitrate overhead due to sidx atom
2873           is high, this option could be used for cases where sidx atom is not
2874           mandatory.  When global_sidx flag is enabled, this option will be
2875           ignored.
2876
2877       -movflags faststart
2878           Run a second pass moving the index (moov atom) to the beginning of
2879           the file.  This operation can take a while, and will not work in
2880           various situations such as fragmented output, thus it is not
2881           enabled by default.
2882
2883       -movflags rtphint
2884           Add RTP hinting tracks to the output file.
2885
2886       -movflags disable_chpl
2887           Disable Nero chapter markers (chpl atom).  Normally, both Nero
2888           chapters and a QuickTime chapter track are written to the file.
2889           With this option set, only the QuickTime chapter track will be
2890           written. Nero chapters can cause failures when the file is
2891           reprocessed with certain tagging programs, like mp3Tag 2.61a and
2892           iTunes 11.3, most likely other versions are affected as well.
2893
2894       -movflags omit_tfhd_offset
2895           Do not write any absolute base_data_offset in tfhd atoms. This
2896           avoids tying fragments to absolute byte positions in the
2897           file/streams.
2898
2899       -movflags default_base_moof
2900           Similarly to the omit_tfhd_offset, this flag avoids writing the
2901           absolute base_data_offset field in tfhd atoms, but does so by using
2902           the new default-base-is-moof flag instead. This flag is new from
2903           14496-12:2012. This may make the fragments easier to parse in
2904           certain circumstances (avoiding basing track fragment location
2905           calculations on the implicit end of the previous track fragment).
2906
2907       -write_tmcd
2908           Specify "on" to force writing a timecode track, "off" to disable it
2909           and "auto" to write a timecode track only for mov and mp4 output
2910           (default).
2911
2912       -movflags negative_cts_offsets
2913           Enables utilization of version 1 of the CTTS box, in which the CTS
2914           offsets can be negative. This enables the initial sample to have
2915           DTS/CTS of zero, and reduces the need for edit lists for some cases
2916           such as video tracks with B-frames. Additionally, eases conformance
2917           with the DASH-IF interoperability guidelines.
2918
2919           This option is implicitly set when writing ismv (Smooth Streaming)
2920           files.
2921
2922       -write_btrt bool
2923           Force or disable writing bitrate box inside stsd box of a track.
2924           The box contains decoding buffer size (in bytes), maximum bitrate
2925           and average bitrate for the track. The box will be skipped if none
2926           of these values can be computed.  Default is -1 or "auto", which
2927           will write the box only in MP4 mode.
2928
2929       -write_prft
2930           Write producer time reference box (PRFT) with a specified time
2931           source for the NTP field in the PRFT box. Set value as wallclock to
2932           specify timesource as wallclock time and pts to specify timesource
2933           as input packets' PTS values.
2934
2935           Setting value to pts is applicable only for a live encoding use
2936           case, where PTS values are set as as wallclock time at the source.
2937           For example, an encoding use case with decklink capture source
2938           where video_pts and audio_pts are set to abs_wallclock.
2939
2940       -empty_hdlr_name bool
2941           Enable to skip writing the name inside a "hdlr" box.  Default is
2942           "false".
2943
2944       -movie_timescale scale
2945           Set the timescale written in the movie header box ("mvhd").  Range
2946           is 1 to INT_MAX. Default is 1000.
2947
2948       -video_track_timescale scale
2949           Set the timescale used for video tracks. Range is 0 to INT_MAX.  If
2950           set to 0, the timescale is automatically set based on the native
2951           stream time base. Default is 0.
2952
2953       Example
2954
2955       Smooth Streaming content can be pushed in real time to a publishing
2956       point on IIS with this muxer. Example:
2957
2958               ffmpeg -re <<normal input/transcoding options>> -movflags isml+frag_keyframe -f ismv http://server/publishingpoint.isml/Streams(Encoder1)
2959
2960   mp3
2961       The MP3 muxer writes a raw MP3 stream with the following optional
2962       features:
2963
2964       •   An ID3v2 metadata header at the beginning (enabled by default).
2965           Versions 2.3 and 2.4 are supported, the "id3v2_version" private
2966           option controls which one is used (3 or 4). Setting "id3v2_version"
2967           to 0 disables the ID3v2 header completely.
2968
2969           The muxer supports writing attached pictures (APIC frames) to the
2970           ID3v2 header.  The pictures are supplied to the muxer in form of a
2971           video stream with a single packet. There can be any number of those
2972           streams, each will correspond to a single APIC frame.  The stream
2973           metadata tags title and comment map to APIC description and picture
2974           type respectively. See <http://id3.org/id3v2.4.0-frames> for
2975           allowed picture types.
2976
2977           Note that the APIC frames must be written at the beginning, so the
2978           muxer will buffer the audio frames until it gets all the pictures.
2979           It is therefore advised to provide the pictures as soon as possible
2980           to avoid excessive buffering.
2981
2982       •   A Xing/LAME frame right after the ID3v2 header (if present). It is
2983           enabled by default, but will be written only if the output is
2984           seekable. The "write_xing" private option can be used to disable
2985           it.  The frame contains various information that may be useful to
2986           the decoder, like the audio duration or encoder delay.
2987
2988       •   A legacy ID3v1 tag at the end of the file (disabled by default). It
2989           may be enabled with the "write_id3v1" private option, but as its
2990           capabilities are very limited, its usage is not recommended.
2991
2992       Examples:
2993
2994       Write an mp3 with an ID3v2.3 header and an ID3v1 footer:
2995
2996               ffmpeg -i INPUT -id3v2_version 3 -write_id3v1 1 out.mp3
2997
2998       To attach a picture to an mp3 file select both the audio and the
2999       picture stream with "map":
3000
3001               ffmpeg -i input.mp3 -i cover.png -c copy -map 0 -map 1
3002               -metadata:s:v title="Album cover" -metadata:s:v comment="Cover (Front)" out.mp3
3003
3004       Write a "clean" MP3 without any extra features:
3005
3006               ffmpeg -i input.wav -write_xing 0 -id3v2_version 0 out.mp3
3007
3008   mpegts
3009       MPEG transport stream muxer.
3010
3011       This muxer implements ISO 13818-1 and part of ETSI EN 300 468.
3012
3013       The recognized metadata settings in mpegts muxer are "service_provider"
3014       and "service_name". If they are not set the default for
3015       "service_provider" is FFmpeg and the default for "service_name" is
3016       Service01.
3017
3018       Options
3019
3020       The muxer options are:
3021
3022       mpegts_transport_stream_id integer
3023           Set the transport_stream_id. This identifies a transponder in DVB.
3024           Default is 0x0001.
3025
3026       mpegts_original_network_id integer
3027           Set the original_network_id. This is unique identifier of a network
3028           in DVB. Its main use is in the unique identification of a service
3029           through the path Original_Network_ID, Transport_Stream_ID. Default
3030           is 0x0001.
3031
3032       mpegts_service_id integer
3033           Set the service_id, also known as program in DVB. Default is
3034           0x0001.
3035
3036       mpegts_service_type integer
3037           Set the program service_type. Default is "digital_tv".  Accepts the
3038           following options:
3039
3040           hex_value
3041               Any hexadecimal value between 0x01 and 0xff as defined in ETSI
3042               300 468.
3043
3044           digital_tv
3045               Digital TV service.
3046
3047           digital_radio
3048               Digital Radio service.
3049
3050           teletext
3051               Teletext service.
3052
3053           advanced_codec_digital_radio
3054               Advanced Codec Digital Radio service.
3055
3056           mpeg2_digital_hdtv
3057               MPEG2 Digital HDTV service.
3058
3059           advanced_codec_digital_sdtv
3060               Advanced Codec Digital SDTV service.
3061
3062           advanced_codec_digital_hdtv
3063               Advanced Codec Digital HDTV service.
3064
3065       mpegts_pmt_start_pid integer
3066           Set the first PID for PMTs. Default is 0x1000, minimum is 0x0020,
3067           maximum is 0x1ffa. This option has no effect in m2ts mode where the
3068           PMT PID is fixed 0x0100.
3069
3070       mpegts_start_pid integer
3071           Set the first PID for elementary streams. Default is 0x0100,
3072           minimum is 0x0020, maximum is 0x1ffa. This option has no effect in
3073           m2ts mode where the elementary stream PIDs are fixed.
3074
3075       mpegts_m2ts_mode boolean
3076           Enable m2ts mode if set to 1. Default value is -1 which disables
3077           m2ts mode.
3078
3079       muxrate integer
3080           Set a constant muxrate. Default is VBR.
3081
3082       pes_payload_size integer
3083           Set minimum PES packet payload in bytes. Default is 2930.
3084
3085       mpegts_flags flags
3086           Set mpegts flags. Accepts the following options:
3087
3088           resend_headers
3089               Reemit PAT/PMT before writing the next packet.
3090
3091           latm
3092               Use LATM packetization for AAC.
3093
3094           pat_pmt_at_frames
3095               Reemit PAT and PMT at each video frame.
3096
3097           system_b
3098               Conform to System B (DVB) instead of System A (ATSC).
3099
3100           initial_discontinuity
3101               Mark the initial packet of each stream as discontinuity.
3102
3103           nit Emit NIT table.
3104
3105           omit_rai
3106               Disable writing of random access indicator.
3107
3108       mpegts_copyts boolean
3109           Preserve original timestamps, if value is set to 1. Default value
3110           is -1, which results in shifting timestamps so that they start from
3111           0.
3112
3113       omit_video_pes_length boolean
3114           Omit the PES packet length for video packets. Default is 1 (true).
3115
3116       pcr_period integer
3117           Override the default PCR retransmission time in milliseconds.
3118           Default is -1 which means that the PCR interval will be determined
3119           automatically: 20 ms is used for CBR streams, the highest multiple
3120           of the frame duration which is less than 100 ms is used for VBR
3121           streams.
3122
3123       pat_period duration
3124           Maximum time in seconds between PAT/PMT tables. Default is 0.1.
3125
3126       sdt_period duration
3127           Maximum time in seconds between SDT tables. Default is 0.5.
3128
3129       nit_period duration
3130           Maximum time in seconds between NIT tables. Default is 0.5.
3131
3132       tables_version integer
3133           Set PAT, PMT, SDT and NIT version (default 0, valid values are from
3134           0 to 31, inclusively).  This option allows updating stream
3135           structure so that standard consumer may detect the change. To do
3136           so, reopen output "AVFormatContext" (in case of API usage) or
3137           restart ffmpeg instance, cyclically changing tables_version value:
3138
3139                   ffmpeg -i source1.ts -codec copy -f mpegts -tables_version 0 udp://1.1.1.1:1111
3140                   ffmpeg -i source2.ts -codec copy -f mpegts -tables_version 1 udp://1.1.1.1:1111
3141                   ...
3142                   ffmpeg -i source3.ts -codec copy -f mpegts -tables_version 31 udp://1.1.1.1:1111
3143                   ffmpeg -i source1.ts -codec copy -f mpegts -tables_version 0 udp://1.1.1.1:1111
3144                   ffmpeg -i source2.ts -codec copy -f mpegts -tables_version 1 udp://1.1.1.1:1111
3145                   ...
3146
3147       Example
3148
3149               ffmpeg -i file.mpg -c copy \
3150                    -mpegts_original_network_id 0x1122 \
3151                    -mpegts_transport_stream_id 0x3344 \
3152                    -mpegts_service_id 0x5566 \
3153                    -mpegts_pmt_start_pid 0x1500 \
3154                    -mpegts_start_pid 0x150 \
3155                    -metadata service_provider="Some provider" \
3156                    -metadata service_name="Some Channel" \
3157                    out.ts
3158
3159   mxf, mxf_d10, mxf_opatom
3160       MXF muxer.
3161
3162       Options
3163
3164       The muxer options are:
3165
3166       store_user_comments bool
3167           Set if user comments should be stored if available or never.  IRT
3168           D-10 does not allow user comments. The default is thus to write
3169           them for mxf and mxf_opatom but not for mxf_d10
3170
3171   null
3172       Null muxer.
3173
3174       This muxer does not generate any output file, it is mainly useful for
3175       testing or benchmarking purposes.
3176
3177       For example to benchmark decoding with ffmpeg you can use the command:
3178
3179               ffmpeg -benchmark -i INPUT -f null out.null
3180
3181       Note that the above command does not read or write the out.null file,
3182       but specifying the output file is required by the ffmpeg syntax.
3183
3184       Alternatively you can write the command as:
3185
3186               ffmpeg -benchmark -i INPUT -f null -
3187
3188   nut
3189       -syncpoints flags
3190           Change the syncpoint usage in nut:
3191
3192           default use the normal low-overhead seeking aids.
3193           none do not use the syncpoints at all, reducing the overhead but
3194           making the stream non-seekable;
3195                   Use of this option is not recommended, as the resulting files are very damage
3196                   sensitive and seeking is not possible. Also in general the overhead from
3197                   syncpoints is negligible. Note, -C<write_index> 0 can be used to disable
3198                   all growing data tables, allowing to mux endless streams with limited memory
3199                   and without these disadvantages.
3200
3201           timestamped extend the syncpoint with a wallclock field.
3202
3203           The none and timestamped flags are experimental.
3204
3205       -write_index bool
3206           Write index at the end, the default is to write an index.
3207
3208               ffmpeg -i INPUT -f_strict experimental -syncpoints none - | processor
3209
3210   ogg
3211       Ogg container muxer.
3212
3213       -page_duration duration
3214           Preferred page duration, in microseconds. The muxer will attempt to
3215           create pages that are approximately duration microseconds long.
3216           This allows the user to compromise between seek granularity and
3217           container overhead. The default is 1 second. A value of 0 will fill
3218           all segments, making pages as large as possible. A value of 1 will
3219           effectively use 1 packet-per-page in most situations, giving a
3220           small seek granularity at the cost of additional container
3221           overhead.
3222
3223       -serial_offset value
3224           Serial value from which to set the streams serial number.  Setting
3225           it to different and sufficiently large values ensures that the
3226           produced ogg files can be safely chained.
3227
3228   raw muxers
3229       Raw muxers accept a single stream matching the designated codec. They
3230       do not store timestamps or metadata.  The recognized extension is the
3231       same as the muxer name unless indicated otherwise.
3232
3233       ac3
3234
3235       Dolby Digital, also known as AC-3, audio.
3236
3237       adx
3238
3239       CRI Middleware ADX audio.
3240
3241       This muxer will write out the total sample count near the start of the
3242       first packet when the output is seekable and the count can be stored in
3243       32 bits.
3244
3245       aptx
3246
3247       aptX (Audio Processing Technology for Bluetooth) audio.
3248
3249       aptx_hd
3250
3251       aptX HD (Audio Processing Technology for Bluetooth) audio.
3252
3253       Extensions: aptxhd
3254
3255       avs2
3256
3257       AVS2-P2/IEEE1857.4 video.
3258
3259       Extensions: avs, avs2
3260
3261       cavsvideo
3262
3263       Chinese AVS (Audio Video Standard) video.
3264
3265       Extensions: cavs
3266
3267       codec2raw
3268
3269       Codec 2 audio.
3270
3271       No extension is registered so format name has to be supplied e.g. with
3272       the ffmpeg CLI tool "-f codec2raw".
3273
3274       data
3275
3276       Data muxer accepts a single stream with any codec of any type.  The
3277       input stream has to be selected using the "-map" option with the ffmpeg
3278       CLI tool.
3279
3280       No extension is registered so format name has to be supplied e.g. with
3281       the ffmpeg CLI tool "-f data".
3282
3283       dirac
3284
3285       BBC Dirac video. The Dirac Pro codec is a subset and is standardized as
3286       SMPTE VC-2.
3287
3288       Extensions: drc, vc2
3289
3290       dnxhd
3291
3292       Avid DNxHD video. It is standardized as SMPTE VC-3. Accepts DNxHR
3293       streams.
3294
3295       Extensions: dnxhd, dnxhr
3296
3297       dts
3298
3299       DTS Coherent Acoustics (DCA) audio.
3300
3301       eac3
3302
3303       Dolby Digital Plus, also known as Enhanced AC-3, audio.
3304
3305       g722
3306
3307       ITU-T G.722 audio.
3308
3309       g723_1
3310
3311       ITU-T G.723.1 audio.
3312
3313       Extensions: tco, rco
3314
3315       g726
3316
3317       ITU-T G.726 big-endian ("left-justified") audio.
3318
3319       No extension is registered so format name has to be supplied e.g. with
3320       the ffmpeg CLI tool "-f g726".
3321
3322       g726le
3323
3324       ITU-T G.726 little-endian ("right-justified") audio.
3325
3326       No extension is registered so format name has to be supplied e.g. with
3327       the ffmpeg CLI tool "-f g726le".
3328
3329       gsm
3330
3331       Global System for Mobile Communications audio.
3332
3333       h261
3334
3335       ITU-T H.261 video.
3336
3337       h263
3338
3339       ITU-T H.263 / H.263-1996, H.263+ / H.263-1998 / H.263 version 2 video.
3340
3341       h264
3342
3343       ITU-T H.264 / MPEG-4 Part 10 AVC video. Bitstream shall be converted to
3344       Annex B syntax if it's in length-prefixed mode.
3345
3346       Extensions: h264, 264
3347
3348       hevc
3349
3350       ITU-T H.265 / MPEG-H Part 2 HEVC video. Bitstream shall be converted to
3351       Annex B syntax if it's in length-prefixed mode.
3352
3353       Extensions: hevc, h265, 265
3354
3355       m4v
3356
3357       MPEG-4 Part 2 video.
3358
3359       mjpeg
3360
3361       Motion JPEG video.
3362
3363       Extensions: mjpg, mjpeg
3364
3365       mlp
3366
3367       Meridian Lossless Packing, also known as Packed PCM, audio.
3368
3369       mp2
3370
3371       MPEG-1 Audio Layer II audio.
3372
3373       Extensions: mp2, m2a, mpa
3374
3375       mpeg1video
3376
3377       MPEG-1 Part 2 video.
3378
3379       Extensions: mpg, mpeg, m1v
3380
3381       mpeg2video
3382
3383       ITU-T H.262 / MPEG-2 Part 2 video.
3384
3385       Extensions: m2v
3386
3387       obu
3388
3389       AV1 low overhead Open Bitstream Units muxer. Temporal delimiter OBUs
3390       will be inserted in all temporal units of the stream.
3391
3392       rawvideo
3393
3394       Raw uncompressed video.
3395
3396       Extensions: yuv, rgb
3397
3398       sbc
3399
3400       Bluetooth SIG low-complexity subband codec audio.
3401
3402       Extensions: sbc, msbc
3403
3404       truehd
3405
3406       Dolby TrueHD audio.
3407
3408       Extensions: thd
3409
3410       vc1
3411
3412       SMPTE 421M / VC-1 video.
3413
3414   segment, stream_segment, ssegment
3415       Basic stream segmenter.
3416
3417       This muxer outputs streams to a number of separate files of nearly
3418       fixed duration. Output filename pattern can be set in a fashion similar
3419       to image2, or by using a "strftime" template if the strftime option is
3420       enabled.
3421
3422       "stream_segment" is a variant of the muxer used to write to streaming
3423       output formats, i.e. which do not require global headers, and is
3424       recommended for outputting e.g. to MPEG transport stream segments.
3425       "ssegment" is a shorter alias for "stream_segment".
3426
3427       Every segment starts with a keyframe of the selected reference stream,
3428       which is set through the reference_stream option.
3429
3430       Note that if you want accurate splitting for a video file, you need to
3431       make the input key frames correspond to the exact splitting times
3432       expected by the segmenter, or the segment muxer will start the new
3433       segment with the key frame found next after the specified start time.
3434
3435       The segment muxer works best with a single constant frame rate video.
3436
3437       Optionally it can generate a list of the created segments, by setting
3438       the option segment_list. The list type is specified by the
3439       segment_list_type option. The entry filenames in the segment list are
3440       set by default to the basename of the corresponding segment files.
3441
3442       See also the hls muxer, which provides a more specific implementation
3443       for HLS segmentation.
3444
3445       Options
3446
3447       The segment muxer supports the following options:
3448
3449       increment_tc 1|0
3450           if set to 1, increment timecode between each segment If this is
3451           selected, the input need to have a timecode in the first video
3452           stream. Default value is 0.
3453
3454       reference_stream specifier
3455           Set the reference stream, as specified by the string specifier.  If
3456           specifier is set to "auto", the reference is chosen automatically.
3457           Otherwise it must be a stream specifier (see the ``Stream
3458           specifiers'' chapter in the ffmpeg manual) which specifies the
3459           reference stream. The default value is "auto".
3460
3461       segment_format format
3462           Override the inner container format, by default it is guessed by
3463           the filename extension.
3464
3465       segment_format_options options_list
3466           Set output format options using a :-separated list of key=value
3467           parameters. Values containing the ":" special character must be
3468           escaped.
3469
3470       segment_list name
3471           Generate also a listfile named name. If not specified no listfile
3472           is generated.
3473
3474       segment_list_flags flags
3475           Set flags affecting the segment list generation.
3476
3477           It currently supports the following flags:
3478
3479           cache
3480               Allow caching (only affects M3U8 list files).
3481
3482           live
3483               Allow live-friendly file generation.
3484
3485       segment_list_size size
3486           Update the list file so that it contains at most size segments. If
3487           0 the list file will contain all the segments. Default value is 0.
3488
3489       segment_list_entry_prefix prefix
3490           Prepend prefix to each entry. Useful to generate absolute paths.
3491           By default no prefix is applied.
3492
3493       segment_list_type type
3494           Select the listing format.
3495
3496           The following values are recognized:
3497
3498           flat
3499               Generate a flat list for the created segments, one segment per
3500               line.
3501
3502           csv, ext
3503               Generate a list for the created segments, one segment per line,
3504               each line matching the format (comma-separated values):
3505
3506                       <segment_filename>,<segment_start_time>,<segment_end_time>
3507
3508               segment_filename is the name of the output file generated by
3509               the muxer according to the provided pattern. CSV escaping
3510               (according to RFC4180) is applied if required.
3511
3512               segment_start_time and segment_end_time specify the segment
3513               start and end time expressed in seconds.
3514
3515               A list file with the suffix ".csv" or ".ext" will auto-select
3516               this format.
3517
3518               ext is deprecated in favor or csv.
3519
3520           ffconcat
3521               Generate an ffconcat file for the created segments. The
3522               resulting file can be read using the FFmpeg concat demuxer.
3523
3524               A list file with the suffix ".ffcat" or ".ffconcat" will auto-
3525               select this format.
3526
3527           m3u8
3528               Generate an extended M3U8 file, version 3, compliant with
3529               <http://tools.ietf.org/id/draft-pantos-http-live-streaming>.
3530
3531               A list file with the suffix ".m3u8" will auto-select this
3532               format.
3533
3534           If not specified the type is guessed from the list file name
3535           suffix.
3536
3537       segment_time time
3538           Set segment duration to time, the value must be a duration
3539           specification. Default value is "2". See also the segment_times
3540           option.
3541
3542           Note that splitting may not be accurate, unless you force the
3543           reference stream key-frames at the given time. See the introductory
3544           notice and the examples below.
3545
3546       min_seg_duration time
3547           Set minimum segment duration to time, the value must be a duration
3548           specification. This prevents the muxer ending segments at a
3549           duration below this value. Only effective with "segment_time".
3550           Default value is "0".
3551
3552       segment_atclocktime 1|0
3553           If set to "1" split at regular clock time intervals starting from
3554           00:00 o'clock. The time value specified in segment_time is used for
3555           setting the length of the splitting interval.
3556
3557           For example with segment_time set to "900" this makes it possible
3558           to create files at 12:00 o'clock, 12:15, 12:30, etc.
3559
3560           Default value is "0".
3561
3562       segment_clocktime_offset duration
3563           Delay the segment splitting times with the specified duration when
3564           using segment_atclocktime.
3565
3566           For example with segment_time set to "900" and
3567           segment_clocktime_offset set to "300" this makes it possible to
3568           create files at 12:05, 12:20, 12:35, etc.
3569
3570           Default value is "0".
3571
3572       segment_clocktime_wrap_duration duration
3573           Force the segmenter to only start a new segment if a packet reaches
3574           the muxer within the specified duration after the segmenting clock
3575           time. This way you can make the segmenter more resilient to
3576           backward local time jumps, such as leap seconds or transition to
3577           standard time from daylight savings time.
3578
3579           Default is the maximum possible duration which means starting a new
3580           segment regardless of the elapsed time since the last clock time.
3581
3582       segment_time_delta delta
3583           Specify the accuracy time when selecting the start time for a
3584           segment, expressed as a duration specification. Default value is
3585           "0".
3586
3587           When delta is specified a key-frame will start a new segment if its
3588           PTS satisfies the relation:
3589
3590                   PTS >= start_time - time_delta
3591
3592           This option is useful when splitting video content, which is always
3593           split at GOP boundaries, in case a key frame is found just before
3594           the specified split time.
3595
3596           In particular may be used in combination with the ffmpeg option
3597           force_key_frames. The key frame times specified by force_key_frames
3598           may not be set accurately because of rounding issues, with the
3599           consequence that a key frame time may result set just before the
3600           specified time. For constant frame rate videos a value of
3601           1/(2*frame_rate) should address the worst case mismatch between the
3602           specified time and the time set by force_key_frames.
3603
3604       segment_times times
3605           Specify a list of split points. times contains a list of comma
3606           separated duration specifications, in increasing order. See also
3607           the segment_time option.
3608
3609       segment_frames frames
3610           Specify a list of split video frame numbers. frames contains a list
3611           of comma separated integer numbers, in increasing order.
3612
3613           This option specifies to start a new segment whenever a reference
3614           stream key frame is found and the sequential number (starting from
3615           0) of the frame is greater or equal to the next value in the list.
3616
3617       segment_wrap limit
3618           Wrap around segment index once it reaches limit.
3619
3620       segment_start_number number
3621           Set the sequence number of the first segment. Defaults to 0.
3622
3623       strftime 1|0
3624           Use the "strftime" function to define the name of the new segments
3625           to write. If this is selected, the output segment name must contain
3626           a "strftime" function template. Default value is 0.
3627
3628       break_non_keyframes 1|0
3629           If enabled, allow segments to start on frames other than keyframes.
3630           This improves behavior on some players when the time between
3631           keyframes is inconsistent, but may make things worse on others, and
3632           can cause some oddities during seeking. Defaults to 0.
3633
3634       reset_timestamps 1|0
3635           Reset timestamps at the beginning of each segment, so that each
3636           segment will start with near-zero timestamps. It is meant to ease
3637           the playback of the generated segments. May not work with some
3638           combinations of muxers/codecs. It is set to 0 by default.
3639
3640       initial_offset offset
3641           Specify timestamp offset to apply to the output packet timestamps.
3642           The argument must be a time duration specification, and defaults to
3643           0.
3644
3645       write_empty_segments 1|0
3646           If enabled, write an empty segment if there are no packets during
3647           the period a segment would usually span. Otherwise, the segment
3648           will be filled with the next packet written. Defaults to 0.
3649
3650       Make sure to require a closed GOP when encoding and to set the GOP size
3651       to fit your segment time constraint.
3652
3653       Examples
3654
3655       •   Remux the content of file in.mkv to a list of segments out-000.nut,
3656           out-001.nut, etc., and write the list of generated segments to
3657           out.list:
3658
3659                   ffmpeg -i in.mkv -codec hevc -flags +cgop -g 60 -map 0 -f segment -segment_list out.list out%03d.nut
3660
3661       •   Segment input and set output format options for the output
3662           segments:
3663
3664                   ffmpeg -i in.mkv -f segment -segment_time 10 -segment_format_options movflags=+faststart out%03d.mp4
3665
3666       •   Segment the input file according to the split points specified by
3667           the segment_times option:
3668
3669                   ffmpeg -i in.mkv -codec copy -map 0 -f segment -segment_list out.csv -segment_times 1,2,3,5,8,13,21 out%03d.nut
3670
3671       •   Use the ffmpeg force_key_frames option to force key frames in the
3672           input at the specified location, together with the segment option
3673           segment_time_delta to account for possible roundings operated when
3674           setting key frame times.
3675
3676                   ffmpeg -i in.mkv -force_key_frames 1,2,3,5,8,13,21 -codec:v mpeg4 -codec:a pcm_s16le -map 0 \
3677                   -f segment -segment_list out.csv -segment_times 1,2,3,5,8,13,21 -segment_time_delta 0.05 out%03d.nut
3678
3679           In order to force key frames on the input file, transcoding is
3680           required.
3681
3682       •   Segment the input file by splitting the input file according to the
3683           frame numbers sequence specified with the segment_frames option:
3684
3685                   ffmpeg -i in.mkv -codec copy -map 0 -f segment -segment_list out.csv -segment_frames 100,200,300,500,800 out%03d.nut
3686
3687       •   Convert the in.mkv to TS segments using the "libx264" and "aac"
3688           encoders:
3689
3690                   ffmpeg -i in.mkv -map 0 -codec:v libx264 -codec:a aac -f ssegment -segment_list out.list out%03d.ts
3691
3692       •   Segment the input file, and create an M3U8 live playlist (can be
3693           used as live HLS source):
3694
3695                   ffmpeg -re -i in.mkv -codec copy -map 0 -f segment -segment_list playlist.m3u8 \
3696                   -segment_list_flags +live -segment_time 10 out%03d.mkv
3697
3698   smoothstreaming
3699       Smooth Streaming muxer generates a set of files (Manifest, chunks)
3700       suitable for serving with conventional web server.
3701
3702       window_size
3703           Specify the number of fragments kept in the manifest. Default 0
3704           (keep all).
3705
3706       extra_window_size
3707           Specify the number of fragments kept outside of the manifest before
3708           removing from disk. Default 5.
3709
3710       lookahead_count
3711           Specify the number of lookahead fragments. Default 2.
3712
3713       min_frag_duration
3714           Specify the minimum fragment duration (in microseconds). Default
3715           5000000.
3716
3717       remove_at_exit
3718           Specify whether to remove all fragments when finished. Default 0
3719           (do not remove).
3720
3721   streamhash
3722       Per stream hash testing format.
3723
3724       This muxer computes and prints a cryptographic hash of all the input
3725       frames, on a per-stream basis. This can be used for equality checks
3726       without having to do a complete binary comparison.
3727
3728       By default audio frames are converted to signed 16-bit raw audio and
3729       video frames to raw video before computing the hash, but the output of
3730       explicit conversions to other codecs can also be used. Timestamps are
3731       ignored. It uses the SHA-256 cryptographic hash function by default,
3732       but supports several other algorithms.
3733
3734       The output of the muxer consists of one line per stream of the form:
3735       streamindex,streamtype,algo=hash, where streamindex is the index of the
3736       mapped stream, streamtype is a single character indicating the type of
3737       stream, algo is a short string representing the hash function used, and
3738       hash is a hexadecimal number representing the computed hash.
3739
3740       hash algorithm
3741           Use the cryptographic hash function specified by the string
3742           algorithm.  Supported values include "MD5", "murmur3", "RIPEMD128",
3743           "RIPEMD160", "RIPEMD256", "RIPEMD320", "SHA160", "SHA224", "SHA256"
3744           (default), "SHA512/224", "SHA512/256", "SHA384", "SHA512", "CRC32"
3745           and "adler32".
3746
3747       Examples
3748
3749       To compute the SHA-256 hash of the input converted to raw audio and
3750       video, and store it in the file out.sha256:
3751
3752               ffmpeg -i INPUT -f streamhash out.sha256
3753
3754       To print an MD5 hash to stdout use the command:
3755
3756               ffmpeg -i INPUT -f streamhash -hash md5 -
3757
3758       See also the hash and framehash muxers.
3759
3760   tee
3761       The tee muxer can be used to write the same data to several outputs,
3762       such as files or streams.  It can be used, for example, to stream a
3763       video over a network and save it to disk at the same time.
3764
3765       It is different from specifying several outputs to the ffmpeg command-
3766       line tool. With the tee muxer, the audio and video data will be encoded
3767       only once.  With conventional multiple outputs, multiple encoding
3768       operations in parallel are initiated, which can be a very expensive
3769       process. The tee muxer is not useful when using the libavformat API
3770       directly because it is then possible to feed the same packets to
3771       several muxers directly.
3772
3773       Since the tee muxer does not represent any particular output format,
3774       ffmpeg cannot auto-select output streams. So all streams intended for
3775       output must be specified using "-map". See the examples below.
3776
3777       Some encoders may need different options depending on the output
3778       format; the auto-detection of this can not work with the tee muxer, so
3779       they need to be explicitly specified.  The main example is the
3780       global_header flag.
3781
3782       The slave outputs are specified in the file name given to the muxer,
3783       separated by '|'. If any of the slave name contains the '|' separator,
3784       leading or trailing spaces or any special character, those must be
3785       escaped (see the "Quoting and escaping" section in the ffmpeg-utils(1)
3786       manual).
3787
3788       Options
3789
3790       use_fifo bool
3791           If set to 1, slave outputs will be processed in separate threads
3792           using the fifo muxer. This allows to compensate for different
3793           speed/latency/reliability of outputs and setup transparent
3794           recovery. By default this feature is turned off.
3795
3796       fifo_options
3797           Options to pass to fifo pseudo-muxer instances. See fifo.
3798
3799       Muxer options can be specified for each slave by prepending them as a
3800       list of key=value pairs separated by ':', between square brackets. If
3801       the options values contain a special character or the ':' separator,
3802       they must be escaped; note that this is a second level escaping.
3803
3804       The following special options are also recognized:
3805
3806       f   Specify the format name. Required if it cannot be guessed from the
3807           output URL.
3808
3809       bsfs[/spec]
3810           Specify a list of bitstream filters to apply to the specified
3811           output.
3812
3813           It is possible to specify to which streams a given bitstream filter
3814           applies, by appending a stream specifier to the option separated by
3815           "/". spec must be a stream specifier (see Format stream
3816           specifiers).
3817
3818           If the stream specifier is not specified, the bitstream filters
3819           will be applied to all streams in the output. This will cause that
3820           output operation to fail if the output contains streams to which
3821           the bitstream filter cannot be applied e.g. "h264_mp4toannexb"
3822           being applied to an output containing an audio stream.
3823
3824           Options for a bitstream filter must be specified in the form of
3825           "opt=value".
3826
3827           Several bitstream filters can be specified, separated by ",".
3828
3829       use_fifo bool
3830           This allows to override tee muxer use_fifo option for individual
3831           slave muxer.
3832
3833       fifo_options
3834           This allows to override tee muxer fifo_options for individual slave
3835           muxer.  See fifo.
3836
3837       select
3838           Select the streams that should be mapped to the slave output,
3839           specified by a stream specifier. If not specified, this defaults to
3840           all the mapped streams. This will cause that output operation to
3841           fail if the output format does not accept all mapped streams.
3842
3843           You may use multiple stream specifiers separated by commas (",")
3844           e.g.: "a:0,v"
3845
3846       onfail
3847           Specify behaviour on output failure. This can be set to either
3848           "abort" (which is default) or "ignore". "abort" will cause whole
3849           process to fail in case of failure on this slave output. "ignore"
3850           will ignore failure on this output, so other outputs will continue
3851           without being affected.
3852
3853       Examples
3854
3855       •   Encode something and both archive it in a WebM file and stream it
3856           as MPEG-TS over UDP:
3857
3858                   ffmpeg -i ... -c:v libx264 -c:a mp2 -f tee -map 0:v -map 0:a
3859                     "archive-20121107.mkv|[f=mpegts]udp://10.0.1.255:1234/"
3860
3861       •   As above, but continue streaming even if output to local file fails
3862           (for example local drive fills up):
3863
3864                   ffmpeg -i ... -c:v libx264 -c:a mp2 -f tee -map 0:v -map 0:a
3865                     "[onfail=ignore]archive-20121107.mkv|[f=mpegts]udp://10.0.1.255:1234/"
3866
3867       •   Use ffmpeg to encode the input, and send the output to three
3868           different destinations. The "dump_extra" bitstream filter is used
3869           to add extradata information to all the output video keyframes
3870           packets, as requested by the MPEG-TS format. The select option is
3871           applied to out.aac in order to make it contain only audio packets.
3872
3873                   ffmpeg -i ... -map 0 -flags +global_header -c:v libx264 -c:a aac
3874                          -f tee "[bsfs/v=dump_extra=freq=keyframe]out.ts|[movflags=+faststart]out.mp4|[select=a]out.aac"
3875
3876       •   As above, but select only stream "a:1" for the audio output. Note
3877           that a second level escaping must be performed, as ":" is a special
3878           character used to separate options.
3879
3880                   ffmpeg -i ... -map 0 -flags +global_header -c:v libx264 -c:a aac
3881                          -f tee "[bsfs/v=dump_extra=freq=keyframe]out.ts|[movflags=+faststart]out.mp4|[select=\'a:1\']out.aac"
3882
3883   webm_chunk
3884       WebM Live Chunk Muxer.
3885
3886       This muxer writes out WebM headers and chunks as separate files which
3887       can be consumed by clients that support WebM Live streams via DASH.
3888
3889       Options
3890
3891       This muxer supports the following options:
3892
3893       chunk_start_index
3894           Index of the first chunk (defaults to 0).
3895
3896       header
3897           Filename of the header where the initialization data will be
3898           written.
3899
3900       audio_chunk_duration
3901           Duration of each audio chunk in milliseconds (defaults to 5000).
3902
3903       Example
3904
3905               ffmpeg -f v4l2 -i /dev/video0 \
3906                      -f alsa -i hw:0 \
3907                      -map 0:0 \
3908                      -c:v libvpx-vp9 \
3909                      -s 640x360 -keyint_min 30 -g 30 \
3910                      -f webm_chunk \
3911                      -header webm_live_video_360.hdr \
3912                      -chunk_start_index 1 \
3913                      webm_live_video_360_%d.chk \
3914                      -map 1:0 \
3915                      -c:a libvorbis \
3916                      -b:a 128k \
3917                      -f webm_chunk \
3918                      -header webm_live_audio_128.hdr \
3919                      -chunk_start_index 1 \
3920                      -audio_chunk_duration 1000 \
3921                      webm_live_audio_128_%d.chk
3922
3923   webm_dash_manifest
3924       WebM DASH Manifest muxer.
3925
3926       This muxer implements the WebM DASH Manifest specification to generate
3927       the DASH manifest XML. It also supports manifest generation for DASH
3928       live streams.
3929
3930       For more information see:
3931
3932       •   WebM DASH Specification:
3933           <https://sites.google.com/a/webmproject.org/wiki/adaptive-streaming/webm-dash-specification>
3934
3935       •   ISO DASH Specification:
3936           <http://standards.iso.org/ittf/PubliclyAvailableStandards/c065274_ISO_IEC_23009-1_2014.zip>
3937
3938       Options
3939
3940       This muxer supports the following options:
3941
3942       adaptation_sets
3943           This option has the following syntax: "id=x,streams=a,b,c
3944           id=y,streams=d,e" where x and y are the unique identifiers of the
3945           adaptation sets and a,b,c,d and e are the indices of the
3946           corresponding audio and video streams. Any number of adaptation
3947           sets can be added using this option.
3948
3949       live
3950           Set this to 1 to create a live stream DASH Manifest. Default: 0.
3951
3952       chunk_start_index
3953           Start index of the first chunk. This will go in the startNumber
3954           attribute of the SegmentTemplate element in the manifest. Default:
3955           0.
3956
3957       chunk_duration_ms
3958           Duration of each chunk in milliseconds. This will go in the
3959           duration attribute of the SegmentTemplate element in the manifest.
3960           Default: 1000.
3961
3962       utc_timing_url
3963           URL of the page that will return the UTC timestamp in ISO format.
3964           This will go in the value attribute of the UTCTiming element in the
3965           manifest.  Default: None.
3966
3967       time_shift_buffer_depth
3968           Smallest time (in seconds) shifting buffer for which any
3969           Representation is guaranteed to be available. This will go in the
3970           timeShiftBufferDepth attribute of the MPD element. Default: 60.
3971
3972       minimum_update_period
3973           Minimum update period (in seconds) of the manifest. This will go in
3974           the minimumUpdatePeriod attribute of the MPD element. Default: 0.
3975
3976       Example
3977
3978               ffmpeg -f webm_dash_manifest -i video1.webm \
3979                      -f webm_dash_manifest -i video2.webm \
3980                      -f webm_dash_manifest -i audio1.webm \
3981                      -f webm_dash_manifest -i audio2.webm \
3982                      -map 0 -map 1 -map 2 -map 3 \
3983                      -c copy \
3984                      -f webm_dash_manifest \
3985                      -adaptation_sets "id=0,streams=0,1 id=1,streams=2,3" \
3986                      manifest.xml
3987

METADATA

3989       FFmpeg is able to dump metadata from media files into a simple
3990       UTF-8-encoded INI-like text file and then load it back using the
3991       metadata muxer/demuxer.
3992
3993       The file format is as follows:
3994
3995       1.  A file consists of a header and a number of metadata tags divided
3996           into sections, each on its own line.
3997
3998       2.  The header is a ;FFMETADATA string, followed by a version number
3999           (now 1).
4000
4001       3.  Metadata tags are of the form key=value
4002
4003       4.  Immediately after header follows global metadata
4004
4005       5.  After global metadata there may be sections with
4006           per-stream/per-chapter metadata.
4007
4008       6.  A section starts with the section name in uppercase (i.e. STREAM or
4009           CHAPTER) in brackets ([, ]) and ends with next section or end of
4010           file.
4011
4012       7.  At the beginning of a chapter section there may be an optional
4013           timebase to be used for start/end values. It must be in form
4014           TIMEBASE=num/den, where num and den are integers. If the timebase
4015           is missing then start/end times are assumed to be in nanoseconds.
4016
4017           Next a chapter section must contain chapter start and end times in
4018           form START=num, END=num, where num is a positive integer.
4019
4020       8.  Empty lines and lines starting with ; or # are ignored.
4021
4022       9.  Metadata keys or values containing special characters (=, ;, #, \
4023           and a newline) must be escaped with a backslash \.
4024
4025       10. Note that whitespace in metadata (e.g. foo = bar) is considered to
4026           be a part of the tag (in the example above key is foo , value is
4027            bar).
4028
4029       A ffmetadata file might look like this:
4030
4031               ;FFMETADATA1
4032               title=bike\\shed
4033               ;this is a comment
4034               artist=FFmpeg troll team
4035
4036               [CHAPTER]
4037               TIMEBASE=1/1000
4038               START=0
4039               #chapter ends at 0:01:00
4040               END=60000
4041               title=chapter \#1
4042               [STREAM]
4043               title=multi\
4044               line
4045
4046       By using the ffmetadata muxer and demuxer it is possible to extract
4047       metadata from an input file to an ffmetadata file, and then transcode
4048       the file into an output file with the edited ffmetadata file.
4049
4050       Extracting an ffmetadata file with ffmpeg goes as follows:
4051
4052               ffmpeg -i INPUT -f ffmetadata FFMETADATAFILE
4053
4054       Reinserting edited metadata information from the FFMETADATAFILE file
4055       can be done as:
4056
4057               ffmpeg -i INPUT -i FFMETADATAFILE -map_metadata 1 -codec copy OUTPUT
4058

SEE ALSO

4060       ffmpeg(1), ffplay(1), ffprobe(1), libavformat(3)
4061

AUTHORS

4063       The FFmpeg developers.
4064
4065       For details about the authorship, see the Git history of the project
4066       (https://git.ffmpeg.org/ffmpeg), e.g. by typing the command git log in
4067       the FFmpeg source directory, or browsing the online repository at
4068       <https://git.ffmpeg.org/ffmpeg>.
4069
4070       Maintainers for the specific components are listed in the file
4071       MAINTAINERS in the source code tree.
4072
4073
4074
4075                                                             FFMPEG-FORMATS(1)
Impressum