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

NAME

6       ffmpeg-filters - FFmpeg filters
7

DESCRIPTION

9       This document describes filters, sources, and sinks provided by the
10       libavfilter library.
11

FILTERING INTRODUCTION

13       Filtering in FFmpeg is enabled through the libavfilter library.
14
15       In libavfilter, a filter can have multiple inputs and multiple outputs.
16       To illustrate the sorts of things that are possible, we consider the
17       following filtergraph.
18
19                               [main]
20               input --> split ---------------------> overlay --> output
21                           |                             ^
22                           |[tmp]                  [flip]|
23                           +-----> crop --> vflip -------+
24
25       This filtergraph splits the input stream in two streams, then sends one
26       stream through the crop filter and the vflip filter, before merging it
27       back with the other stream by overlaying it on top. You can use the
28       following command to achieve this:
29
30               ffmpeg -i INPUT -vf "split [main][tmp]; [tmp] crop=iw:ih/2:0:0, vflip [flip]; [main][flip] overlay=0:H/2" OUTPUT
31
32       The result will be that the top half of the video is mirrored onto the
33       bottom half of the output video.
34
35       Filters in the same linear chain are separated by commas, and distinct
36       linear chains of filters are separated by semicolons. In our example,
37       crop,vflip are in one linear chain, split and overlay are separately in
38       another. The points where the linear chains join are labelled by names
39       enclosed in square brackets. In the example, the split filter generates
40       two outputs that are associated to the labels [main] and [tmp].
41
42       The stream sent to the second output of split, labelled as [tmp], is
43       processed through the crop filter, which crops away the lower half part
44       of the video, and then vertically flipped. The overlay filter takes in
45       input the first unchanged output of the split filter (which was
46       labelled as [main]), and overlay on its lower half the output generated
47       by the crop,vflip filterchain.
48
49       Some filters take in input a list of parameters: they are specified
50       after the filter name and an equal sign, and are separated from each
51       other by a colon.
52
53       There exist so-called source filters that do not have an audio/video
54       input, and sink filters that will not have audio/video output.
55

GRAPH

57       The graph2dot program included in the FFmpeg tools directory can be
58       used to parse a filtergraph description and issue a corresponding
59       textual representation in the dot language.
60
61       Invoke the command:
62
63               graph2dot -h
64
65       to see how to use graph2dot.
66
67       You can then pass the dot description to the dot program (from the
68       graphviz suite of programs) and obtain a graphical representation of
69       the filtergraph.
70
71       For example the sequence of commands:
72
73               echo <GRAPH_DESCRIPTION> | \
74               tools/graph2dot -o graph.tmp && \
75               dot -Tpng graph.tmp -o graph.png && \
76               display graph.png
77
78       can be used to create and display an image representing the graph
79       described by the GRAPH_DESCRIPTION string. Note that this string must
80       be a complete self-contained graph, with its inputs and outputs
81       explicitly defined.  For example if your command line is of the form:
82
83               ffmpeg -i infile -vf scale=640:360 outfile
84
85       your GRAPH_DESCRIPTION string will need to be of the form:
86
87               nullsrc,scale=640:360,nullsink
88
89       you may also need to set the nullsrc parameters and add a format filter
90       in order to simulate a specific input file.
91

FILTERGRAPH DESCRIPTION

93       A filtergraph is a directed graph of connected filters. It can contain
94       cycles, and there can be multiple links between a pair of filters. Each
95       link has one input pad on one side connecting it to one filter from
96       which it takes its input, and one output pad on the other side
97       connecting it to one filter accepting its output.
98
99       Each filter in a filtergraph is an instance of a filter class
100       registered in the application, which defines the features and the
101       number of input and output pads of the filter.
102
103       A filter with no input pads is called a "source", and a filter with no
104       output pads is called a "sink".
105
106   Filtergraph syntax
107       A filtergraph has a textual representation, which is recognized by the
108       -filter/-vf/-af and -filter_complex options in ffmpeg and -vf/-af in
109       ffplay, and by the "avfilter_graph_parse_ptr()" function defined in
110       libavfilter/avfilter.h.
111
112       A filterchain consists of a sequence of connected filters, each one
113       connected to the previous one in the sequence. A filterchain is
114       represented by a list of ","-separated filter descriptions.
115
116       A filtergraph consists of a sequence of filterchains. A sequence of
117       filterchains is represented by a list of ";"-separated filterchain
118       descriptions.
119
120       A filter is represented by a string of the form:
121       [in_link_1]...[in_link_N]filter_name@id=arguments[out_link_1]...[out_link_M]
122
123       filter_name is the name of the filter class of which the described
124       filter is an instance of, and has to be the name of one of the filter
125       classes registered in the program optionally followed by "@id".  The
126       name of the filter class is optionally followed by a string
127       "=arguments".
128
129       arguments is a string which contains the parameters used to initialize
130       the filter instance. It may have one of two forms:
131
132       •   A ':'-separated list of key=value pairs.
133
134       •   A ':'-separated list of value. In this case, the keys are assumed
135           to be the option names in the order they are declared. E.g. the
136           "fade" filter declares three options in this order -- type,
137           start_frame and nb_frames. Then the parameter list in:0:30 means
138           that the value in is assigned to the option type, 0 to start_frame
139           and 30 to nb_frames.
140
141       •   A ':'-separated list of mixed direct value and long key=value
142           pairs. The direct value must precede the key=value pairs, and
143           follow the same constraints order of the previous point. The
144           following key=value pairs can be set in any preferred order.
145
146       If the option value itself is a list of items (e.g. the "format" filter
147       takes a list of pixel formats), the items in the list are usually
148       separated by |.
149
150       The list of arguments can be quoted using the character ' as initial
151       and ending mark, and the character \ for escaping the characters within
152       the quoted text; otherwise the argument string is considered terminated
153       when the next special character (belonging to the set []=;,) is
154       encountered.
155
156       The name and arguments of the filter are optionally preceded and
157       followed by a list of link labels.  A link label allows one to name a
158       link and associate it to a filter output or input pad. The preceding
159       labels in_link_1 ... in_link_N, are associated to the filter input
160       pads, the following labels out_link_1 ... out_link_M, are associated to
161       the output pads.
162
163       When two link labels with the same name are found in the filtergraph, a
164       link between the corresponding input and output pad is created.
165
166       If an output pad is not labelled, it is linked by default to the first
167       unlabelled input pad of the next filter in the filterchain.  For
168       example in the filterchain
169
170               nullsrc, split[L1], [L2]overlay, nullsink
171
172       the split filter instance has two output pads, and the overlay filter
173       instance two input pads. The first output pad of split is labelled
174       "L1", the first input pad of overlay is labelled "L2", and the second
175       output pad of split is linked to the second input pad of overlay, which
176       are both unlabelled.
177
178       In a filter description, if the input label of the first filter is not
179       specified, "in" is assumed; if the output label of the last filter is
180       not specified, "out" is assumed.
181
182       In a complete filterchain all the unlabelled filter input and output
183       pads must be connected. A filtergraph is considered valid if all the
184       filter input and output pads of all the filterchains are connected.
185
186       Libavfilter will automatically insert scale filters where format
187       conversion is required. It is possible to specify swscale flags for
188       those automatically inserted scalers by prepending "sws_flags=flags;"
189       to the filtergraph description.
190
191       Here is a BNF description of the filtergraph syntax:
192
193               <NAME>             ::= sequence of alphanumeric characters and '_'
194               <FILTER_NAME>      ::= <NAME>["@"<NAME>]
195               <LINKLABEL>        ::= "[" <NAME> "]"
196               <LINKLABELS>       ::= <LINKLABEL> [<LINKLABELS>]
197               <FILTER_ARGUMENTS> ::= sequence of chars (possibly quoted)
198               <FILTER>           ::= [<LINKLABELS>] <FILTER_NAME> ["=" <FILTER_ARGUMENTS>] [<LINKLABELS>]
199               <FILTERCHAIN>      ::= <FILTER> [,<FILTERCHAIN>]
200               <FILTERGRAPH>      ::= [sws_flags=<flags>;] <FILTERCHAIN> [;<FILTERGRAPH>]
201
202   Notes on filtergraph escaping
203       Filtergraph description composition entails several levels of escaping.
204       See the "Quoting and escaping" section in the ffmpeg-utils(1) manual
205       for more information about the employed escaping procedure.
206
207       A first level escaping affects the content of each filter option value,
208       which may contain the special character ":" used to separate values, or
209       one of the escaping characters "\'".
210
211       A second level escaping affects the whole filter description, which may
212       contain the escaping characters "\'" or the special characters "[],;"
213       used by the filtergraph description.
214
215       Finally, when you specify a filtergraph on a shell commandline, you
216       need to perform a third level escaping for the shell special characters
217       contained within it.
218
219       For example, consider the following string to be embedded in the
220       drawtext filter description text value:
221
222               this is a 'string': may contain one, or more, special characters
223
224       This string contains the "'" special escaping character, and the ":"
225       special character, so it needs to be escaped in this way:
226
227               text=this is a \'string\'\: may contain one, or more, special characters
228
229       A second level of escaping is required when embedding the filter
230       description in a filtergraph description, in order to escape all the
231       filtergraph special characters. Thus the example above becomes:
232
233               drawtext=text=this is a \\\'string\\\'\\: may contain one\, or more\, special characters
234
235       (note that in addition to the "\'" escaping special characters, also
236       "," needs to be escaped).
237
238       Finally an additional level of escaping is needed when writing the
239       filtergraph description in a shell command, which depends on the
240       escaping rules of the adopted shell. For example, assuming that "\" is
241       special and needs to be escaped with another "\", the previous string
242       will finally result in:
243
244               -vf "drawtext=text=this is a \\\\\\'string\\\\\\'\\\\: may contain one\\, or more\\, special characters"
245

TIMELINE EDITING

247       Some filters support a generic enable option. For the filters
248       supporting timeline editing, this option can be set to an expression
249       which is evaluated before sending a frame to the filter. If the
250       evaluation is non-zero, the filter will be enabled, otherwise the frame
251       will be sent unchanged to the next filter in the filtergraph.
252
253       The expression accepts the following values:
254
255       t   timestamp expressed in seconds, NAN if the input timestamp is
256           unknown
257
258       n   sequential number of the input frame, starting from 0
259
260       pos the position in the file of the input frame, NAN if unknown
261
262       w
263       h   width and height of the input frame if video
264
265       Additionally, these filters support an enable command that can be used
266       to re-define the expression.
267
268       Like any other filtering option, the enable option follows the same
269       rules.
270
271       For example, to enable a blur filter (smartblur) from 10 seconds to 3
272       minutes, and a curves filter starting at 3 seconds:
273
274               smartblur = enable='between(t,10,3*60)',
275               curves    = enable='gte(t,3)' : preset=cross_process
276
277       See "ffmpeg -filters" to view which filters have timeline support.
278

CHANGING OPTIONS AT RUNTIME WITH A COMMAND

280       Some options can be changed during the operation of the filter using a
281       command. These options are marked 'T' on the output of ffmpeg -h
282       filter=<name of filter>.  The name of the command is the name of the
283       option and the argument is the new value.
284

OPTIONS FOR FILTERS WITH SEVERAL INPUTS

286       Some filters with several inputs support a common set of options.
287       These options can only be set by name, not with the short notation.
288
289       eof_action
290           The action to take when EOF is encountered on the secondary input;
291           it accepts one of the following values:
292
293           repeat
294               Repeat the last frame (the default).
295
296           endall
297               End both streams.
298
299           pass
300               Pass the main input through.
301
302       shortest
303           If set to 1, force the output to terminate when the shortest input
304           terminates. Default value is 0.
305
306       repeatlast
307           If set to 1, force the filter to extend the last frame of secondary
308           streams until the end of the primary stream. A value of 0 disables
309           this behavior.  Default value is 1.
310

AUDIO FILTERS

312       When you configure your FFmpeg build, you can disable any of the
313       existing filters using "--disable-filters".  The configure output will
314       show the audio filters included in your build.
315
316       Below is a description of the currently available audio filters.
317
318   acompressor
319       A compressor is mainly used to reduce the dynamic range of a signal.
320       Especially modern music is mostly compressed at a high ratio to improve
321       the overall loudness. It's done to get the highest attention of a
322       listener, "fatten" the sound and bring more "power" to the track.  If a
323       signal is compressed too much it may sound dull or "dead" afterwards or
324       it may start to "pump" (which could be a powerful effect but can also
325       destroy a track completely).  The right compression is the key to reach
326       a professional sound and is the high art of mixing and mastering.
327       Because of its complex settings it may take a long time to get the
328       right feeling for this kind of effect.
329
330       Compression is done by detecting the volume above a chosen level
331       "threshold" and dividing it by the factor set with "ratio".  So if you
332       set the threshold to -12dB and your signal reaches -6dB a ratio of 2:1
333       will result in a signal at -9dB. Because an exact manipulation of the
334       signal would cause distortion of the waveform the reduction can be
335       levelled over the time. This is done by setting "Attack" and "Release".
336       "attack" determines how long the signal has to rise above the threshold
337       before any reduction will occur and "release" sets the time the signal
338       has to fall below the threshold to reduce the reduction again. Shorter
339       signals than the chosen attack time will be left untouched.  The
340       overall reduction of the signal can be made up afterwards with the
341       "makeup" setting. So compressing the peaks of a signal about 6dB and
342       raising the makeup to this level results in a signal twice as loud than
343       the source. To gain a softer entry in the compression the "knee"
344       flattens the hard edge at the threshold in the range of the chosen
345       decibels.
346
347       The filter accepts the following options:
348
349       level_in
350           Set input gain. Default is 1. Range is between 0.015625 and 64.
351
352       mode
353           Set mode of compressor operation. Can be "upward" or "downward".
354           Default is "downward".
355
356       threshold
357           If a signal of stream rises above this level it will affect the
358           gain reduction.  By default it is 0.125. Range is between
359           0.00097563 and 1.
360
361       ratio
362           Set a ratio by which the signal is reduced. 1:2 means that if the
363           level rose 4dB above the threshold, it will be only 2dB above after
364           the reduction.  Default is 2. Range is between 1 and 20.
365
366       attack
367           Amount of milliseconds the signal has to rise above the threshold
368           before gain reduction starts. Default is 20. Range is between 0.01
369           and 2000.
370
371       release
372           Amount of milliseconds the signal has to fall below the threshold
373           before reduction is decreased again. Default is 250. Range is
374           between 0.01 and 9000.
375
376       makeup
377           Set the amount by how much signal will be amplified after
378           processing.  Default is 1. Range is from 1 to 64.
379
380       knee
381           Curve the sharp knee around the threshold to enter gain reduction
382           more softly.  Default is 2.82843. Range is between 1 and 8.
383
384       link
385           Choose if the "average" level between all channels of input stream
386           or the louder("maximum") channel of input stream affects the
387           reduction. Default is "average".
388
389       detection
390           Should the exact signal be taken in case of "peak" or an RMS one in
391           case of "rms". Default is "rms" which is mostly smoother.
392
393       mix How much to use compressed signal in output. Default is 1.  Range
394           is between 0 and 1.
395
396       Commands
397
398       This filter supports the all above options as commands.
399
400   acontrast
401       Simple audio dynamic range compression/expansion filter.
402
403       The filter accepts the following options:
404
405       contrast
406           Set contrast. Default is 33. Allowed range is between 0 and 100.
407
408   acopy
409       Copy the input audio source unchanged to the output. This is mainly
410       useful for testing purposes.
411
412   acrossfade
413       Apply cross fade from one input audio stream to another input audio
414       stream.  The cross fade is applied for specified duration near the end
415       of first stream.
416
417       The filter accepts the following options:
418
419       nb_samples, ns
420           Specify the number of samples for which the cross fade effect has
421           to last.  At the end of the cross fade effect the first input audio
422           will be completely silent. Default is 44100.
423
424       duration, d
425           Specify the duration of the cross fade effect. See the Time
426           duration section in the ffmpeg-utils(1) manual for the accepted
427           syntax.  By default the duration is determined by nb_samples.  If
428           set this option is used instead of nb_samples.
429
430       overlap, o
431           Should first stream end overlap with second stream start. Default
432           is enabled.
433
434       curve1
435           Set curve for cross fade transition for first stream.
436
437       curve2
438           Set curve for cross fade transition for second stream.
439
440           For description of available curve types see afade filter
441           description.
442
443       Examples
444
445       •   Cross fade from one input to another:
446
447                   ffmpeg -i first.flac -i second.flac -filter_complex acrossfade=d=10:c1=exp:c2=exp output.flac
448
449       •   Cross fade from one input to another but without overlapping:
450
451                   ffmpeg -i first.flac -i second.flac -filter_complex acrossfade=d=10:o=0:c1=exp:c2=exp output.flac
452
453   acrossover
454       Split audio stream into several bands.
455
456       This filter splits audio stream into two or more frequency ranges.
457       Summing all streams back will give flat output.
458
459       The filter accepts the following options:
460
461       split
462           Set split frequencies. Those must be positive and increasing.
463
464       order
465           Set filter order for each band split. This controls filter roll-off
466           or steepness of filter transfer function.  Available values are:
467
468           2nd 12 dB per octave.
469
470           4th 24 dB per octave.
471
472           6th 36 dB per octave.
473
474           8th 48 dB per octave.
475
476           10th
477               60 dB per octave.
478
479           12th
480               72 dB per octave.
481
482           14th
483               84 dB per octave.
484
485           16th
486               96 dB per octave.
487
488           18th
489               108 dB per octave.
490
491           20th
492               120 dB per octave.
493
494           Default is 4th.
495
496       level
497           Set input gain level. Allowed range is from 0 to 1. Default value
498           is 1.
499
500       gains
501           Set output gain for each band. Default value is 1 for all bands.
502
503       precision
504           Set which precision to use when processing samples.
505
506           auto
507               Auto pick internal sample format depending on other filters.
508
509           float
510               Always use single-floating point precision sample format.
511
512           double
513               Always use double-floating point precision sample format.
514
515           Default value is "auto".
516
517       Examples
518
519       •   Split input audio stream into two bands (low and high) with split
520           frequency of 1500 Hz, each band will be in separate stream:
521
522                   ffmpeg -i in.flac -filter_complex 'acrossover=split=1500[LOW][HIGH]' -map '[LOW]' low.wav -map '[HIGH]' high.wav
523
524       •   Same as above, but with higher filter order:
525
526                   ffmpeg -i in.flac -filter_complex 'acrossover=split=1500:order=8th[LOW][HIGH]' -map '[LOW]' low.wav -map '[HIGH]' high.wav
527
528       •   Same as above, but also with additional middle band (frequencies
529           between 1500 and 8000):
530
531                   ffmpeg -i in.flac -filter_complex 'acrossover=split=1500 8000:order=8th[LOW][MID][HIGH]' -map '[LOW]' low.wav -map '[MID]' mid.wav -map '[HIGH]' high.wav
532
533   acrusher
534       Reduce audio bit resolution.
535
536       This filter is bit crusher with enhanced functionality. A bit crusher
537       is used to audibly reduce number of bits an audio signal is sampled
538       with. This doesn't change the bit depth at all, it just produces the
539       effect. Material reduced in bit depth sounds more harsh and "digital".
540       This filter is able to even round to continuous values instead of
541       discrete bit depths.  Additionally it has a D/C offset which results in
542       different crushing of the lower and the upper half of the signal.  An
543       Anti-Aliasing setting is able to produce "softer" crushing sounds.
544
545       Another feature of this filter is the logarithmic mode.  This setting
546       switches from linear distances between bits to logarithmic ones.  The
547       result is a much more "natural" sounding crusher which doesn't gate low
548       signals for example. The human ear has a logarithmic perception, so
549       this kind of crushing is much more pleasant.  Logarithmic crushing is
550       also able to get anti-aliased.
551
552       The filter accepts the following options:
553
554       level_in
555           Set level in.
556
557       level_out
558           Set level out.
559
560       bits
561           Set bit reduction.
562
563       mix Set mixing amount.
564
565       mode
566           Can be linear: "lin" or logarithmic: "log".
567
568       dc  Set DC.
569
570       aa  Set anti-aliasing.
571
572       samples
573           Set sample reduction.
574
575       lfo Enable LFO. By default disabled.
576
577       lforange
578           Set LFO range.
579
580       lforate
581           Set LFO rate.
582
583       Commands
584
585       This filter supports the all above options as commands.
586
587   acue
588       Delay audio filtering until a given wallclock timestamp. See the cue
589       filter.
590
591   adeclick
592       Remove impulsive noise from input audio.
593
594       Samples detected as impulsive noise are replaced by interpolated
595       samples using autoregressive modelling.
596
597       window, w
598           Set window size, in milliseconds. Allowed range is from 10 to 100.
599           Default value is 55 milliseconds.  This sets size of window which
600           will be processed at once.
601
602       overlap, o
603           Set window overlap, in percentage of window size. Allowed range is
604           from 50 to 95. Default value is 75 percent.  Setting this to a very
605           high value increases impulsive noise removal but makes whole
606           process much slower.
607
608       arorder, a
609           Set autoregression order, in percentage of window size. Allowed
610           range is from 0 to 25. Default value is 2 percent. This option also
611           controls quality of interpolated samples using neighbour good
612           samples.
613
614       threshold, t
615           Set threshold value. Allowed range is from 1 to 100.  Default value
616           is 2.  This controls the strength of impulsive noise which is going
617           to be removed.  The lower value, the more samples will be detected
618           as impulsive noise.
619
620       burst, b
621           Set burst fusion, in percentage of window size. Allowed range is 0
622           to 10. Default value is 2.  If any two samples detected as noise
623           are spaced less than this value then any sample between those two
624           samples will be also detected as noise.
625
626       method, m
627           Set overlap method.
628
629           It accepts the following values:
630
631           add, a
632               Select overlap-add method. Even not interpolated samples are
633               slightly changed with this method.
634
635           save, s
636               Select overlap-save method. Not interpolated samples remain
637               unchanged.
638
639           Default value is "a".
640
641   adeclip
642       Remove clipped samples from input audio.
643
644       Samples detected as clipped are replaced by interpolated samples using
645       autoregressive modelling.
646
647       window, w
648           Set window size, in milliseconds. Allowed range is from 10 to 100.
649           Default value is 55 milliseconds.  This sets size of window which
650           will be processed at once.
651
652       overlap, o
653           Set window overlap, in percentage of window size. Allowed range is
654           from 50 to 95. Default value is 75 percent.
655
656       arorder, a
657           Set autoregression order, in percentage of window size. Allowed
658           range is from 0 to 25. Default value is 8 percent. This option also
659           controls quality of interpolated samples using neighbour good
660           samples.
661
662       threshold, t
663           Set threshold value. Allowed range is from 1 to 100.  Default value
664           is 10. Higher values make clip detection less aggressive.
665
666       hsize, n
667           Set size of histogram used to detect clips. Allowed range is from
668           100 to 9999.  Default value is 1000. Higher values make clip
669           detection less aggressive.
670
671       method, m
672           Set overlap method.
673
674           It accepts the following values:
675
676           add, a
677               Select overlap-add method. Even not interpolated samples are
678               slightly changed with this method.
679
680           save, s
681               Select overlap-save method. Not interpolated samples remain
682               unchanged.
683
684           Default value is "a".
685
686   adecorrelate
687       Apply decorrelation to input audio stream.
688
689       The filter accepts the following options:
690
691       stages
692           Set decorrelation stages of filtering. Allowed range is from 1 to
693           16. Default value is 6.
694
695       seed
696           Set random seed used for setting delay in samples across channels.
697
698   adelay
699       Delay one or more audio channels.
700
701       Samples in delayed channel are filled with silence.
702
703       The filter accepts the following option:
704
705       delays
706           Set list of delays in milliseconds for each channel separated by
707           '|'.  Unused delays will be silently ignored. If number of given
708           delays is smaller than number of channels all remaining channels
709           will not be delayed.  If you want to delay exact number of samples,
710           append 'S' to number.  If you want instead to delay in seconds,
711           append 's' to number.
712
713       all Use last set delay for all remaining channels. By default is
714           disabled.  This option if enabled changes how option "delays" is
715           interpreted.
716
717       Examples
718
719       •   Delay first channel by 1.5 seconds, the third channel by 0.5
720           seconds and leave the second channel (and any other channels that
721           may be present) unchanged.
722
723                   adelay=1500|0|500
724
725       •   Delay second channel by 500 samples, the third channel by 700
726           samples and leave the first channel (and any other channels that
727           may be present) unchanged.
728
729                   adelay=0|500S|700S
730
731       •   Delay all channels by same number of samples:
732
733                   adelay=delays=64S:all=1
734
735   adenorm
736       Remedy denormals in audio by adding extremely low-level noise.
737
738       This filter shall be placed before any filter that can produce
739       denormals.
740
741       A description of the accepted parameters follows.
742
743       level
744           Set level of added noise in dB. Default is "-351".  Allowed range
745           is from -451 to -90.
746
747       type
748           Set type of added noise.
749
750           dc  Add DC signal.
751
752           ac  Add AC signal.
753
754           square
755               Add square signal.
756
757           pulse
758               Add pulse signal.
759
760           Default is "dc".
761
762       Commands
763
764       This filter supports the all above options as commands.
765
766   aderivative, aintegral
767       Compute derivative/integral of audio stream.
768
769       Applying both filters one after another produces original audio.
770
771   adynamicequalizer
772       Apply dynamic equalization to input audio stream.
773
774       A description of the accepted options follows.
775
776       threshold
777           Set the detection threshold used to trigger equalization.
778           Threshold detection is using bandpass filter.  Default value is 0.
779           Allowed range is from 0 to 100.
780
781       dfrequency
782           Set the detection frequency in Hz used for bandpass filter used to
783           trigger equalization.  Default value is 1000 Hz. Allowed range is
784           between 2 and 1000000 Hz.
785
786       dqfactor
787           Set the detection resonance factor for bandpass filter used to
788           trigger equalization.  Default value is 1. Allowed range is from
789           0.001 to 1000.
790
791       tfrequency
792           Set the target frequency of equalization filter.  Default value is
793           1000 Hz. Allowed range is between 2 and 1000000 Hz.
794
795       tqfactor
796           Set the target resonance factor for target equalization filter.
797           Default value is 1. Allowed range is from 0.001 to 1000.
798
799       attack
800           Set the amount of milliseconds the signal from detection has to
801           rise above the detection threshold before equalization starts.
802           Default is 20. Allowed range is between 1 and 2000.
803
804       release
805           Set the amount of milliseconds the signal from detection has to
806           fall below the detection threshold before equalization ends.
807           Default is 200. Allowed range is between 1 and 2000.
808
809       knee
810           Curve the sharp knee around the detection threshold to calculate
811           equalization gain more softly.  Default is 1. Allowed range is
812           between 0 and 8.
813
814       ratio
815           Set the ratio by which the equalization gain is raised.  Default is
816           1. Allowed range is between 1 and 20.
817
818       makeup
819           Set the makeup offset in dB by which the equalization gain is
820           raised.  Default is 0. Allowed range is between 0 and 30.
821
822       range
823           Set the max allowed cut/boost amount in dB. Default is 0.  Allowed
824           range is from 0 to 200.
825
826       slew
827           Set the slew factor. Default is 1. Allowed range is from 1 to 200.
828
829       mode
830           Set the mode of filter operation, can be one of the following:
831
832           listen
833               Output only isolated bandpass signal.
834
835           cut Cut frequencies above detection threshold.
836
837           boost
838               Boost frequencies bellow detection threshold.
839
840           Default mode is cut.
841
842       tftype
843           Set the type of target filter, can be one of the following:
844
845           bell
846           lowshelf
847           highshelf
848
849           Default type is bell.
850
851       Commands
852
853       This filter supports the all above options as commands.
854
855   adynamicsmooth
856       Apply dynamic smoothing to input audio stream.
857
858       A description of the accepted options follows.
859
860       sensitivity
861           Set an amount of sensitivity to frequency fluctations. Default is
862           2.  Allowed range is from 0 to 1e+06.
863
864       basefreq
865           Set a base frequency for smoothing. Default value is 22050.
866           Allowed range is from 2 to 1e+06.
867
868       Commands
869
870       This filter supports the all above options as commands.
871
872   aecho
873       Apply echoing to the input audio.
874
875       Echoes are reflected sound and can occur naturally amongst mountains
876       (and sometimes large buildings) when talking or shouting; digital echo
877       effects emulate this behaviour and are often used to help fill out the
878       sound of a single instrument or vocal. The time difference between the
879       original signal and the reflection is the "delay", and the loudness of
880       the reflected signal is the "decay".  Multiple echoes can have
881       different delays and decays.
882
883       A description of the accepted parameters follows.
884
885       in_gain
886           Set input gain of reflected signal. Default is 0.6.
887
888       out_gain
889           Set output gain of reflected signal. Default is 0.3.
890
891       delays
892           Set list of time intervals in milliseconds between original signal
893           and reflections separated by '|'. Allowed range for each "delay" is
894           "(0 - 90000.0]".  Default is 1000.
895
896       decays
897           Set list of loudness of reflected signals separated by '|'.
898           Allowed range for each "decay" is "(0 - 1.0]".  Default is 0.5.
899
900       Examples
901
902       •   Make it sound as if there are twice as many instruments as are
903           actually playing:
904
905                   aecho=0.8:0.88:60:0.4
906
907       •   If delay is very short, then it sounds like a (metallic) robot
908           playing music:
909
910                   aecho=0.8:0.88:6:0.4
911
912       •   A longer delay will sound like an open air concert in the
913           mountains:
914
915                   aecho=0.8:0.9:1000:0.3
916
917       •   Same as above but with one more mountain:
918
919                   aecho=0.8:0.9:1000|1800:0.3|0.25
920
921   aemphasis
922       Audio emphasis filter creates or restores material directly taken from
923       LPs or emphased CDs with different filter curves. E.g. to store music
924       on vinyl the signal has to be altered by a filter first to even out the
925       disadvantages of this recording medium.  Once the material is played
926       back the inverse filter has to be applied to restore the distortion of
927       the frequency response.
928
929       The filter accepts the following options:
930
931       level_in
932           Set input gain.
933
934       level_out
935           Set output gain.
936
937       mode
938           Set filter mode. For restoring material use "reproduction" mode,
939           otherwise use "production" mode. Default is "reproduction" mode.
940
941       type
942           Set filter type. Selects medium. Can be one of the following:
943
944           col select Columbia.
945
946           emi select EMI.
947
948           bsi select BSI (78RPM).
949
950           riaa
951               select RIAA.
952
953           cd  select Compact Disc (CD).
954
955           50fm
956               select 50Xs (FM).
957
958           75fm
959               select 75Xs (FM).
960
961           50kf
962               select 50Xs (FM-KF).
963
964           75kf
965               select 75Xs (FM-KF).
966
967       Commands
968
969       This filter supports the all above options as commands.
970
971   aeval
972       Modify an audio signal according to the specified expressions.
973
974       This filter accepts one or more expressions (one for each channel),
975       which are evaluated and used to modify a corresponding audio signal.
976
977       It accepts the following parameters:
978
979       exprs
980           Set the '|'-separated expressions list for each separate channel.
981           If the number of input channels is greater than the number of
982           expressions, the last specified expression is used for the
983           remaining output channels.
984
985       channel_layout, c
986           Set output channel layout. If not specified, the channel layout is
987           specified by the number of expressions. If set to same, it will use
988           by default the same input channel layout.
989
990       Each expression in exprs can contain the following constants and
991       functions:
992
993       ch  channel number of the current expression
994
995       n   number of the evaluated sample, starting from 0
996
997       s   sample rate
998
999       t   time of the evaluated sample expressed in seconds
1000
1001       nb_in_channels
1002       nb_out_channels
1003           input and output number of channels
1004
1005       val(CH)
1006           the value of input channel with number CH
1007
1008       Note: this filter is slow. For faster processing you should use a
1009       dedicated filter.
1010
1011       Examples
1012
1013       •   Half volume:
1014
1015                   aeval=val(ch)/2:c=same
1016
1017       •   Invert phase of the second channel:
1018
1019                   aeval=val(0)|-val(1)
1020
1021   aexciter
1022       An exciter is used to produce high sound that is not present in the
1023       original signal. This is done by creating harmonic distortions of the
1024       signal which are restricted in range and added to the original signal.
1025       An Exciter raises the upper end of an audio signal without simply
1026       raising the higher frequencies like an equalizer would do to create a
1027       more "crisp" or "brilliant" sound.
1028
1029       The filter accepts the following options:
1030
1031       level_in
1032           Set input level prior processing of signal.  Allowed range is from
1033           0 to 64.  Default value is 1.
1034
1035       level_out
1036           Set output level after processing of signal.  Allowed range is from
1037           0 to 64.  Default value is 1.
1038
1039       amount
1040           Set the amount of harmonics added to original signal.  Allowed
1041           range is from 0 to 64.  Default value is 1.
1042
1043       drive
1044           Set the amount of newly created harmonics.  Allowed range is from
1045           0.1 to 10.  Default value is 8.5.
1046
1047       blend
1048           Set the octave of newly created harmonics.  Allowed range is from
1049           -10 to 10.  Default value is 0.
1050
1051       freq
1052           Set the lower frequency limit of producing harmonics in Hz.
1053           Allowed range is from 2000 to 12000 Hz.  Default is 7500 Hz.
1054
1055       ceil
1056           Set the upper frequency limit of producing harmonics.  Allowed
1057           range is from 9999 to 20000 Hz.  If value is lower than 10000 Hz no
1058           limit is applied.
1059
1060       listen
1061           Mute the original signal and output only added harmonics.  By
1062           default is disabled.
1063
1064       Commands
1065
1066       This filter supports the all above options as commands.
1067
1068   afade
1069       Apply fade-in/out effect to input audio.
1070
1071       A description of the accepted parameters follows.
1072
1073       type, t
1074           Specify the effect type, can be either "in" for fade-in, or "out"
1075           for a fade-out effect. Default is "in".
1076
1077       start_sample, ss
1078           Specify the number of the start sample for starting to apply the
1079           fade effect. Default is 0.
1080
1081       nb_samples, ns
1082           Specify the number of samples for which the fade effect has to
1083           last. At the end of the fade-in effect the output audio will have
1084           the same volume as the input audio, at the end of the fade-out
1085           transition the output audio will be silence. Default is 44100.
1086
1087       start_time, st
1088           Specify the start time of the fade effect. Default is 0.  The value
1089           must be specified as a time duration; see the Time duration section
1090           in the ffmpeg-utils(1) manual for the accepted syntax.  If set this
1091           option is used instead of start_sample.
1092
1093       duration, d
1094           Specify the duration of the fade effect. See the Time duration
1095           section in the ffmpeg-utils(1) manual for the accepted syntax.  At
1096           the end of the fade-in effect the output audio will have the same
1097           volume as the input audio, at the end of the fade-out transition
1098           the output audio will be silence.  By default the duration is
1099           determined by nb_samples.  If set this option is used instead of
1100           nb_samples.
1101
1102       curve
1103           Set curve for fade transition.
1104
1105           It accepts the following values:
1106
1107           tri select triangular, linear slope (default)
1108
1109           qsin
1110               select quarter of sine wave
1111
1112           hsin
1113               select half of sine wave
1114
1115           esin
1116               select exponential sine wave
1117
1118           log select logarithmic
1119
1120           ipar
1121               select inverted parabola
1122
1123           qua select quadratic
1124
1125           cub select cubic
1126
1127           squ select square root
1128
1129           cbr select cubic root
1130
1131           par select parabola
1132
1133           exp select exponential
1134
1135           iqsin
1136               select inverted quarter of sine wave
1137
1138           ihsin
1139               select inverted half of sine wave
1140
1141           dese
1142               select double-exponential seat
1143
1144           desi
1145               select double-exponential sigmoid
1146
1147           losi
1148               select logistic sigmoid
1149
1150           sinc
1151               select sine cardinal function
1152
1153           isinc
1154               select inverted sine cardinal function
1155
1156           nofade
1157               no fade applied
1158
1159       Commands
1160
1161       This filter supports the all above options as commands.
1162
1163       Examples
1164
1165       •   Fade in first 15 seconds of audio:
1166
1167                   afade=t=in:ss=0:d=15
1168
1169       •   Fade out last 25 seconds of a 900 seconds audio:
1170
1171                   afade=t=out:st=875:d=25
1172
1173   afftdn
1174       Denoise audio samples with FFT.
1175
1176       A description of the accepted parameters follows.
1177
1178       noise_reduction, nr
1179           Set the noise reduction in dB, allowed range is 0.01 to 97.
1180           Default value is 12 dB.
1181
1182       noise_floor, nf
1183           Set the noise floor in dB, allowed range is -80 to -20.  Default
1184           value is -50 dB.
1185
1186       noise_type, nt
1187           Set the noise type.
1188
1189           It accepts the following values:
1190
1191           white, w
1192               Select white noise.
1193
1194           vinyl, v
1195               Select vinyl noise.
1196
1197           shellac, s
1198               Select shellac noise.
1199
1200           custom, c
1201               Select custom noise, defined in "bn" option.
1202
1203               Default value is white noise.
1204
1205       band_noise, bn
1206           Set custom band noise profile for every one of 15 bands.  Bands are
1207           separated by ' ' or '|'.
1208
1209       residual_floor, rf
1210           Set the residual floor in dB, allowed range is -80 to -20.  Default
1211           value is -38 dB.
1212
1213       track_noise, tn
1214           Enable noise floor tracking. By default is disabled.  With this
1215           enabled, noise floor is automatically adjusted.
1216
1217       track_residual, tr
1218           Enable residual tracking. By default is disabled.
1219
1220       output_mode, om
1221           Set the output mode.
1222
1223           It accepts the following values:
1224
1225           input, i
1226               Pass input unchanged.
1227
1228           output, o
1229               Pass noise filtered out.
1230
1231           noise, n
1232               Pass only noise.
1233
1234               Default value is output.
1235
1236       adaptivity, ad
1237           Set the adaptivity factor, used how fast to adapt gains adjustments
1238           per each frequency bin. Value 0 enables instant adaptation, while
1239           higher values react much slower.  Allowed range is from 0 to 1.
1240           Default value is 0.5.
1241
1242       floor_offset, fo
1243           Set the noise floor offset factor. This option is used to adjust
1244           offset applied to measured noise floor. It is only effective when
1245           noise floor tracking is enabled.  Allowed range is from -2.0 to
1246           2.0. Default value is 1.0.
1247
1248       noise_link, nl
1249           Set the noise link used for multichannel audio.
1250
1251           It accepts the following values:
1252
1253           none
1254               Use unchanged channel's noise floor.
1255
1256           min Use measured min noise floor of all channels.
1257
1258           max Use measured max noise floor of all channels.
1259
1260           average
1261               Use measured average noise floor of all channels.
1262
1263               Default value is min.
1264
1265       band_multiplier, bm
1266           Set the band multiplier factor, used how much to spread bands
1267           across frequency bins.  Allowed range is from 0.2 to 5. Default
1268           value is 1.25.
1269
1270       sample_noise, sn
1271           Toggle capturing and measurement of noise profile from input audio.
1272
1273           It accepts the following values:
1274
1275           start, begin
1276               Start sample noise capture.
1277
1278           stop, end
1279               Stop sample noise capture and measure new noise band profile.
1280
1281               Default value is "none".
1282
1283       gain_smooth, gs
1284           Set gain smooth spatial radius, used to smooth gains applied to
1285           each frequency bin.  Useful to reduce random music noise artefacts.
1286           Higher values increases smoothing of gains.  Allowed range is from
1287           0 to 50.  Default value is 0.
1288
1289       Commands
1290
1291       This filter supports the some above mentioned options as commands.
1292
1293       Examples
1294
1295       •   Reduce white noise by 10dB, and use previously measured noise floor
1296           of -40dB:
1297
1298                   afftdn=nr=10:nf=-40
1299
1300       •   Reduce white noise by 10dB, also set initial noise floor to -80dB
1301           and enable automatic tracking of noise floor so noise floor will
1302           gradually change during processing:
1303
1304                   afftdn=nr=10:nf=-80:tn=1
1305
1306       •   Reduce noise by 20dB, using noise floor of -40dB and using commands
1307           to take noise profile of first 0.4 seconds of input audio:
1308
1309                   asendcmd=0.0 afftdn sn start,asendcmd=0.4 afftdn sn stop,afftdn=nr=20:nf=-40
1310
1311   afftfilt
1312       Apply arbitrary expressions to samples in frequency domain.
1313
1314       real
1315           Set frequency domain real expression for each separate channel
1316           separated by '|'. Default is "re".  If the number of input channels
1317           is greater than the number of expressions, the last specified
1318           expression is used for the remaining output channels.
1319
1320       imag
1321           Set frequency domain imaginary expression for each separate channel
1322           separated by '|'. Default is "im".
1323
1324           Each expression in real and imag can contain the following
1325           constants and functions:
1326
1327           sr  sample rate
1328
1329           b   current frequency bin number
1330
1331           nb  number of available bins
1332
1333           ch  channel number of the current expression
1334
1335           chs number of channels
1336
1337           pts current frame pts
1338
1339           re  current real part of frequency bin of current channel
1340
1341           im  current imaginary part of frequency bin of current channel
1342
1343           real(b, ch)
1344               Return the value of real part of frequency bin at location
1345               (bin,channel)
1346
1347           imag(b, ch)
1348               Return the value of imaginary part of frequency bin at location
1349               (bin,channel)
1350
1351       win_size
1352           Set window size. Allowed range is from 16 to 131072.  Default is
1353           4096
1354
1355       win_func
1356           Set window function.
1357
1358           It accepts the following values:
1359
1360           rect
1361           bartlett
1362           hann, hanning
1363           hamming
1364           blackman
1365           welch
1366           flattop
1367           bharris
1368           bnuttall
1369           bhann
1370           sine
1371           nuttall
1372           lanczos
1373           gauss
1374           tukey
1375           dolph
1376           cauchy
1377           parzen
1378           poisson
1379           bohman
1380
1381           Default is "hann".
1382
1383       overlap
1384           Set window overlap. If set to 1, the recommended overlap for
1385           selected window function will be picked. Default is 0.75.
1386
1387       Examples
1388
1389       •   Leave almost only low frequencies in audio:
1390
1391                   afftfilt="'real=re * (1-clip((b/nb)*b,0,1))':imag='im * (1-clip((b/nb)*b,0,1))'"
1392
1393       •   Apply robotize effect:
1394
1395                   afftfilt="real='hypot(re,im)*sin(0)':imag='hypot(re,im)*cos(0)':win_size=512:overlap=0.75"
1396
1397       •   Apply whisper effect:
1398
1399                   afftfilt="real='hypot(re,im)*cos((random(0)*2-1)*2*3.14)':imag='hypot(re,im)*sin((random(1)*2-1)*2*3.14)':win_size=128:overlap=0.8"
1400
1401   afir
1402       Apply an arbitrary Finite Impulse Response filter.
1403
1404       This filter is designed for applying long FIR filters, up to 60 seconds
1405       long.
1406
1407       It can be used as component for digital crossover filters, room
1408       equalization, cross talk cancellation, wavefield synthesis,
1409       auralization, ambiophonics, ambisonics and spatialization.
1410
1411       This filter uses the streams higher than first one as FIR coefficients.
1412       If the non-first stream holds a single channel, it will be used for all
1413       input channels in the first stream, otherwise the number of channels in
1414       the non-first stream must be same as the number of channels in the
1415       first stream.
1416
1417       It accepts the following parameters:
1418
1419       dry Set dry gain. This sets input gain.
1420
1421       wet Set wet gain. This sets final output gain.
1422
1423       length
1424           Set Impulse Response filter length. Default is 1, which means whole
1425           IR is processed.
1426
1427       gtype
1428           Enable applying gain measured from power of IR.
1429
1430           Set which approach to use for auto gain measurement.
1431
1432           none
1433               Do not apply any gain.
1434
1435           peak
1436               select peak gain, very conservative approach. This is default
1437               value.
1438
1439           dc  select DC gain, limited application.
1440
1441           gn  select gain to noise approach, this is most popular one.
1442
1443       irgain
1444           Set gain to be applied to IR coefficients before filtering.
1445           Allowed range is 0 to 1. This gain is applied after any gain
1446           applied with gtype option.
1447
1448       irfmt
1449           Set format of IR stream. Can be "mono" or "input".  Default is
1450           "input".
1451
1452       maxir
1453           Set max allowed Impulse Response filter duration in seconds.
1454           Default is 30 seconds.  Allowed range is 0.1 to 60 seconds.
1455
1456       response
1457           Show IR frequency response, magnitude(magenta), phase(green) and
1458           group delay(yellow) in additional video stream.  By default it is
1459           disabled.
1460
1461       channel
1462           Set for which IR channel to display frequency response. By default
1463           is first channel displayed. This option is used only when response
1464           is enabled.
1465
1466       size
1467           Set video stream size. This option is used only when response is
1468           enabled.
1469
1470       rate
1471           Set video stream frame rate. This option is used only when response
1472           is enabled.
1473
1474       minp
1475           Set minimal partition size used for convolution. Default is 8192.
1476           Allowed range is from 1 to 32768.  Lower values decreases latency
1477           at cost of higher CPU usage.
1478
1479       maxp
1480           Set maximal partition size used for convolution. Default is 8192.
1481           Allowed range is from 8 to 32768.  Lower values may increase CPU
1482           usage.
1483
1484       nbirs
1485           Set number of input impulse responses streams which will be
1486           switchable at runtime.  Allowed range is from 1 to 32. Default is
1487           1.
1488
1489       ir  Set IR stream which will be used for convolution, starting from 0,
1490           should always be lower than supplied value by "nbirs" option.
1491           Default is 0.  This option can be changed at runtime via commands.
1492
1493       precision
1494           Set which precision to use when processing samples.
1495
1496           auto
1497               Auto pick internal sample format depending on other filters.
1498
1499           float
1500               Always use single-floating point precision sample format.
1501
1502           double
1503               Always use double-floating point precision sample format.
1504
1505           Default value is auto.
1506
1507       Examples
1508
1509       •   Apply reverb to stream using mono IR file as second input, complete
1510           command using ffmpeg:
1511
1512                   ffmpeg -i input.wav -i middle_tunnel_1way_mono.wav -lavfi afir output.wav
1513
1514   aformat
1515       Set output format constraints for the input audio. The framework will
1516       negotiate the most appropriate format to minimize conversions.
1517
1518       It accepts the following parameters:
1519
1520       sample_fmts, f
1521           A '|'-separated list of requested sample formats.
1522
1523       sample_rates, r
1524           A '|'-separated list of requested sample rates.
1525
1526       channel_layouts, cl
1527           A '|'-separated list of requested channel layouts.
1528
1529           See the Channel Layout section in the ffmpeg-utils(1) manual for
1530           the required syntax.
1531
1532       If a parameter is omitted, all values are allowed.
1533
1534       Force the output to either unsigned 8-bit or signed 16-bit stereo
1535
1536               aformat=sample_fmts=u8|s16:channel_layouts=stereo
1537
1538   afreqshift
1539       Apply frequency shift to input audio samples.
1540
1541       The filter accepts the following options:
1542
1543       shift
1544           Specify frequency shift. Allowed range is -INT_MAX to INT_MAX.
1545           Default value is 0.0.
1546
1547       level
1548           Set output gain applied to final output. Allowed range is from 0.0
1549           to 1.0.  Default value is 1.0.
1550
1551       order
1552           Set filter order used for filtering. Allowed range is from 1 to 16.
1553           Default value is 8.
1554
1555       Commands
1556
1557       This filter supports the all above options as commands.
1558
1559   afwtdn
1560       Reduce broadband noise from input samples using Wavelets.
1561
1562       A description of the accepted options follows.
1563
1564       sigma
1565           Set the noise sigma, allowed range is from 0 to 1.  Default value
1566           is 0.  This option controls strength of denoising applied to input
1567           samples.  Most useful way to set this option is via decibels, eg.
1568           -45dB.
1569
1570       levels
1571           Set the number of wavelet levels of decomposition.  Allowed range
1572           is from 1 to 12.  Default value is 10.  Setting this too low make
1573           denoising performance very poor.
1574
1575       wavet
1576           Set wavelet type for decomposition of input frame.  They are sorted
1577           by number of coefficients, from lowest to highest.  More
1578           coefficients means worse filtering speed, but overall better
1579           quality.  Available wavelets are:
1580
1581           sym2
1582           sym4
1583           rbior68
1584           deb10
1585           sym10
1586           coif5
1587           bl3
1588       percent
1589           Set percent of full denoising. Allowed range is from 0 to 100
1590           percent.  Default value is 85 percent or partial denoising.
1591
1592       profile
1593           If enabled, first input frame will be used as noise profile.  If
1594           first frame samples contain non-noise performance will be very
1595           poor.
1596
1597       adaptive
1598           If enabled, input frames are analyzed for presence of noise.  If
1599           noise is detected with high possibility then input frame profile
1600           will be used for processing following frames, until new noise frame
1601           is detected.
1602
1603       samples
1604           Set size of single frame in number of samples. Allowed range is
1605           from 512 to 65536. Default frame size is 8192 samples.
1606
1607       softness
1608           Set softness applied inside thresholding function. Allowed range is
1609           from 0 to 10. Default softness is 1.
1610
1611       Commands
1612
1613       This filter supports the all above options as commands.
1614
1615   agate
1616       A gate is mainly used to reduce lower parts of a signal. This kind of
1617       signal processing reduces disturbing noise between useful signals.
1618
1619       Gating is done by detecting the volume below a chosen level threshold
1620       and dividing it by the factor set with ratio. The bottom of the noise
1621       floor is set via range. Because an exact manipulation of the signal
1622       would cause distortion of the waveform the reduction can be levelled
1623       over time. This is done by setting attack and release.
1624
1625       attack determines how long the signal has to fall below the threshold
1626       before any reduction will occur and release sets the time the signal
1627       has to rise above the threshold to reduce the reduction again.  Shorter
1628       signals than the chosen attack time will be left untouched.
1629
1630       level_in
1631           Set input level before filtering.  Default is 1. Allowed range is
1632           from 0.015625 to 64.
1633
1634       mode
1635           Set the mode of operation. Can be "upward" or "downward".  Default
1636           is "downward". If set to "upward" mode, higher parts of signal will
1637           be amplified, expanding dynamic range in upward direction.
1638           Otherwise, in case of "downward" lower parts of signal will be
1639           reduced.
1640
1641       range
1642           Set the level of gain reduction when the signal is below the
1643           threshold.  Default is 0.06125. Allowed range is from 0 to 1.
1644           Setting this to 0 disables reduction and then filter behaves like
1645           expander.
1646
1647       threshold
1648           If a signal rises above this level the gain reduction is released.
1649           Default is 0.125. Allowed range is from 0 to 1.
1650
1651       ratio
1652           Set a ratio by which the signal is reduced.  Default is 2. Allowed
1653           range is from 1 to 9000.
1654
1655       attack
1656           Amount of milliseconds the signal has to rise above the threshold
1657           before gain reduction stops.  Default is 20 milliseconds. Allowed
1658           range is from 0.01 to 9000.
1659
1660       release
1661           Amount of milliseconds the signal has to fall below the threshold
1662           before the reduction is increased again. Default is 250
1663           milliseconds.  Allowed range is from 0.01 to 9000.
1664
1665       makeup
1666           Set amount of amplification of signal after processing.  Default is
1667           1. Allowed range is from 1 to 64.
1668
1669       knee
1670           Curve the sharp knee around the threshold to enter gain reduction
1671           more softly.  Default is 2.828427125. Allowed range is from 1 to 8.
1672
1673       detection
1674           Choose if exact signal should be taken for detection or an RMS like
1675           one.  Default is "rms". Can be "peak" or "rms".
1676
1677       link
1678           Choose if the average level between all channels or the louder
1679           channel affects the reduction.  Default is "average". Can be
1680           "average" or "maximum".
1681
1682       Commands
1683
1684       This filter supports the all above options as commands.
1685
1686   aiir
1687       Apply an arbitrary Infinite Impulse Response filter.
1688
1689       It accepts the following parameters:
1690
1691       zeros, z
1692           Set B/numerator/zeros/reflection coefficients.
1693
1694       poles, p
1695           Set A/denominator/poles/ladder coefficients.
1696
1697       gains, k
1698           Set channels gains.
1699
1700       dry_gain
1701           Set input gain.
1702
1703       wet_gain
1704           Set output gain.
1705
1706       format, f
1707           Set coefficients format.
1708
1709           ll  lattice-ladder function
1710
1711           sf  analog transfer function
1712
1713           tf  digital transfer function
1714
1715           zp  Z-plane zeros/poles, cartesian (default)
1716
1717           pr  Z-plane zeros/poles, polar radians
1718
1719           pd  Z-plane zeros/poles, polar degrees
1720
1721           sp  S-plane zeros/poles
1722
1723       process, r
1724           Set type of processing.
1725
1726           d   direct processing
1727
1728           s   serial processing
1729
1730           p   parallel processing
1731
1732       precision, e
1733           Set filtering precision.
1734
1735           dbl double-precision floating-point (default)
1736
1737           flt single-precision floating-point
1738
1739           i32 32-bit integers
1740
1741           i16 16-bit integers
1742
1743       normalize, n
1744           Normalize filter coefficients, by default is enabled.  Enabling it
1745           will normalize magnitude response at DC to 0dB.
1746
1747       mix How much to use filtered signal in output. Default is 1.  Range is
1748           between 0 and 1.
1749
1750       response
1751           Show IR frequency response, magnitude(magenta), phase(green) and
1752           group delay(yellow) in additional video stream.  By default it is
1753           disabled.
1754
1755       channel
1756           Set for which IR channel to display frequency response. By default
1757           is first channel displayed. This option is used only when response
1758           is enabled.
1759
1760       size
1761           Set video stream size. This option is used only when response is
1762           enabled.
1763
1764       Coefficients in "tf" and "sf" format are separated by spaces and are in
1765       ascending order.
1766
1767       Coefficients in "zp" format are separated by spaces and order of
1768       coefficients doesn't matter. Coefficients in "zp" format are complex
1769       numbers with i imaginary unit.
1770
1771       Different coefficients and gains can be provided for every channel, in
1772       such case use '|' to separate coefficients or gains. Last provided
1773       coefficients will be used for all remaining channels.
1774
1775       Examples
1776
1777       •   Apply 2 pole elliptic notch at around 5000Hz for 48000 Hz sample
1778           rate:
1779
1780                   aiir=k=1:z=7.957584807809675810E-1 -2.575128568908332300 3.674839853930788710 -2.57512875289799137 7.957586296317130880E-1:p=1 -2.86950072432325953 3.63022088054647218 -2.28075678147272232 6.361362326477423500E-1:f=tf:r=d
1781
1782       •   Same as above but in "zp" format:
1783
1784                   aiir=k=0.79575848078096756:z=0.80918701+0.58773007i 0.80918701-0.58773007i 0.80884700+0.58784055i 0.80884700-0.58784055i:p=0.63892345+0.59951235i 0.63892345-0.59951235i 0.79582691+0.44198673i 0.79582691-0.44198673i:f=zp:r=s
1785
1786       •   Apply 3-rd order analog normalized Butterworth low-pass filter,
1787           using analog transfer function format:
1788
1789                   aiir=z=1.3057 0 0 0:p=1.3057 2.3892 2.1860 1:f=sf:r=d
1790
1791   alimiter
1792       The limiter prevents an input signal from rising over a desired
1793       threshold.  This limiter uses lookahead technology to prevent your
1794       signal from distorting.  It means that there is a small delay after the
1795       signal is processed. Keep in mind that the delay it produces is the
1796       attack time you set.
1797
1798       The filter accepts the following options:
1799
1800       level_in
1801           Set input gain. Default is 1.
1802
1803       level_out
1804           Set output gain. Default is 1.
1805
1806       limit
1807           Don't let signals above this level pass the limiter. Default is 1.
1808
1809       attack
1810           The limiter will reach its attenuation level in this amount of time
1811           in milliseconds. Default is 5 milliseconds.
1812
1813       release
1814           Come back from limiting to attenuation 1.0 in this amount of
1815           milliseconds.  Default is 50 milliseconds.
1816
1817       asc When gain reduction is always needed ASC takes care of releasing to
1818           an average reduction level rather than reaching a reduction of 0 in
1819           the release time.
1820
1821       asc_level
1822           Select how much the release time is affected by ASC, 0 means nearly
1823           no changes in release time while 1 produces higher release times.
1824
1825       level
1826           Auto level output signal. Default is enabled.  This normalizes
1827           audio back to 0dB if enabled.
1828
1829       latency
1830           Compensate the delay introduced by using the lookahead buffer set
1831           with attack parameter. Also flush the valid audio data in the
1832           lookahead buffer when the stream hits EOF.
1833
1834       Depending on picked setting it is recommended to upsample input 2x or
1835       4x times with aresample before applying this filter.
1836
1837   allpass
1838       Apply a two-pole all-pass filter with central frequency (in Hz)
1839       frequency, and filter-width width.  An all-pass filter changes the
1840       audio's frequency to phase relationship without changing its frequency
1841       to amplitude relationship.
1842
1843       The filter accepts the following options:
1844
1845       frequency, f
1846           Set frequency in Hz.
1847
1848       width_type, t
1849           Set method to specify band-width of filter.
1850
1851           h   Hz
1852
1853           q   Q-Factor
1854
1855           o   octave
1856
1857           s   slope
1858
1859           k   kHz
1860
1861       width, w
1862           Specify the band-width of a filter in width_type units.
1863
1864       mix, m
1865           How much to use filtered signal in output. Default is 1.  Range is
1866           between 0 and 1.
1867
1868       channels, c
1869           Specify which channels to filter, by default all available are
1870           filtered.
1871
1872       normalize, n
1873           Normalize biquad coefficients, by default is disabled.  Enabling it
1874           will normalize magnitude response at DC to 0dB.
1875
1876       order, o
1877           Set the filter order, can be 1 or 2. Default is 2.
1878
1879       transform, a
1880           Set transform type of IIR filter.
1881
1882           di
1883           dii
1884           tdi
1885           tdii
1886           latt
1887           svf
1888           zdf
1889       precision, r
1890           Set precison of filtering.
1891
1892           auto
1893               Pick automatic sample format depending on surround filters.
1894
1895           s16 Always use signed 16-bit.
1896
1897           s32 Always use signed 32-bit.
1898
1899           f32 Always use float 32-bit.
1900
1901           f64 Always use float 64-bit.
1902
1903       Commands
1904
1905       This filter supports the following commands:
1906
1907       frequency, f
1908           Change allpass frequency.  Syntax for the command is : "frequency"
1909
1910       width_type, t
1911           Change allpass width_type.  Syntax for the command is :
1912           "width_type"
1913
1914       width, w
1915           Change allpass width.  Syntax for the command is : "width"
1916
1917       mix, m
1918           Change allpass mix.  Syntax for the command is : "mix"
1919
1920   aloop
1921       Loop audio samples.
1922
1923       The filter accepts the following options:
1924
1925       loop
1926           Set the number of loops. Setting this value to -1 will result in
1927           infinite loops.  Default is 0.
1928
1929       size
1930           Set maximal number of samples. Default is 0.
1931
1932       start
1933           Set first sample of loop. Default is 0.
1934
1935   amerge
1936       Merge two or more audio streams into a single multi-channel stream.
1937
1938       The filter accepts the following options:
1939
1940       inputs
1941           Set the number of inputs. Default is 2.
1942
1943       If the channel layouts of the inputs are disjoint, and therefore
1944       compatible, the channel layout of the output will be set accordingly
1945       and the channels will be reordered as necessary. If the channel layouts
1946       of the inputs are not disjoint, the output will have all the channels
1947       of the first input then all the channels of the second input, in that
1948       order, and the channel layout of the output will be the default value
1949       corresponding to the total number of channels.
1950
1951       For example, if the first input is in 2.1 (FL+FR+LF) and the second
1952       input is FC+BL+BR, then the output will be in 5.1, with the channels in
1953       the following order: a1, a2, b1, a3, b2, b3 (a1 is the first channel of
1954       the first input, b1 is the first channel of the second input).
1955
1956       On the other hand, if both input are in stereo, the output channels
1957       will be in the default order: a1, a2, b1, b2, and the channel layout
1958       will be arbitrarily set to 4.0, which may or may not be the expected
1959       value.
1960
1961       All inputs must have the same sample rate, and format.
1962
1963       If inputs do not have the same duration, the output will stop with the
1964       shortest.
1965
1966       Examples
1967
1968       •   Merge two mono files into a stereo stream:
1969
1970                   amovie=left.wav [l] ; amovie=right.mp3 [r] ; [l] [r] amerge
1971
1972       •   Multiple merges assuming 1 video stream and 6 audio streams in
1973           input.mkv:
1974
1975                   ffmpeg -i input.mkv -filter_complex "[0:1][0:2][0:3][0:4][0:5][0:6] amerge=inputs=6" -c:a pcm_s16le output.mkv
1976
1977   amix
1978       Mixes multiple audio inputs into a single output.
1979
1980       Note that this filter only supports float samples (the amerge and pan
1981       audio filters support many formats). If the amix input has integer
1982       samples then aresample will be automatically inserted to perform the
1983       conversion to float samples.
1984
1985       For example
1986
1987               ffmpeg -i INPUT1 -i INPUT2 -i INPUT3 -filter_complex amix=inputs=3:duration=first:dropout_transition=3 OUTPUT
1988
1989       will mix 3 input audio streams to a single output with the same
1990       duration as the first input and a dropout transition time of 3 seconds.
1991
1992       It accepts the following parameters:
1993
1994       inputs
1995           The number of inputs. If unspecified, it defaults to 2.
1996
1997       duration
1998           How to determine the end-of-stream.
1999
2000           longest
2001               The duration of the longest input. (default)
2002
2003           shortest
2004               The duration of the shortest input.
2005
2006           first
2007               The duration of the first input.
2008
2009       dropout_transition
2010           The transition time, in seconds, for volume renormalization when an
2011           input stream ends. The default value is 2 seconds.
2012
2013       weights
2014           Specify weight of each input audio stream as sequence.  Each weight
2015           is separated by space. By default all inputs have same weight.
2016
2017       normalize
2018           Always scale inputs instead of only doing summation of samples.
2019           Beware of heavy clipping if inputs are not normalized prior or
2020           after filtering by this filter if this option is disabled. By
2021           default is enabled.
2022
2023       Commands
2024
2025       This filter supports the following commands:
2026
2027       weights
2028       normalize
2029           Syntax is same as option with same name.
2030
2031   amultiply
2032       Multiply first audio stream with second audio stream and store result
2033       in output audio stream. Multiplication is done by multiplying each
2034       sample from first stream with sample at same position from second
2035       stream.
2036
2037       With this element-wise multiplication one can create amplitude fades
2038       and amplitude modulations.
2039
2040   anequalizer
2041       High-order parametric multiband equalizer for each channel.
2042
2043       It accepts the following parameters:
2044
2045       params
2046           This option string is in format: "cchn f=cf w=w g=g t=f | ..."
2047           Each equalizer band is separated by '|'.
2048
2049           chn Set channel number to which equalization will be applied.  If
2050               input doesn't have that channel the entry is ignored.
2051
2052           f   Set central frequency for band.  If input doesn't have that
2053               frequency the entry is ignored.
2054
2055           w   Set band width in Hertz.
2056
2057           g   Set band gain in dB.
2058
2059           t   Set filter type for band, optional, can be:
2060
2061               0   Butterworth, this is default.
2062
2063               1   Chebyshev type 1.
2064
2065               2   Chebyshev type 2.
2066
2067       curves
2068           With this option activated frequency response of anequalizer is
2069           displayed in video stream.
2070
2071       size
2072           Set video stream size. Only useful if curves option is activated.
2073
2074       mgain
2075           Set max gain that will be displayed. Only useful if curves option
2076           is activated.  Setting this to a reasonable value makes it possible
2077           to display gain which is derived from neighbour bands which are too
2078           close to each other and thus produce higher gain when both are
2079           activated.
2080
2081       fscale
2082           Set frequency scale used to draw frequency response in video
2083           output.  Can be linear or logarithmic. Default is logarithmic.
2084
2085       colors
2086           Set color for each channel curve which is going to be displayed in
2087           video stream.  This is list of color names separated by space or by
2088           '|'.  Unrecognised or missing colors will be replaced by white
2089           color.
2090
2091       Examples
2092
2093       •   Lower gain by 10 of central frequency 200Hz and width 100 Hz for
2094           first 2 channels using Chebyshev type 1 filter:
2095
2096                   anequalizer=c0 f=200 w=100 g=-10 t=1|c1 f=200 w=100 g=-10 t=1
2097
2098       Commands
2099
2100       This filter supports the following commands:
2101
2102       change
2103           Alter existing filter parameters.  Syntax for the commands is :
2104           "fN|f=freq|w=width|g=gain"
2105
2106           fN is existing filter number, starting from 0, if no such filter is
2107           available error is returned.  freq set new frequency parameter.
2108           width set new width parameter in Hertz.  gain set new gain
2109           parameter in dB.
2110
2111           Full filter invocation with asendcmd may look like this:
2112           asendcmd=c='4.0 anequalizer change
2113           0|f=200|w=50|g=1',anequalizer=...
2114
2115   anlmdn
2116       Reduce broadband noise in audio samples using Non-Local Means
2117       algorithm.
2118
2119       Each sample is adjusted by looking for other samples with similar
2120       contexts. This context similarity is defined by comparing their
2121       surrounding patches of size p. Patches are searched in an area of r
2122       around the sample.
2123
2124       The filter accepts the following options:
2125
2126       strength, s
2127           Set denoising strength. Allowed range is from 0.00001 to 10000.
2128           Default value is 0.00001.
2129
2130       patch, p
2131           Set patch radius duration. Allowed range is from 1 to 100
2132           milliseconds.  Default value is 2 milliseconds.
2133
2134       research, r
2135           Set research radius duration. Allowed range is from 2 to 300
2136           milliseconds.  Default value is 6 milliseconds.
2137
2138       output, o
2139           Set the output mode.
2140
2141           It accepts the following values:
2142
2143           i   Pass input unchanged.
2144
2145           o   Pass noise filtered out.
2146
2147           n   Pass only noise.
2148
2149               Default value is o.
2150
2151       smooth, m
2152           Set smooth factor. Default value is 11. Allowed range is from 1 to
2153           1000.
2154
2155       Commands
2156
2157       This filter supports the all above options as commands.
2158
2159   anlmf, anlms
2160       Apply Normalized Least-Mean-(Squares|Fourth) algorithm to the first
2161       audio stream using the second audio stream.
2162
2163       This adaptive filter is used to mimic a desired filter by finding the
2164       filter coefficients that relate to producing the least mean square of
2165       the error signal (difference between the desired, 2nd input audio
2166       stream and the actual signal, the 1st input audio stream).
2167
2168       A description of the accepted options follows.
2169
2170       order
2171           Set filter order.
2172
2173       mu  Set filter mu.
2174
2175       eps Set the filter eps.
2176
2177       leakage
2178           Set the filter leakage.
2179
2180       out_mode
2181           It accepts the following values:
2182
2183           i   Pass the 1st input.
2184
2185           d   Pass the 2nd input.
2186
2187           o   Pass filtered samples.
2188
2189           n   Pass difference between desired and filtered samples.
2190
2191               Default value is o.
2192
2193       Examples
2194
2195       •   One of many usages of this filter is noise reduction, input audio
2196           is filtered with same samples that are delayed by fixed amount, one
2197           such example for stereo audio is:
2198
2199                   asplit[a][b],[a]adelay=32S|32S[a],[b][a]anlms=order=128:leakage=0.0005:mu=.5:out_mode=o
2200
2201       Commands
2202
2203       This filter supports the same commands as options, excluding option
2204       "order".
2205
2206   anull
2207       Pass the audio source unchanged to the output.
2208
2209   apad
2210       Pad the end of an audio stream with silence.
2211
2212       This can be used together with ffmpeg -shortest to extend audio streams
2213       to the same length as the video stream.
2214
2215       A description of the accepted options follows.
2216
2217       packet_size
2218           Set silence packet size. Default value is 4096.
2219
2220       pad_len
2221           Set the number of samples of silence to add to the end. After the
2222           value is reached, the stream is terminated. This option is mutually
2223           exclusive with whole_len.
2224
2225       whole_len
2226           Set the minimum total number of samples in the output audio stream.
2227           If the value is longer than the input audio length, silence is
2228           added to the end, until the value is reached. This option is
2229           mutually exclusive with pad_len.
2230
2231       pad_dur
2232           Specify the duration of samples of silence to add. See the Time
2233           duration section in the ffmpeg-utils(1) manual for the accepted
2234           syntax. Used only if set to non-negative value.
2235
2236       whole_dur
2237           Specify the minimum total duration in the output audio stream. See
2238           the Time duration section in the ffmpeg-utils(1) manual for the
2239           accepted syntax. Used only if set to non-negative value. If the
2240           value is longer than the input audio length, silence is added to
2241           the end, until the value is reached.  This option is mutually
2242           exclusive with pad_dur
2243
2244       If neither the pad_len nor the whole_len nor pad_dur nor whole_dur
2245       option is set, the filter will add silence to the end of the input
2246       stream indefinitely.
2247
2248       Note that for ffmpeg 4.4 and earlier a zero pad_dur or whole_dur also
2249       caused the filter to add silence indefinitely.
2250
2251       Examples
2252
2253       •   Add 1024 samples of silence to the end of the input:
2254
2255                   apad=pad_len=1024
2256
2257       •   Make sure the audio output will contain at least 10000 samples, pad
2258           the input with silence if required:
2259
2260                   apad=whole_len=10000
2261
2262       •   Use ffmpeg to pad the audio input with silence, so that the video
2263           stream will always result the shortest and will be converted until
2264           the end in the output file when using the shortest option:
2265
2266                   ffmpeg -i VIDEO -i AUDIO -filter_complex "[1:0]apad" -shortest OUTPUT
2267
2268   aphaser
2269       Add a phasing effect to the input audio.
2270
2271       A phaser filter creates series of peaks and troughs in the frequency
2272       spectrum.  The position of the peaks and troughs are modulated so that
2273       they vary over time, creating a sweeping effect.
2274
2275       A description of the accepted parameters follows.
2276
2277       in_gain
2278           Set input gain. Default is 0.4.
2279
2280       out_gain
2281           Set output gain. Default is 0.74
2282
2283       delay
2284           Set delay in milliseconds. Default is 3.0.
2285
2286       decay
2287           Set decay. Default is 0.4.
2288
2289       speed
2290           Set modulation speed in Hz. Default is 0.5.
2291
2292       type
2293           Set modulation type. Default is triangular.
2294
2295           It accepts the following values:
2296
2297           triangular, t
2298           sinusoidal, s
2299
2300   aphaseshift
2301       Apply phase shift to input audio samples.
2302
2303       The filter accepts the following options:
2304
2305       shift
2306           Specify phase shift. Allowed range is from -1.0 to 1.0.  Default
2307           value is 0.0.
2308
2309       level
2310           Set output gain applied to final output. Allowed range is from 0.0
2311           to 1.0.  Default value is 1.0.
2312
2313       order
2314           Set filter order used for filtering. Allowed range is from 1 to 16.
2315           Default value is 8.
2316
2317       Commands
2318
2319       This filter supports the all above options as commands.
2320
2321   apsyclip
2322       Apply Psychoacoustic clipper to input audio stream.
2323
2324       The filter accepts the following options:
2325
2326       level_in
2327           Set input gain. By default it is 1. Range is [0.015625 - 64].
2328
2329       level_out
2330           Set output gain. By default it is 1. Range is [0.015625 - 64].
2331
2332       clip
2333           Set the clipping start value. Default value is 0dBFS or 1.
2334
2335       diff
2336           Output only difference samples, useful to hear introduced
2337           distortions.  By default is disabled.
2338
2339       adaptive
2340           Set strength of adaptive distortion applied. Default value is 0.5.
2341           Allowed range is from 0 to 1.
2342
2343       iterations
2344           Set number of iterations of psychoacoustic clipper.  Allowed range
2345           is from 1 to 20. Default value is 10.
2346
2347       level
2348           Auto level output signal. Default is disabled.  This normalizes
2349           audio back to 0dBFS if enabled.
2350
2351       Commands
2352
2353       This filter supports the all above options as commands.
2354
2355   apulsator
2356       Audio pulsator is something between an autopanner and a tremolo.  But
2357       it can produce funny stereo effects as well. Pulsator changes the
2358       volume of the left and right channel based on a LFO (low frequency
2359       oscillator) with different waveforms and shifted phases.  This filter
2360       have the ability to define an offset between left and right channel. An
2361       offset of 0 means that both LFO shapes match each other.  The left and
2362       right channel are altered equally - a conventional tremolo.  An offset
2363       of 50% means that the shape of the right channel is exactly shifted in
2364       phase (or moved backwards about half of the frequency) - pulsator acts
2365       as an autopanner. At 1 both curves match again. Every setting in
2366       between moves the phase shift gapless between all stages and produces
2367       some "bypassing" sounds with sine and triangle waveforms. The more you
2368       set the offset near 1 (starting from the 0.5) the faster the signal
2369       passes from the left to the right speaker.
2370
2371       The filter accepts the following options:
2372
2373       level_in
2374           Set input gain. By default it is 1. Range is [0.015625 - 64].
2375
2376       level_out
2377           Set output gain. By default it is 1. Range is [0.015625 - 64].
2378
2379       mode
2380           Set waveform shape the LFO will use. Can be one of: sine, triangle,
2381           square, sawup or sawdown. Default is sine.
2382
2383       amount
2384           Set modulation. Define how much of original signal is affected by
2385           the LFO.
2386
2387       offset_l
2388           Set left channel offset. Default is 0. Allowed range is [0 - 1].
2389
2390       offset_r
2391           Set right channel offset. Default is 0.5. Allowed range is [0 - 1].
2392
2393       width
2394           Set pulse width. Default is 1. Allowed range is [0 - 2].
2395
2396       timing
2397           Set possible timing mode. Can be one of: bpm, ms or hz. Default is
2398           hz.
2399
2400       bpm Set bpm. Default is 120. Allowed range is [30 - 300]. Only used if
2401           timing is set to bpm.
2402
2403       ms  Set ms. Default is 500. Allowed range is [10 - 2000]. Only used if
2404           timing is set to ms.
2405
2406       hz  Set frequency in Hz. Default is 2. Allowed range is [0.01 - 100].
2407           Only used if timing is set to hz.
2408
2409   aresample
2410       Resample the input audio to the specified parameters, using the
2411       libswresample library. If none are specified then the filter will
2412       automatically convert between its input and output.
2413
2414       This filter is also able to stretch/squeeze the audio data to make it
2415       match the timestamps or to inject silence / cut out audio to make it
2416       match the timestamps, do a combination of both or do neither.
2417
2418       The filter accepts the syntax [sample_rate:]resampler_options, where
2419       sample_rate expresses a sample rate and resampler_options is a list of
2420       key=value pairs, separated by ":". See the "Resampler Options" section
2421       in the ffmpeg-resampler(1) manual for the complete list of supported
2422       options.
2423
2424       Examples
2425
2426       •   Resample the input audio to 44100Hz:
2427
2428                   aresample=44100
2429
2430       •   Stretch/squeeze samples to the given timestamps, with a maximum of
2431           1000 samples per second compensation:
2432
2433                   aresample=async=1000
2434
2435   areverse
2436       Reverse an audio clip.
2437
2438       Warning: This filter requires memory to buffer the entire clip, so
2439       trimming is suggested.
2440
2441       Examples
2442
2443       •   Take the first 5 seconds of a clip, and reverse it.
2444
2445                   atrim=end=5,areverse
2446
2447   arnndn
2448       Reduce noise from speech using Recurrent Neural Networks.
2449
2450       This filter accepts the following options:
2451
2452       model, m
2453           Set train model file to load. This option is always required.
2454
2455       mix Set how much to mix filtered samples into final output.  Allowed
2456           range is from -1 to 1. Default value is 1.  Negative values are
2457           special, they set how much to keep filtered noise in the final
2458           filter output. Set this option to -1 to hear actual noise removed
2459           from input signal.
2460
2461       Commands
2462
2463       This filter supports the all above options as commands.
2464
2465   asdr
2466       Measure Audio Signal-to-Distortion Ratio.
2467
2468       This filter takes two audio streams for input, and outputs first audio
2469       stream.  Results are in dB per channel at end of either input.
2470
2471   asetnsamples
2472       Set the number of samples per each output audio frame.
2473
2474       The last output packet may contain a different number of samples, as
2475       the filter will flush all the remaining samples when the input audio
2476       signals its end.
2477
2478       The filter accepts the following options:
2479
2480       nb_out_samples, n
2481           Set the number of frames per each output audio frame. The number is
2482           intended as the number of samples per each channel.  Default value
2483           is 1024.
2484
2485       pad, p
2486           If set to 1, the filter will pad the last audio frame with zeroes,
2487           so that the last frame will contain the same number of samples as
2488           the previous ones. Default value is 1.
2489
2490       For example, to set the number of per-frame samples to 1234 and disable
2491       padding for the last frame, use:
2492
2493               asetnsamples=n=1234:p=0
2494
2495   asetrate
2496       Set the sample rate without altering the PCM data.  This will result in
2497       a change of speed and pitch.
2498
2499       The filter accepts the following options:
2500
2501       sample_rate, r
2502           Set the output sample rate. Default is 44100 Hz.
2503
2504   ashowinfo
2505       Show a line containing various information for each input audio frame.
2506       The input audio is not modified.
2507
2508       The shown line contains a sequence of key/value pairs of the form
2509       key:value.
2510
2511       The following values are shown in the output:
2512
2513       n   The (sequential) number of the input frame, starting from 0.
2514
2515       pts The presentation timestamp of the input frame, in time base units;
2516           the time base depends on the filter input pad, and is usually
2517           1/sample_rate.
2518
2519       pts_time
2520           The presentation timestamp of the input frame in seconds.
2521
2522       pos position of the frame in the input stream, -1 if this information
2523           in unavailable and/or meaningless (for example in case of synthetic
2524           audio)
2525
2526       fmt The sample format.
2527
2528       chlayout
2529           The channel layout.
2530
2531       rate
2532           The sample rate for the audio frame.
2533
2534       nb_samples
2535           The number of samples (per channel) in the frame.
2536
2537       checksum
2538           The Adler-32 checksum (printed in hexadecimal) of the audio data.
2539           For planar audio, the data is treated as if all the planes were
2540           concatenated.
2541
2542       plane_checksums
2543           A list of Adler-32 checksums for each data plane.
2544
2545   asoftclip
2546       Apply audio soft clipping.
2547
2548       Soft clipping is a type of distortion effect where the amplitude of a
2549       signal is saturated along a smooth curve, rather than the abrupt shape
2550       of hard-clipping.
2551
2552       This filter accepts the following options:
2553
2554       type
2555           Set type of soft-clipping.
2556
2557           It accepts the following values:
2558
2559           hard
2560           tanh
2561           atan
2562           cubic
2563           exp
2564           alg
2565           quintic
2566           sin
2567           erf
2568       threshold
2569           Set threshold from where to start clipping. Default value is 0dB or
2570           1.
2571
2572       output
2573           Set gain applied to output. Default value is 0dB or 1.
2574
2575       param
2576           Set additional parameter which controls sigmoid function.
2577
2578       oversample
2579           Set oversampling factor.
2580
2581       Commands
2582
2583       This filter supports the all above options as commands.
2584
2585   aspectralstats
2586       Display frequency domain statistical information about the audio
2587       channels.  Statistics are calculated and stored as metadata for each
2588       audio channel and for each audio frame.
2589
2590       It accepts the following option:
2591
2592       win_size
2593           Set the window length in samples. Default value is 2048.  Allowed
2594           range is from 32 to 65536.
2595
2596       win_func
2597           Set window function.
2598
2599           It accepts the following values:
2600
2601           rect
2602           bartlett
2603           hann, hanning
2604           hamming
2605           blackman
2606           welch
2607           flattop
2608           bharris
2609           bnuttall
2610           bhann
2611           sine
2612           nuttall
2613           lanczos
2614           gauss
2615           tukey
2616           dolph
2617           cauchy
2618           parzen
2619           poisson
2620           bohman
2621
2622           Default is "hann".
2623
2624       overlap
2625           Set window overlap. Allowed range is from 0 to 1. Default value is
2626           0.5.
2627
2628       A list of each metadata key follows:
2629
2630       mean
2631       variance
2632       centroid
2633       spread
2634       skewness
2635       kurtosis
2636       entropy
2637       flatness
2638       crest
2639       flux
2640       slope
2641       decrease
2642       rolloff
2643
2644   asr
2645       Automatic Speech Recognition
2646
2647       This filter uses PocketSphinx for speech recognition. To enable
2648       compilation of this filter, you need to configure FFmpeg with
2649       "--enable-pocketsphinx".
2650
2651       It accepts the following options:
2652
2653       rate
2654           Set sampling rate of input audio. Defaults is 16000.  This need to
2655           match speech models, otherwise one will get poor results.
2656
2657       hmm Set dictionary containing acoustic model files.
2658
2659       dict
2660           Set pronunciation dictionary.
2661
2662       lm  Set language model file.
2663
2664       lmctl
2665           Set language model set.
2666
2667       lmname
2668           Set which language model to use.
2669
2670       logfn
2671           Set output for log messages.
2672
2673       The filter exports recognized speech as the frame metadata
2674       "lavfi.asr.text".
2675
2676   astats
2677       Display time domain statistical information about the audio channels.
2678       Statistics are calculated and displayed for each audio channel and,
2679       where applicable, an overall figure is also given.
2680
2681       It accepts the following option:
2682
2683       length
2684           Short window length in seconds, used for peak and trough RMS
2685           measurement.  Default is 0.05 (50 milliseconds). Allowed range is
2686           "[0 - 10]".
2687
2688       metadata
2689           Set metadata injection. All the metadata keys are prefixed with
2690           "lavfi.astats.X", where "X" is channel number starting from 1 or
2691           string "Overall". Default is disabled.
2692
2693           Available keys for each channel are: DC_offset Min_level Max_level
2694           Min_difference Max_difference Mean_difference RMS_difference
2695           Peak_level RMS_peak RMS_trough Crest_factor Flat_factor Peak_count
2696           Noise_floor Noise_floor_count Entropy Bit_depth Dynamic_range
2697           Zero_crossings Zero_crossings_rate Number_of_NaNs Number_of_Infs
2698           Number_of_denormals
2699
2700           and for Overall: DC_offset Min_level Max_level Min_difference
2701           Max_difference Mean_difference RMS_difference Peak_level RMS_level
2702           RMS_peak RMS_trough Flat_factor Peak_count Noise_floor
2703           Noise_floor_count Entropy Bit_depth Number_of_samples
2704           Number_of_NaNs Number_of_Infs Number_of_denormals
2705
2706           For example full key look like this "lavfi.astats.1.DC_offset" or
2707           this "lavfi.astats.Overall.Peak_count".
2708
2709           For description what each key means read below.
2710
2711       reset
2712           Set the number of frames over which cumulative stats are calculated
2713           before being reset Default is disabled.
2714
2715       measure_perchannel
2716           Select the parameters which are measured per channel. The metadata
2717           keys can be used as flags, default is all which measures
2718           everything.  none disables all per channel measurement.
2719
2720       measure_overall
2721           Select the parameters which are measured overall. The metadata keys
2722           can be used as flags, default is all which measures everything.
2723           none disables all overall measurement.
2724
2725       A description of each shown parameter follows:
2726
2727       DC offset
2728           Mean amplitude displacement from zero.
2729
2730       Min level
2731           Minimal sample level.
2732
2733       Max level
2734           Maximal sample level.
2735
2736       Min difference
2737           Minimal difference between two consecutive samples.
2738
2739       Max difference
2740           Maximal difference between two consecutive samples.
2741
2742       Mean difference
2743           Mean difference between two consecutive samples.  The average of
2744           each difference between two consecutive samples.
2745
2746       RMS difference
2747           Root Mean Square difference between two consecutive samples.
2748
2749       Peak level dB
2750       RMS level dB
2751           Standard peak and RMS level measured in dBFS.
2752
2753       RMS peak dB
2754       RMS trough dB
2755           Peak and trough values for RMS level measured over a short window.
2756
2757       Crest factor
2758           Standard ratio of peak to RMS level (note: not in dB).
2759
2760       Flat factor
2761           Flatness (i.e. consecutive samples with the same value) of the
2762           signal at its peak levels (i.e. either Min level or Max level).
2763
2764       Peak count
2765           Number of occasions (not the number of samples) that the signal
2766           attained either Min level or Max level.
2767
2768       Noise floor dB
2769           Minimum local peak measured in dBFS over a short window.
2770
2771       Noise floor count
2772           Number of occasions (not the number of samples) that the signal
2773           attained Noise floor.
2774
2775       Entropy
2776           Entropy measured across whole audio. Entropy of value near 1.0 is
2777           typically measured for white noise.
2778
2779       Bit depth
2780           Overall bit depth of audio. Number of bits used for each sample.
2781
2782       Dynamic range
2783           Measured dynamic range of audio in dB.
2784
2785       Zero crossings
2786           Number of points where the waveform crosses the zero level axis.
2787
2788       Zero crossings rate
2789           Rate of Zero crossings and number of audio samples.
2790
2791   asubboost
2792       Boost subwoofer frequencies.
2793
2794       The filter accepts the following options:
2795
2796       dry Set dry gain, how much of original signal is kept. Allowed range is
2797           from 0 to 1.  Default value is 1.0.
2798
2799       wet Set wet gain, how much of filtered signal is kept. Allowed range is
2800           from 0 to 1.  Default value is 1.0.
2801
2802       boost
2803           Set max boost factor. Allowed range is from 1 to 12. Default value
2804           is 2.
2805
2806       decay
2807           Set delay line decay gain value. Allowed range is from 0 to 1.
2808           Default value is 0.0.
2809
2810       feedback
2811           Set delay line feedback gain value. Allowed range is from 0 to 1.
2812           Default value is 0.9.
2813
2814       cutoff
2815           Set cutoff frequency in Hertz. Allowed range is 50 to 900.  Default
2816           value is 100.
2817
2818       slope
2819           Set slope amount for cutoff frequency. Allowed range is 0.0001 to
2820           1.  Default value is 0.5.
2821
2822       delay
2823           Set delay. Allowed range is from 1 to 100.  Default value is 20.
2824
2825       channels
2826           Set the channels to process. Default value is all available.
2827
2828       Commands
2829
2830       This filter supports the all above options as commands.
2831
2832   asubcut
2833       Cut subwoofer frequencies.
2834
2835       This filter allows to set custom, steeper roll off than highpass
2836       filter, and thus is able to more attenuate frequency content in stop-
2837       band.
2838
2839       The filter accepts the following options:
2840
2841       cutoff
2842           Set cutoff frequency in Hertz. Allowed range is 2 to 200.  Default
2843           value is 20.
2844
2845       order
2846           Set filter order. Available values are from 3 to 20.  Default value
2847           is 10.
2848
2849       level
2850           Set input gain level. Allowed range is from 0 to 1. Default value
2851           is 1.
2852
2853       Commands
2854
2855       This filter supports the all above options as commands.
2856
2857   asupercut
2858       Cut super frequencies.
2859
2860       The filter accepts the following options:
2861
2862       cutoff
2863           Set cutoff frequency in Hertz. Allowed range is 20000 to 192000.
2864           Default value is 20000.
2865
2866       order
2867           Set filter order. Available values are from 3 to 20.  Default value
2868           is 10.
2869
2870       level
2871           Set input gain level. Allowed range is from 0 to 1. Default value
2872           is 1.
2873
2874       Commands
2875
2876       This filter supports the all above options as commands.
2877
2878   asuperpass
2879       Apply high order Butterworth band-pass filter.
2880
2881       The filter accepts the following options:
2882
2883       centerf
2884           Set center frequency in Hertz. Allowed range is 2 to 999999.
2885           Default value is 1000.
2886
2887       order
2888           Set filter order. Available values are from 4 to 20.  Default value
2889           is 4.
2890
2891       qfactor
2892           Set Q-factor. Allowed range is from 0.01 to 100. Default value is
2893           1.
2894
2895       level
2896           Set input gain level. Allowed range is from 0 to 2. Default value
2897           is 1.
2898
2899       Commands
2900
2901       This filter supports the all above options as commands.
2902
2903   asuperstop
2904       Apply high order Butterworth band-stop filter.
2905
2906       The filter accepts the following options:
2907
2908       centerf
2909           Set center frequency in Hertz. Allowed range is 2 to 999999.
2910           Default value is 1000.
2911
2912       order
2913           Set filter order. Available values are from 4 to 20.  Default value
2914           is 4.
2915
2916       qfactor
2917           Set Q-factor. Allowed range is from 0.01 to 100. Default value is
2918           1.
2919
2920       level
2921           Set input gain level. Allowed range is from 0 to 2. Default value
2922           is 1.
2923
2924       Commands
2925
2926       This filter supports the all above options as commands.
2927
2928   atempo
2929       Adjust audio tempo.
2930
2931       The filter accepts exactly one parameter, the audio tempo. If not
2932       specified then the filter will assume nominal 1.0 tempo. Tempo must be
2933       in the [0.5, 100.0] range.
2934
2935       Note that tempo greater than 2 will skip some samples rather than blend
2936       them in.  If for any reason this is a concern it is always possible to
2937       daisy-chain several instances of atempo to achieve the desired product
2938       tempo.
2939
2940       Examples
2941
2942       •   Slow down audio to 80% tempo:
2943
2944                   atempo=0.8
2945
2946       •   To speed up audio to 300% tempo:
2947
2948                   atempo=3
2949
2950       •   To speed up audio to 300% tempo by daisy-chaining two atempo
2951           instances:
2952
2953                   atempo=sqrt(3),atempo=sqrt(3)
2954
2955       Commands
2956
2957       This filter supports the following commands:
2958
2959       tempo
2960           Change filter tempo scale factor.  Syntax for the command is :
2961           "tempo"
2962
2963   atilt
2964       Apply spectral tilt filter to audio stream.
2965
2966       This filter apply any spectral roll-off slope over any specified
2967       frequency band.
2968
2969       The filter accepts the following options:
2970
2971       freq
2972           Set central frequency of tilt in Hz. Default is 10000 Hz.
2973
2974       slope
2975           Set slope direction of tilt. Default is 0. Allowed range is from -1
2976           to 1.
2977
2978       width
2979           Set width of tilt. Default is 1000. Allowed range is from 100 to
2980           10000.
2981
2982       order
2983           Set order of tilt filter.
2984
2985       level
2986           Set input volume level. Allowed range is from 0 to 4.  Defalt is 1.
2987
2988       Commands
2989
2990       This filter supports the all above options as commands.
2991
2992   atrim
2993       Trim the input so that the output contains one continuous subpart of
2994       the input.
2995
2996       It accepts the following parameters:
2997
2998       start
2999           Timestamp (in seconds) of the start of the section to keep. I.e.
3000           the audio sample with the timestamp start will be the first sample
3001           in the output.
3002
3003       end Specify time of the first audio sample that will be dropped, i.e.
3004           the audio sample immediately preceding the one with the timestamp
3005           end will be the last sample in the output.
3006
3007       start_pts
3008           Same as start, except this option sets the start timestamp in
3009           samples instead of seconds.
3010
3011       end_pts
3012           Same as end, except this option sets the end timestamp in samples
3013           instead of seconds.
3014
3015       duration
3016           The maximum duration of the output in seconds.
3017
3018       start_sample
3019           The number of the first sample that should be output.
3020
3021       end_sample
3022           The number of the first sample that should be dropped.
3023
3024       start, end, and duration are expressed as time duration specifications;
3025       see the Time duration section in the ffmpeg-utils(1) manual.
3026
3027       Note that the first two sets of the start/end options and the duration
3028       option look at the frame timestamp, while the _sample options simply
3029       count the samples that pass through the filter. So start/end_pts and
3030       start/end_sample will give different results when the timestamps are
3031       wrong, inexact or do not start at zero. Also note that this filter does
3032       not modify the timestamps. If you wish to have the output timestamps
3033       start at zero, insert the asetpts filter after the atrim filter.
3034
3035       If multiple start or end options are set, this filter tries to be
3036       greedy and keep all samples that match at least one of the specified
3037       constraints. To keep only the part that matches all the constraints at
3038       once, chain multiple atrim filters.
3039
3040       The defaults are such that all the input is kept. So it is possible to
3041       set e.g.  just the end values to keep everything before the specified
3042       time.
3043
3044       Examples:
3045
3046       •   Drop everything except the second minute of input:
3047
3048                   ffmpeg -i INPUT -af atrim=60:120
3049
3050       •   Keep only the first 1000 samples:
3051
3052                   ffmpeg -i INPUT -af atrim=end_sample=1000
3053
3054   axcorrelate
3055       Calculate normalized windowed cross-correlation between two input audio
3056       streams.
3057
3058       Resulted samples are always between -1 and 1 inclusive.  If result is 1
3059       it means two input samples are highly correlated in that selected
3060       segment.  Result 0 means they are not correlated at all.  If result is
3061       -1 it means two input samples are out of phase, which means they cancel
3062       each other.
3063
3064       The filter accepts the following options:
3065
3066       size
3067           Set size of segment over which cross-correlation is calculated.
3068           Default is 256. Allowed range is from 2 to 131072.
3069
3070       algo
3071           Set algorithm for cross-correlation. Can be "slow" or "fast".
3072           Default is "slow". Fast algorithm assumes mean values over any
3073           given segment are always zero and thus need much less calculations
3074           to make.  This is generally not true, but is valid for typical
3075           audio streams.
3076
3077       Examples
3078
3079       •   Calculate correlation between channels in stereo audio stream:
3080
3081                   ffmpeg -i stereo.wav -af channelsplit,axcorrelate=size=1024:algo=fast correlation.wav
3082
3083   bandpass
3084       Apply a two-pole Butterworth band-pass filter with central frequency
3085       frequency, and (3dB-point) band-width width.  The csg option selects a
3086       constant skirt gain (peak gain = Q) instead of the default: constant
3087       0dB peak gain.  The filter roll off at 6dB per octave (20dB per
3088       decade).
3089
3090       The filter accepts the following options:
3091
3092       frequency, f
3093           Set the filter's central frequency. Default is 3000.
3094
3095       csg Constant skirt gain if set to 1. Defaults to 0.
3096
3097       width_type, t
3098           Set method to specify band-width of filter.
3099
3100           h   Hz
3101
3102           q   Q-Factor
3103
3104           o   octave
3105
3106           s   slope
3107
3108           k   kHz
3109
3110       width, w
3111           Specify the band-width of a filter in width_type units.
3112
3113       mix, m
3114           How much to use filtered signal in output. Default is 1.  Range is
3115           between 0 and 1.
3116
3117       channels, c
3118           Specify which channels to filter, by default all available are
3119           filtered.
3120
3121       normalize, n
3122           Normalize biquad coefficients, by default is disabled.  Enabling it
3123           will normalize magnitude response at DC to 0dB.
3124
3125       transform, a
3126           Set transform type of IIR filter.
3127
3128           di
3129           dii
3130           tdi
3131           tdii
3132           latt
3133           svf
3134           zdf
3135       precision, r
3136           Set precison of filtering.
3137
3138           auto
3139               Pick automatic sample format depending on surround filters.
3140
3141           s16 Always use signed 16-bit.
3142
3143           s32 Always use signed 32-bit.
3144
3145           f32 Always use float 32-bit.
3146
3147           f64 Always use float 64-bit.
3148
3149       block_size, b
3150           Set block size used for reverse IIR processing. If this value is
3151           set to high enough value (higher than impulse response length
3152           truncated when reaches near zero values) filtering will become
3153           linear phase otherwise if not big enough it will just produce nasty
3154           artifacts.
3155
3156           Note that filter delay will be exactly this many samples when set
3157           to non-zero value.
3158
3159       Commands
3160
3161       This filter supports the following commands:
3162
3163       frequency, f
3164           Change bandpass frequency.  Syntax for the command is : "frequency"
3165
3166       width_type, t
3167           Change bandpass width_type.  Syntax for the command is :
3168           "width_type"
3169
3170       width, w
3171           Change bandpass width.  Syntax for the command is : "width"
3172
3173       mix, m
3174           Change bandpass mix.  Syntax for the command is : "mix"
3175
3176   bandreject
3177       Apply a two-pole Butterworth band-reject filter with central frequency
3178       frequency, and (3dB-point) band-width width.  The filter roll off at
3179       6dB per octave (20dB per decade).
3180
3181       The filter accepts the following options:
3182
3183       frequency, f
3184           Set the filter's central frequency. Default is 3000.
3185
3186       width_type, t
3187           Set method to specify band-width of filter.
3188
3189           h   Hz
3190
3191           q   Q-Factor
3192
3193           o   octave
3194
3195           s   slope
3196
3197           k   kHz
3198
3199       width, w
3200           Specify the band-width of a filter in width_type units.
3201
3202       mix, m
3203           How much to use filtered signal in output. Default is 1.  Range is
3204           between 0 and 1.
3205
3206       channels, c
3207           Specify which channels to filter, by default all available are
3208           filtered.
3209
3210       normalize, n
3211           Normalize biquad coefficients, by default is disabled.  Enabling it
3212           will normalize magnitude response at DC to 0dB.
3213
3214       transform, a
3215           Set transform type of IIR filter.
3216
3217           di
3218           dii
3219           tdi
3220           tdii
3221           latt
3222           svf
3223           zdf
3224       precision, r
3225           Set precison of filtering.
3226
3227           auto
3228               Pick automatic sample format depending on surround filters.
3229
3230           s16 Always use signed 16-bit.
3231
3232           s32 Always use signed 32-bit.
3233
3234           f32 Always use float 32-bit.
3235
3236           f64 Always use float 64-bit.
3237
3238       block_size, b
3239           Set block size used for reverse IIR processing. If this value is
3240           set to high enough value (higher than impulse response length
3241           truncated when reaches near zero values) filtering will become
3242           linear phase otherwise if not big enough it will just produce nasty
3243           artifacts.
3244
3245           Note that filter delay will be exactly this many samples when set
3246           to non-zero value.
3247
3248       Commands
3249
3250       This filter supports the following commands:
3251
3252       frequency, f
3253           Change bandreject frequency.  Syntax for the command is :
3254           "frequency"
3255
3256       width_type, t
3257           Change bandreject width_type.  Syntax for the command is :
3258           "width_type"
3259
3260       width, w
3261           Change bandreject width.  Syntax for the command is : "width"
3262
3263       mix, m
3264           Change bandreject mix.  Syntax for the command is : "mix"
3265
3266   bass, lowshelf
3267       Boost or cut the bass (lower) frequencies of the audio using a two-pole
3268       shelving filter with a response similar to that of a standard hi-fi's
3269       tone-controls. This is also known as shelving equalisation (EQ).
3270
3271       The filter accepts the following options:
3272
3273       gain, g
3274           Give the gain at 0 Hz. Its useful range is about -20 (for a large
3275           cut) to +20 (for a large boost).  Beware of clipping when using a
3276           positive gain.
3277
3278       frequency, f
3279           Set the filter's central frequency and so can be used to extend or
3280           reduce the frequency range to be boosted or cut.  The default value
3281           is 100 Hz.
3282
3283       width_type, t
3284           Set method to specify band-width of filter.
3285
3286           h   Hz
3287
3288           q   Q-Factor
3289
3290           o   octave
3291
3292           s   slope
3293
3294           k   kHz
3295
3296       width, w
3297           Determine how steep is the filter's shelf transition.
3298
3299       poles, p
3300           Set number of poles. Default is 2.
3301
3302       mix, m
3303           How much to use filtered signal in output. Default is 1.  Range is
3304           between 0 and 1.
3305
3306       channels, c
3307           Specify which channels to filter, by default all available are
3308           filtered.
3309
3310       normalize, n
3311           Normalize biquad coefficients, by default is disabled.  Enabling it
3312           will normalize magnitude response at DC to 0dB.
3313
3314       transform, a
3315           Set transform type of IIR filter.
3316
3317           di
3318           dii
3319           tdi
3320           tdii
3321           latt
3322           svf
3323           zdf
3324       precision, r
3325           Set precison of filtering.
3326
3327           auto
3328               Pick automatic sample format depending on surround filters.
3329
3330           s16 Always use signed 16-bit.
3331
3332           s32 Always use signed 32-bit.
3333
3334           f32 Always use float 32-bit.
3335
3336           f64 Always use float 64-bit.
3337
3338       block_size, b
3339           Set block size used for reverse IIR processing. If this value is
3340           set to high enough value (higher than impulse response length
3341           truncated when reaches near zero values) filtering will become
3342           linear phase otherwise if not big enough it will just produce nasty
3343           artifacts.
3344
3345           Note that filter delay will be exactly this many samples when set
3346           to non-zero value.
3347
3348       Commands
3349
3350       This filter supports the following commands:
3351
3352       frequency, f
3353           Change bass frequency.  Syntax for the command is : "frequency"
3354
3355       width_type, t
3356           Change bass width_type.  Syntax for the command is : "width_type"
3357
3358       width, w
3359           Change bass width.  Syntax for the command is : "width"
3360
3361       gain, g
3362           Change bass gain.  Syntax for the command is : "gain"
3363
3364       mix, m
3365           Change bass mix.  Syntax for the command is : "mix"
3366
3367   biquad
3368       Apply a biquad IIR filter with the given coefficients.  Where b0, b1,
3369       b2 and a0, a1, a2 are the numerator and denominator coefficients
3370       respectively.  and channels, c specify which channels to filter, by
3371       default all available are filtered.
3372
3373       Commands
3374
3375       This filter supports the following commands:
3376
3377       a0
3378       a1
3379       a2
3380       b0
3381       b1
3382       b2  Change biquad parameter.  Syntax for the command is : "value"
3383
3384       mix, m
3385           How much to use filtered signal in output. Default is 1.  Range is
3386           between 0 and 1.
3387
3388       channels, c
3389           Specify which channels to filter, by default all available are
3390           filtered.
3391
3392       normalize, n
3393           Normalize biquad coefficients, by default is disabled.  Enabling it
3394           will normalize magnitude response at DC to 0dB.
3395
3396       transform, a
3397           Set transform type of IIR filter.
3398
3399           di
3400           dii
3401           tdi
3402           tdii
3403           latt
3404           svf
3405           zdf
3406       precision, r
3407           Set precison of filtering.
3408
3409           auto
3410               Pick automatic sample format depending on surround filters.
3411
3412           s16 Always use signed 16-bit.
3413
3414           s32 Always use signed 32-bit.
3415
3416           f32 Always use float 32-bit.
3417
3418           f64 Always use float 64-bit.
3419
3420       block_size, b
3421           Set block size used for reverse IIR processing. If this value is
3422           set to high enough value (higher than impulse response length
3423           truncated when reaches near zero values) filtering will become
3424           linear phase otherwise if not big enough it will just produce nasty
3425           artifacts.
3426
3427           Note that filter delay will be exactly this many samples when set
3428           to non-zero value.
3429
3430   bs2b
3431       Bauer stereo to binaural transformation, which improves headphone
3432       listening of stereo audio records.
3433
3434       To enable compilation of this filter you need to configure FFmpeg with
3435       "--enable-libbs2b".
3436
3437       It accepts the following parameters:
3438
3439       profile
3440           Pre-defined crossfeed level.
3441
3442           default
3443               Default level (fcut=700, feed=50).
3444
3445           cmoy
3446               Chu Moy circuit (fcut=700, feed=60).
3447
3448           jmeier
3449               Jan Meier circuit (fcut=650, feed=95).
3450
3451       fcut
3452           Cut frequency (in Hz).
3453
3454       feed
3455           Feed level (in Hz).
3456
3457   channelmap
3458       Remap input channels to new locations.
3459
3460       It accepts the following parameters:
3461
3462       map Map channels from input to output. The argument is a '|'-separated
3463           list of mappings, each in the "in_channel-out_channel" or
3464           in_channel form. in_channel can be either the name of the input
3465           channel (e.g. FL for front left) or its index in the input channel
3466           layout.  out_channel is the name of the output channel or its index
3467           in the output channel layout. If out_channel is not given then it
3468           is implicitly an index, starting with zero and increasing by one
3469           for each mapping.
3470
3471       channel_layout
3472           The channel layout of the output stream.
3473
3474       If no mapping is present, the filter will implicitly map input channels
3475       to output channels, preserving indices.
3476
3477       Examples
3478
3479       •   For example, assuming a 5.1+downmix input MOV file,
3480
3481                   ffmpeg -i in.mov -filter 'channelmap=map=DL-FL|DR-FR' out.wav
3482
3483           will create an output WAV file tagged as stereo from the downmix
3484           channels of the input.
3485
3486       •   To fix a 5.1 WAV improperly encoded in AAC's native channel order
3487
3488                   ffmpeg -i in.wav -filter 'channelmap=1|2|0|5|3|4:5.1' out.wav
3489
3490   channelsplit
3491       Split each channel from an input audio stream into a separate output
3492       stream.
3493
3494       It accepts the following parameters:
3495
3496       channel_layout
3497           The channel layout of the input stream. The default is "stereo".
3498
3499       channels
3500           A channel layout describing the channels to be extracted as
3501           separate output streams or "all" to extract each input channel as a
3502           separate stream. The default is "all".
3503
3504           Choosing channels not present in channel layout in the input will
3505           result in an error.
3506
3507       Examples
3508
3509       •   For example, assuming a stereo input MP3 file,
3510
3511                   ffmpeg -i in.mp3 -filter_complex channelsplit out.mkv
3512
3513           will create an output Matroska file with two audio streams, one
3514           containing only the left channel and the other the right channel.
3515
3516       •   Split a 5.1 WAV file into per-channel files:
3517
3518                   ffmpeg -i in.wav -filter_complex
3519                   'channelsplit=channel_layout=5.1[FL][FR][FC][LFE][SL][SR]'
3520                   -map '[FL]' front_left.wav -map '[FR]' front_right.wav -map '[FC]'
3521                   front_center.wav -map '[LFE]' lfe.wav -map '[SL]' side_left.wav -map '[SR]'
3522                   side_right.wav
3523
3524       •   Extract only LFE from a 5.1 WAV file:
3525
3526                   ffmpeg -i in.wav -filter_complex 'channelsplit=channel_layout=5.1:channels=LFE[LFE]'
3527                   -map '[LFE]' lfe.wav
3528
3529   chorus
3530       Add a chorus effect to the audio.
3531
3532       Can make a single vocal sound like a chorus, but can also be applied to
3533       instrumentation.
3534
3535       Chorus resembles an echo effect with a short delay, but whereas with
3536       echo the delay is constant, with chorus, it is varied using using
3537       sinusoidal or triangular modulation.  The modulation depth defines the
3538       range the modulated delay is played before or after the delay. Hence
3539       the delayed sound will sound slower or faster, that is the delayed
3540       sound tuned around the original one, like in a chorus where some vocals
3541       are slightly off key.
3542
3543       It accepts the following parameters:
3544
3545       in_gain
3546           Set input gain. Default is 0.4.
3547
3548       out_gain
3549           Set output gain. Default is 0.4.
3550
3551       delays
3552           Set delays. A typical delay is around 40ms to 60ms.
3553
3554       decays
3555           Set decays.
3556
3557       speeds
3558           Set speeds.
3559
3560       depths
3561           Set depths.
3562
3563       Examples
3564
3565       •   A single delay:
3566
3567                   chorus=0.7:0.9:55:0.4:0.25:2
3568
3569       •   Two delays:
3570
3571                   chorus=0.6:0.9:50|60:0.4|0.32:0.25|0.4:2|1.3
3572
3573       •   Fuller sounding chorus with three delays:
3574
3575                   chorus=0.5:0.9:50|60|40:0.4|0.32|0.3:0.25|0.4|0.3:2|2.3|1.3
3576
3577   compand
3578       Compress or expand the audio's dynamic range.
3579
3580       It accepts the following parameters:
3581
3582       attacks
3583       decays
3584           A list of times in seconds for each channel over which the
3585           instantaneous level of the input signal is averaged to determine
3586           its volume. attacks refers to increase of volume and decays refers
3587           to decrease of volume. For most situations, the attack time
3588           (response to the audio getting louder) should be shorter than the
3589           decay time, because the human ear is more sensitive to sudden loud
3590           audio than sudden soft audio. A typical value for attack is 0.3
3591           seconds and a typical value for decay is 0.8 seconds.  If specified
3592           number of attacks & decays is lower than number of channels, the
3593           last set attack/decay will be used for all remaining channels.
3594
3595       points
3596           A list of points for the transfer function, specified in dB
3597           relative to the maximum possible signal amplitude. Each key points
3598           list must be defined using the following syntax:
3599           "x0/y0|x1/y1|x2/y2|...." or "x0/y0 x1/y1 x2/y2 ...."
3600
3601           The input values must be in strictly increasing order but the
3602           transfer function does not have to be monotonically rising. The
3603           point "0/0" is assumed but may be overridden (by "0/out-dBn").
3604           Typical values for the transfer function are "-70/-70|-60/-20|1/0".
3605
3606       soft-knee
3607           Set the curve radius in dB for all joints. It defaults to 0.01.
3608
3609       gain
3610           Set the additional gain in dB to be applied at all points on the
3611           transfer function. This allows for easy adjustment of the overall
3612           gain.  It defaults to 0.
3613
3614       volume
3615           Set an initial volume, in dB, to be assumed for each channel when
3616           filtering starts. This permits the user to supply a nominal level
3617           initially, so that, for example, a very large gain is not applied
3618           to initial signal levels before the companding has begun to
3619           operate. A typical value for audio which is initially quiet is -90
3620           dB. It defaults to 0.
3621
3622       delay
3623           Set a delay, in seconds. The input audio is analyzed immediately,
3624           but audio is delayed before being fed to the volume adjuster.
3625           Specifying a delay approximately equal to the attack/decay times
3626           allows the filter to effectively operate in predictive rather than
3627           reactive mode. It defaults to 0.
3628
3629       Examples
3630
3631       •   Make music with both quiet and loud passages suitable for listening
3632           to in a noisy environment:
3633
3634                   compand=.3|.3:1|1:-90/-60|-60/-40|-40/-30|-20/-20:6:0:-90:0.2
3635
3636           Another example for audio with whisper and explosion parts:
3637
3638                   compand=0|0:1|1:-90/-900|-70/-70|-30/-9|0/-3:6:0:0:0
3639
3640       •   A noise gate for when the noise is at a lower level than the
3641           signal:
3642
3643                   compand=.1|.1:.2|.2:-900/-900|-50.1/-900|-50/-50:.01:0:-90:.1
3644
3645       •   Here is another noise gate, this time for when the noise is at a
3646           higher level than the signal (making it, in some ways, similar to
3647           squelch):
3648
3649                   compand=.1|.1:.1|.1:-45.1/-45.1|-45/-900|0/-900:.01:45:-90:.1
3650
3651       •   2:1 compression starting at -6dB:
3652
3653                   compand=points=-80/-80|-6/-6|0/-3.8|20/3.5
3654
3655       •   2:1 compression starting at -9dB:
3656
3657                   compand=points=-80/-80|-9/-9|0/-5.3|20/2.9
3658
3659       •   2:1 compression starting at -12dB:
3660
3661                   compand=points=-80/-80|-12/-12|0/-6.8|20/1.9
3662
3663       •   2:1 compression starting at -18dB:
3664
3665                   compand=points=-80/-80|-18/-18|0/-9.8|20/0.7
3666
3667       •   3:1 compression starting at -15dB:
3668
3669                   compand=points=-80/-80|-15/-15|0/-10.8|20/-5.2
3670
3671       •   Compressor/Gate:
3672
3673                   compand=points=-80/-105|-62/-80|-15.4/-15.4|0/-12|20/-7.6
3674
3675       •   Expander:
3676
3677                   compand=attacks=0:points=-80/-169|-54/-80|-49.5/-64.6|-41.1/-41.1|-25.8/-15|-10.8/-4.5|0/0|20/8.3
3678
3679       •   Hard limiter at -6dB:
3680
3681                   compand=attacks=0:points=-80/-80|-6/-6|20/-6
3682
3683       •   Hard limiter at -12dB:
3684
3685                   compand=attacks=0:points=-80/-80|-12/-12|20/-12
3686
3687       •   Hard noise gate at -35 dB:
3688
3689                   compand=attacks=0:points=-80/-115|-35.1/-80|-35/-35|20/20
3690
3691       •   Soft limiter:
3692
3693                   compand=attacks=0:points=-80/-80|-12.4/-12.4|-6/-8|0/-6.8|20/-2.8
3694
3695   compensationdelay
3696       Compensation Delay Line is a metric based delay to compensate differing
3697       positions of microphones or speakers.
3698
3699       For example, you have recorded guitar with two microphones placed in
3700       different locations. Because the front of sound wave has fixed speed in
3701       normal conditions, the phasing of microphones can vary and depends on
3702       their location and interposition. The best sound mix can be achieved
3703       when these microphones are in phase (synchronized). Note that a
3704       distance of ~30 cm between microphones makes one microphone capture the
3705       signal in antiphase to the other microphone. That makes the final mix
3706       sound moody.  This filter helps to solve phasing problems by adding
3707       different delays to each microphone track and make them synchronized.
3708
3709       The best result can be reached when you take one track as base and
3710       synchronize other tracks one by one with it.  Remember that
3711       synchronization/delay tolerance depends on sample rate, too.  Higher
3712       sample rates will give more tolerance.
3713
3714       The filter accepts the following parameters:
3715
3716       mm  Set millimeters distance. This is compensation distance for fine
3717           tuning.  Default is 0.
3718
3719       cm  Set cm distance. This is compensation distance for tightening
3720           distance setup.  Default is 0.
3721
3722       m   Set meters distance. This is compensation distance for hard
3723           distance setup.  Default is 0.
3724
3725       dry Set dry amount. Amount of unprocessed (dry) signal.  Default is 0.
3726
3727       wet Set wet amount. Amount of processed (wet) signal.  Default is 1.
3728
3729       temp
3730           Set temperature in degrees Celsius. This is the temperature of the
3731           environment.  Default is 20.
3732
3733       Commands
3734
3735       This filter supports the all above options as commands.
3736
3737   crossfeed
3738       Apply headphone crossfeed filter.
3739
3740       Crossfeed is the process of blending the left and right channels of
3741       stereo audio recording.  It is mainly used to reduce extreme stereo
3742       separation of low frequencies.
3743
3744       The intent is to produce more speaker like sound to the listener.
3745
3746       The filter accepts the following options:
3747
3748       strength
3749           Set strength of crossfeed. Default is 0.2. Allowed range is from 0
3750           to 1.  This sets gain of low shelf filter for side part of stereo
3751           image.  Default is -6dB. Max allowed is -30db when strength is set
3752           to 1.
3753
3754       range
3755           Set soundstage wideness. Default is 0.5. Allowed range is from 0 to
3756           1.  This sets cut off frequency of low shelf filter. Default is cut
3757           off near 1550 Hz. With range set to 1 cut off frequency is set to
3758           2100 Hz.
3759
3760       slope
3761           Set curve slope of low shelf filter. Default is 0.5.  Allowed range
3762           is from 0.01 to 1.
3763
3764       level_in
3765           Set input gain. Default is 0.9.
3766
3767       level_out
3768           Set output gain. Default is 1.
3769
3770       block_size
3771           Set block size used for reverse IIR processing. If this value is
3772           set to high enough value (higher than impulse response length
3773           truncated when reaches near zero values) filtering will become
3774           linear phase otherwise if not big enough it will just produce nasty
3775           artifacts.
3776
3777           Note that filter delay will be exactly this many samples when set
3778           to non-zero value.
3779
3780       Commands
3781
3782       This filter supports the all above options as commands.
3783
3784   crystalizer
3785       Simple algorithm for audio noise sharpening.
3786
3787       This filter linearly increases differences betweeen each audio sample.
3788
3789       The filter accepts the following options:
3790
3791       i   Sets the intensity of effect (default: 2.0). Must be in range
3792           between -10.0 to 0 (unchanged sound) to 10.0 (maximum effect).  To
3793           inverse filtering use negative value.
3794
3795       c   Enable clipping. By default is enabled.
3796
3797       Commands
3798
3799       This filter supports the all above options as commands.
3800
3801   dcshift
3802       Apply a DC shift to the audio.
3803
3804       This can be useful to remove a DC offset (caused perhaps by a hardware
3805       problem in the recording chain) from the audio. The effect of a DC
3806       offset is reduced headroom and hence volume. The astats filter can be
3807       used to determine if a signal has a DC offset.
3808
3809       shift
3810           Set the DC shift, allowed range is [-1, 1]. It indicates the amount
3811           to shift the audio.
3812
3813       limitergain
3814           Optional. It should have a value much less than 1 (e.g. 0.05 or
3815           0.02) and is used to prevent clipping.
3816
3817   deesser
3818       Apply de-essing to the audio samples.
3819
3820       i   Set intensity for triggering de-essing. Allowed range is from 0 to
3821           1.  Default is 0.
3822
3823       m   Set amount of ducking on treble part of sound. Allowed range is
3824           from 0 to 1.  Default is 0.5.
3825
3826       f   How much of original frequency content to keep when de-essing.
3827           Allowed range is from 0 to 1.  Default is 0.5.
3828
3829       s   Set the output mode.
3830
3831           It accepts the following values:
3832
3833           i   Pass input unchanged.
3834
3835           o   Pass ess filtered out.
3836
3837           e   Pass only ess.
3838
3839               Default value is o.
3840
3841   dialoguenhance
3842       Enhance dialogue in stereo audio.
3843
3844       This filter accepts stereo input and produce surround (3.0) channels
3845       output.  The newly produced front center channel have enhanced speech
3846       dialogue originally available in both stereo channels.  This filter
3847       outputs front left and front right channels same as available in stereo
3848       input.
3849
3850       The filter accepts the following options:
3851
3852       original
3853           Set the original center factor to keep in front center channel
3854           output.  Allowed range is from 0 to 1. Default value is 1.
3855
3856       enhance
3857           Set the dialogue enhance factor to put in front center channel
3858           output.  Allowed range is from 0 to 3. Default value is 1.
3859
3860       voice
3861           Set the voice detection factor.  Allowed range is from 2 to 32.
3862           Default value is 2.
3863
3864       Commands
3865
3866       This filter supports the all above options as commands.
3867
3868   drmeter
3869       Measure audio dynamic range.
3870
3871       DR values of 14 and higher is found in very dynamic material. DR of 8
3872       to 13 is found in transition material. And anything less that 8 have
3873       very poor dynamics and is very compressed.
3874
3875       The filter accepts the following options:
3876
3877       length
3878           Set window length in seconds used to split audio into segments of
3879           equal length.  Default is 3 seconds.
3880
3881   dynaudnorm
3882       Dynamic Audio Normalizer.
3883
3884       This filter applies a certain amount of gain to the input audio in
3885       order to bring its peak magnitude to a target level (e.g. 0 dBFS).
3886       However, in contrast to more "simple" normalization algorithms, the
3887       Dynamic Audio Normalizer *dynamically* re-adjusts the gain factor to
3888       the input audio.  This allows for applying extra gain to the "quiet"
3889       sections of the audio while avoiding distortions or clipping the "loud"
3890       sections. In other words: The Dynamic Audio Normalizer will "even out"
3891       the volume of quiet and loud sections, in the sense that the volume of
3892       each section is brought to the same target level. Note, however, that
3893       the Dynamic Audio Normalizer achieves this goal *without* applying
3894       "dynamic range compressing". It will retain 100% of the dynamic range
3895       *within* each section of the audio file.
3896
3897       framelen, f
3898           Set the frame length in milliseconds. In range from 10 to 8000
3899           milliseconds.  Default is 500 milliseconds.  The Dynamic Audio
3900           Normalizer processes the input audio in small chunks, referred to
3901           as frames. This is required, because a peak magnitude has no
3902           meaning for just a single sample value. Instead, we need to
3903           determine the peak magnitude for a contiguous sequence of sample
3904           values. While a "standard" normalizer would simply use the peak
3905           magnitude of the complete file, the Dynamic Audio Normalizer
3906           determines the peak magnitude individually for each frame. The
3907           length of a frame is specified in milliseconds. By default, the
3908           Dynamic Audio Normalizer uses a frame length of 500 milliseconds,
3909           which has been found to give good results with most files.  Note
3910           that the exact frame length, in number of samples, will be
3911           determined automatically, based on the sampling rate of the
3912           individual input audio file.
3913
3914       gausssize, g
3915           Set the Gaussian filter window size. In range from 3 to 301, must
3916           be odd number. Default is 31.  Probably the most important
3917           parameter of the Dynamic Audio Normalizer is the "window size" of
3918           the Gaussian smoothing filter. The filter's window size is
3919           specified in frames, centered around the current frame. For the
3920           sake of simplicity, this must be an odd number. Consequently, the
3921           default value of 31 takes into account the current frame, as well
3922           as the 15 preceding frames and the 15 subsequent frames. Using a
3923           larger window results in a stronger smoothing effect and thus in
3924           less gain variation, i.e. slower gain adaptation. Conversely, using
3925           a smaller window results in a weaker smoothing effect and thus in
3926           more gain variation, i.e. faster gain adaptation.  In other words,
3927           the more you increase this value, the more the Dynamic Audio
3928           Normalizer will behave like a "traditional" normalization filter.
3929           On the contrary, the more you decrease this value, the more the
3930           Dynamic Audio Normalizer will behave like a dynamic range
3931           compressor.
3932
3933       peak, p
3934           Set the target peak value. This specifies the highest permissible
3935           magnitude level for the normalized audio input. This filter will
3936           try to approach the target peak magnitude as closely as possible,
3937           but at the same time it also makes sure that the normalized signal
3938           will never exceed the peak magnitude.  A frame's maximum local gain
3939           factor is imposed directly by the target peak magnitude. The
3940           default value is 0.95 and thus leaves a headroom of 5%*.  It is not
3941           recommended to go above this value.
3942
3943       maxgain, m
3944           Set the maximum gain factor. In range from 1.0 to 100.0. Default is
3945           10.0.  The Dynamic Audio Normalizer determines the maximum possible
3946           (local) gain factor for each input frame, i.e. the maximum gain
3947           factor that does not result in clipping or distortion. The maximum
3948           gain factor is determined by the frame's highest magnitude sample.
3949           However, the Dynamic Audio Normalizer additionally bounds the
3950           frame's maximum gain factor by a predetermined (global) maximum
3951           gain factor. This is done in order to avoid excessive gain factors
3952           in "silent" or almost silent frames. By default, the maximum gain
3953           factor is 10.0, For most inputs the default value should be
3954           sufficient and it usually is not recommended to increase this
3955           value. Though, for input with an extremely low overall volume
3956           level, it may be necessary to allow even higher gain factors. Note,
3957           however, that the Dynamic Audio Normalizer does not simply apply a
3958           "hard" threshold (i.e. cut off values above the threshold).
3959           Instead, a "sigmoid" threshold function will be applied. This way,
3960           the gain factors will smoothly approach the threshold value, but
3961           never exceed that value.
3962
3963       targetrms, r
3964           Set the target RMS. In range from 0.0 to 1.0. Default is 0.0 -
3965           disabled.  By default, the Dynamic Audio Normalizer performs "peak"
3966           normalization.  This means that the maximum local gain factor for
3967           each frame is defined (only) by the frame's highest magnitude
3968           sample. This way, the samples can be amplified as much as possible
3969           without exceeding the maximum signal level, i.e. without clipping.
3970           Optionally, however, the Dynamic Audio Normalizer can also take
3971           into account the frame's root mean square, abbreviated RMS. In
3972           electrical engineering, the RMS is commonly used to determine the
3973           power of a time-varying signal. It is therefore considered that the
3974           RMS is a better approximation of the "perceived loudness" than just
3975           looking at the signal's peak magnitude. Consequently, by adjusting
3976           all frames to a constant RMS value, a uniform "perceived loudness"
3977           can be established. If a target RMS value has been specified, a
3978           frame's local gain factor is defined as the factor that would
3979           result in exactly that RMS value.  Note, however, that the maximum
3980           local gain factor is still restricted by the frame's highest
3981           magnitude sample, in order to prevent clipping.
3982
3983       coupling, n
3984           Enable channels coupling. By default is enabled.  By default, the
3985           Dynamic Audio Normalizer will amplify all channels by the same
3986           amount. This means the same gain factor will be applied to all
3987           channels, i.e.  the maximum possible gain factor is determined by
3988           the "loudest" channel.  However, in some recordings, it may happen
3989           that the volume of the different channels is uneven, e.g. one
3990           channel may be "quieter" than the other one(s).  In this case, this
3991           option can be used to disable the channel coupling. This way, the
3992           gain factor will be determined independently for each channel,
3993           depending only on the individual channel's highest magnitude
3994           sample. This allows for harmonizing the volume of the different
3995           channels.
3996
3997       correctdc, c
3998           Enable DC bias correction. By default is disabled.  An audio signal
3999           (in the time domain) is a sequence of sample values.  In the
4000           Dynamic Audio Normalizer these sample values are represented in the
4001           -1.0 to 1.0 range, regardless of the original input format.
4002           Normally, the audio signal, or "waveform", should be centered
4003           around the zero point.  That means if we calculate the mean value
4004           of all samples in a file, or in a single frame, then the result
4005           should be 0.0 or at least very close to that value. If, however,
4006           there is a significant deviation of the mean value from 0.0, in
4007           either positive or negative direction, this is referred to as a DC
4008           bias or DC offset. Since a DC bias is clearly undesirable, the
4009           Dynamic Audio Normalizer provides optional DC bias correction.
4010           With DC bias correction enabled, the Dynamic Audio Normalizer will
4011           determine the mean value, or "DC correction" offset, of each input
4012           frame and subtract that value from all of the frame's sample values
4013           which ensures those samples are centered around 0.0 again. Also, in
4014           order to avoid "gaps" at the frame boundaries, the DC correction
4015           offset values will be interpolated smoothly between neighbouring
4016           frames.
4017
4018       altboundary, b
4019           Enable alternative boundary mode. By default is disabled.  The
4020           Dynamic Audio Normalizer takes into account a certain neighbourhood
4021           around each frame. This includes the preceding frames as well as
4022           the subsequent frames. However, for the "boundary" frames, located
4023           at the very beginning and at the very end of the audio file, not
4024           all neighbouring frames are available. In particular, for the first
4025           few frames in the audio file, the preceding frames are not known.
4026           And, similarly, for the last few frames in the audio file, the
4027           subsequent frames are not known. Thus, the question arises which
4028           gain factors should be assumed for the missing frames in the
4029           "boundary" region. The Dynamic Audio Normalizer implements two
4030           modes to deal with this situation. The default boundary mode
4031           assumes a gain factor of exactly 1.0 for the missing frames,
4032           resulting in a smooth "fade in" and "fade out" at the beginning and
4033           at the end of the input, respectively.
4034
4035       compress, s
4036           Set the compress factor. In range from 0.0 to 30.0. Default is 0.0.
4037           By default, the Dynamic Audio Normalizer does not apply
4038           "traditional" compression. This means that signal peaks will not be
4039           pruned and thus the full dynamic range will be retained within each
4040           local neighbourhood. However, in some cases it may be desirable to
4041           combine the Dynamic Audio Normalizer's normalization algorithm with
4042           a more "traditional" compression.  For this purpose, the Dynamic
4043           Audio Normalizer provides an optional compression (thresholding)
4044           function. If (and only if) the compression feature is enabled, all
4045           input frames will be processed by a soft knee thresholding function
4046           prior to the actual normalization process. Put simply, the
4047           thresholding function is going to prune all samples whose magnitude
4048           exceeds a certain threshold value.  However, the Dynamic Audio
4049           Normalizer does not simply apply a fixed threshold value. Instead,
4050           the threshold value will be adjusted for each individual frame.  In
4051           general, smaller parameters result in stronger compression, and
4052           vice versa.  Values below 3.0 are not recommended, because audible
4053           distortion may appear.
4054
4055       threshold, t
4056           Set the target threshold value. This specifies the lowest
4057           permissible magnitude level for the audio input which will be
4058           normalized.  If input frame volume is above this value frame will
4059           be normalized.  Otherwise frame may not be normalized at all. The
4060           default value is set to 0, which means all input frames will be
4061           normalized.  This option is mostly useful if digital noise is not
4062           wanted to be amplified.
4063
4064       channels, h
4065           Specify which channels to filter, by default all available channels
4066           are filtered.
4067
4068       overlap, o
4069           Specify overlap for frames. If set to 0 (default) no frame
4070           overlapping is done.  Using >0 and <1 values will make less
4071           conservative gain adjustments, like when framelen option is set to
4072           smaller value, if framelen option value is compensated for non-zero
4073           overlap then gain adjustments will be smoother across time compared
4074           to zero overlap case.
4075
4076       Commands
4077
4078       This filter supports the all above options as commands.
4079
4080   earwax
4081       Make audio easier to listen to on headphones.
4082
4083       This filter adds `cues' to 44.1kHz stereo (i.e. audio CD format) audio
4084       so that when listened to on headphones the stereo image is moved from
4085       inside your head (standard for headphones) to outside and in front of
4086       the listener (standard for speakers).
4087
4088       Ported from SoX.
4089
4090   equalizer
4091       Apply a two-pole peaking equalisation (EQ) filter. With this filter,
4092       the signal-level at and around a selected frequency can be increased or
4093       decreased, whilst (unlike bandpass and bandreject filters) that at all
4094       other frequencies is unchanged.
4095
4096       In order to produce complex equalisation curves, this filter can be
4097       given several times, each with a different central frequency.
4098
4099       The filter accepts the following options:
4100
4101       frequency, f
4102           Set the filter's central frequency in Hz.
4103
4104       width_type, t
4105           Set method to specify band-width of filter.
4106
4107           h   Hz
4108
4109           q   Q-Factor
4110
4111           o   octave
4112
4113           s   slope
4114
4115           k   kHz
4116
4117       width, w
4118           Specify the band-width of a filter in width_type units.
4119
4120       gain, g
4121           Set the required gain or attenuation in dB.  Beware of clipping
4122           when using a positive gain.
4123
4124       mix, m
4125           How much to use filtered signal in output. Default is 1.  Range is
4126           between 0 and 1.
4127
4128       channels, c
4129           Specify which channels to filter, by default all available are
4130           filtered.
4131
4132       normalize, n
4133           Normalize biquad coefficients, by default is disabled.  Enabling it
4134           will normalize magnitude response at DC to 0dB.
4135
4136       transform, a
4137           Set transform type of IIR filter.
4138
4139           di
4140           dii
4141           tdi
4142           tdii
4143           latt
4144           svf
4145           zdf
4146       precision, r
4147           Set precison of filtering.
4148
4149           auto
4150               Pick automatic sample format depending on surround filters.
4151
4152           s16 Always use signed 16-bit.
4153
4154           s32 Always use signed 32-bit.
4155
4156           f32 Always use float 32-bit.
4157
4158           f64 Always use float 64-bit.
4159
4160       block_size, b
4161           Set block size used for reverse IIR processing. If this value is
4162           set to high enough value (higher than impulse response length
4163           truncated when reaches near zero values) filtering will become
4164           linear phase otherwise if not big enough it will just produce nasty
4165           artifacts.
4166
4167           Note that filter delay will be exactly this many samples when set
4168           to non-zero value.
4169
4170       Examples
4171
4172       •   Attenuate 10 dB at 1000 Hz, with a bandwidth of 200 Hz:
4173
4174                   equalizer=f=1000:t=h:width=200:g=-10
4175
4176       •   Apply 2 dB gain at 1000 Hz with Q 1 and attenuate 5 dB at 100 Hz
4177           with Q 2:
4178
4179                   equalizer=f=1000:t=q:w=1:g=2,equalizer=f=100:t=q:w=2:g=-5
4180
4181       Commands
4182
4183       This filter supports the following commands:
4184
4185       frequency, f
4186           Change equalizer frequency.  Syntax for the command is :
4187           "frequency"
4188
4189       width_type, t
4190           Change equalizer width_type.  Syntax for the command is :
4191           "width_type"
4192
4193       width, w
4194           Change equalizer width.  Syntax for the command is : "width"
4195
4196       gain, g
4197           Change equalizer gain.  Syntax for the command is : "gain"
4198
4199       mix, m
4200           Change equalizer mix.  Syntax for the command is : "mix"
4201
4202   extrastereo
4203       Linearly increases the difference between left and right channels which
4204       adds some sort of "live" effect to playback.
4205
4206       The filter accepts the following options:
4207
4208       m   Sets the difference coefficient (default: 2.5). 0.0 means mono
4209           sound (average of both channels), with 1.0 sound will be unchanged,
4210           with -1.0 left and right channels will be swapped.
4211
4212       c   Enable clipping. By default is enabled.
4213
4214       Commands
4215
4216       This filter supports the all above options as commands.
4217
4218   firequalizer
4219       Apply FIR Equalization using arbitrary frequency response.
4220
4221       The filter accepts the following option:
4222
4223       gain
4224           Set gain curve equation (in dB). The expression can contain
4225           variables:
4226
4227           f   the evaluated frequency
4228
4229           sr  sample rate
4230
4231           ch  channel number, set to 0 when multichannels evaluation is
4232               disabled
4233
4234           chid
4235               channel id, see libavutil/channel_layout.h, set to the first
4236               channel id when multichannels evaluation is disabled
4237
4238           chs number of channels
4239
4240           chlayout
4241               channel_layout, see libavutil/channel_layout.h
4242
4243           and functions:
4244
4245           gain_interpolate(f)
4246               interpolate gain on frequency f based on gain_entry
4247
4248           cubic_interpolate(f)
4249               same as gain_interpolate, but smoother
4250
4251           This option is also available as command. Default is
4252           gain_interpolate(f).
4253
4254       gain_entry
4255           Set gain entry for gain_interpolate function. The expression can
4256           contain functions:
4257
4258           entry(f, g)
4259               store gain entry at frequency f with value g
4260
4261           This option is also available as command.
4262
4263       delay
4264           Set filter delay in seconds. Higher value means more accurate.
4265           Default is 0.01.
4266
4267       accuracy
4268           Set filter accuracy in Hz. Lower value means more accurate.
4269           Default is 5.
4270
4271       wfunc
4272           Set window function. Acceptable values are:
4273
4274           rectangular
4275               rectangular window, useful when gain curve is already smooth
4276
4277           hann
4278               hann window (default)
4279
4280           hamming
4281               hamming window
4282
4283           blackman
4284               blackman window
4285
4286           nuttall3
4287               3-terms continuous 1st derivative nuttall window
4288
4289           mnuttall3
4290               minimum 3-terms discontinuous nuttall window
4291
4292           nuttall
4293               4-terms continuous 1st derivative nuttall window
4294
4295           bnuttall
4296               minimum 4-terms discontinuous nuttall (blackman-nuttall) window
4297
4298           bharris
4299               blackman-harris window
4300
4301           tukey
4302               tukey window
4303
4304       fixed
4305           If enabled, use fixed number of audio samples. This improves speed
4306           when filtering with large delay. Default is disabled.
4307
4308       multi
4309           Enable multichannels evaluation on gain. Default is disabled.
4310
4311       zero_phase
4312           Enable zero phase mode by subtracting timestamp to compensate
4313           delay.  Default is disabled.
4314
4315       scale
4316           Set scale used by gain. Acceptable values are:
4317
4318           linlin
4319               linear frequency, linear gain
4320
4321           linlog
4322               linear frequency, logarithmic (in dB) gain (default)
4323
4324           loglin
4325               logarithmic (in octave scale where 20 Hz is 0) frequency,
4326               linear gain
4327
4328           loglog
4329               logarithmic frequency, logarithmic gain
4330
4331       dumpfile
4332           Set file for dumping, suitable for gnuplot.
4333
4334       dumpscale
4335           Set scale for dumpfile. Acceptable values are same with scale
4336           option.  Default is linlog.
4337
4338       fft2
4339           Enable 2-channel convolution using complex FFT. This improves speed
4340           significantly.  Default is disabled.
4341
4342       min_phase
4343           Enable minimum phase impulse response. Default is disabled.
4344
4345       Examples
4346
4347       •   lowpass at 1000 Hz:
4348
4349                   firequalizer=gain='if(lt(f,1000), 0, -INF)'
4350
4351       •   lowpass at 1000 Hz with gain_entry:
4352
4353                   firequalizer=gain_entry='entry(1000,0); entry(1001, -INF)'
4354
4355       •   custom equalization:
4356
4357                   firequalizer=gain_entry='entry(100,0); entry(400, -4); entry(1000, -6); entry(2000, 0)'
4358
4359       •   higher delay with zero phase to compensate delay:
4360
4361                   firequalizer=delay=0.1:fixed=on:zero_phase=on
4362
4363       •   lowpass on left channel, highpass on right channel:
4364
4365                   firequalizer=gain='if(eq(chid,1), gain_interpolate(f), if(eq(chid,2), gain_interpolate(1e6+f), 0))'
4366                   :gain_entry='entry(1000, 0); entry(1001,-INF); entry(1e6+1000,0)':multi=on
4367
4368   flanger
4369       Apply a flanging effect to the audio.
4370
4371       The filter accepts the following options:
4372
4373       delay
4374           Set base delay in milliseconds. Range from 0 to 30. Default value
4375           is 0.
4376
4377       depth
4378           Set added sweep delay in milliseconds. Range from 0 to 10. Default
4379           value is 2.
4380
4381       regen
4382           Set percentage regeneration (delayed signal feedback). Range from
4383           -95 to 95.  Default value is 0.
4384
4385       width
4386           Set percentage of delayed signal mixed with original. Range from 0
4387           to 100.  Default value is 71.
4388
4389       speed
4390           Set sweeps per second (Hz). Range from 0.1 to 10. Default value is
4391           0.5.
4392
4393       shape
4394           Set swept wave shape, can be triangular or sinusoidal.  Default
4395           value is sinusoidal.
4396
4397       phase
4398           Set swept wave percentage-shift for multi channel. Range from 0 to
4399           100.  Default value is 25.
4400
4401       interp
4402           Set delay-line interpolation, linear or quadratic.  Default is
4403           linear.
4404
4405   haas
4406       Apply Haas effect to audio.
4407
4408       Note that this makes most sense to apply on mono signals.  With this
4409       filter applied to mono signals it give some directionality and
4410       stretches its stereo image.
4411
4412       The filter accepts the following options:
4413
4414       level_in
4415           Set input level. By default is 1, or 0dB
4416
4417       level_out
4418           Set output level. By default is 1, or 0dB.
4419
4420       side_gain
4421           Set gain applied to side part of signal. By default is 1.
4422
4423       middle_source
4424           Set kind of middle source. Can be one of the following:
4425
4426           left
4427               Pick left channel.
4428
4429           right
4430               Pick right channel.
4431
4432           mid Pick middle part signal of stereo image.
4433
4434           side
4435               Pick side part signal of stereo image.
4436
4437       middle_phase
4438           Change middle phase. By default is disabled.
4439
4440       left_delay
4441           Set left channel delay. By default is 2.05 milliseconds.
4442
4443       left_balance
4444           Set left channel balance. By default is -1.
4445
4446       left_gain
4447           Set left channel gain. By default is 1.
4448
4449       left_phase
4450           Change left phase. By default is disabled.
4451
4452       right_delay
4453           Set right channel delay. By defaults is 2.12 milliseconds.
4454
4455       right_balance
4456           Set right channel balance. By default is 1.
4457
4458       right_gain
4459           Set right channel gain. By default is 1.
4460
4461       right_phase
4462           Change right phase. By default is enabled.
4463
4464   hdcd
4465       Decodes High Definition Compatible Digital (HDCD) data. A 16-bit PCM
4466       stream with embedded HDCD codes is expanded into a 20-bit PCM stream.
4467
4468       The filter supports the Peak Extend and Low-level Gain Adjustment
4469       features of HDCD, and detects the Transient Filter flag.
4470
4471               ffmpeg -i HDCD16.flac -af hdcd OUT24.flac
4472
4473       When using the filter with wav, note the default encoding for wav is
4474       16-bit, so the resulting 20-bit stream will be truncated back to
4475       16-bit. Use something like -acodec pcm_s24le after the filter to get
4476       24-bit PCM output.
4477
4478               ffmpeg -i HDCD16.wav -af hdcd OUT16.wav
4479               ffmpeg -i HDCD16.wav -af hdcd -c:a pcm_s24le OUT24.wav
4480
4481       The filter accepts the following options:
4482
4483       disable_autoconvert
4484           Disable any automatic format conversion or resampling in the filter
4485           graph.
4486
4487       process_stereo
4488           Process the stereo channels together. If target_gain does not match
4489           between channels, consider it invalid and use the last valid
4490           target_gain.
4491
4492       cdt_ms
4493           Set the code detect timer period in ms.
4494
4495       force_pe
4496           Always extend peaks above -3dBFS even if PE isn't signaled.
4497
4498       analyze_mode
4499           Replace audio with a solid tone and adjust the amplitude to signal
4500           some specific aspect of the decoding process. The output file can
4501           be loaded in an audio editor alongside the original to aid
4502           analysis.
4503
4504           "analyze_mode=pe:force_pe=true" can be used to see all samples
4505           above the PE level.
4506
4507           Modes are:
4508
4509           0, off
4510               Disabled
4511
4512           1, lle
4513               Gain adjustment level at each sample
4514
4515           2, pe
4516               Samples where peak extend occurs
4517
4518           3, cdt
4519               Samples where the code detect timer is active
4520
4521           4, tgm
4522               Samples where the target gain does not match between channels
4523
4524   headphone
4525       Apply head-related transfer functions (HRTFs) to create virtual
4526       loudspeakers around the user for binaural listening via headphones.
4527       The HRIRs are provided via additional streams, for each channel one
4528       stereo input stream is needed.
4529
4530       The filter accepts the following options:
4531
4532       map Set mapping of input streams for convolution.  The argument is a
4533           '|'-separated list of channel names in order as they are given as
4534           additional stream inputs for filter.  This also specify number of
4535           input streams. Number of input streams must be not less than number
4536           of channels in first stream plus one.
4537
4538       gain
4539           Set gain applied to audio. Value is in dB. Default is 0.
4540
4541       type
4542           Set processing type. Can be time or freq. time is processing audio
4543           in time domain which is slow.  freq is processing audio in
4544           frequency domain which is fast.  Default is freq.
4545
4546       lfe Set custom gain for LFE channels. Value is in dB. Default is 0.
4547
4548       size
4549           Set size of frame in number of samples which will be processed at
4550           once.  Default value is 1024. Allowed range is from 1024 to 96000.
4551
4552       hrir
4553           Set format of hrir stream.  Default value is stereo. Alternative
4554           value is multich.  If value is set to stereo, number of additional
4555           streams should be greater or equal to number of input channels in
4556           first input stream.  Also each additional stream should have stereo
4557           number of channels.  If value is set to multich, number of
4558           additional streams should be exactly one. Also number of input
4559           channels of additional stream should be equal or greater than twice
4560           number of channels of first input stream.
4561
4562       Examples
4563
4564       •   Full example using wav files as coefficients with amovie filters
4565           for 7.1 downmix, each amovie filter use stereo file with IR
4566           coefficients as input.  The files give coefficients for each
4567           position of virtual loudspeaker:
4568
4569                   ffmpeg -i input.wav
4570                   -filter_complex "amovie=azi_270_ele_0_DFC.wav[sr];amovie=azi_90_ele_0_DFC.wav[sl];amovie=azi_225_ele_0_DFC.wav[br];amovie=azi_135_ele_0_DFC.wav[bl];amovie=azi_0_ele_0_DFC.wav,asplit[fc][lfe];amovie=azi_35_ele_0_DFC.wav[fl];amovie=azi_325_ele_0_DFC.wav[fr];[0:a][fl][fr][fc][lfe][bl][br][sl][sr]headphone=FL|FR|FC|LFE|BL|BR|SL|SR"
4571                   output.wav
4572
4573       •   Full example using wav files as coefficients with amovie filters
4574           for 7.1 downmix, but now in multich hrir format.
4575
4576                   ffmpeg -i input.wav -filter_complex "amovie=minp.wav[hrirs];[0:a][hrirs]headphone=map=FL|FR|FC|LFE|BL|BR|SL|SR:hrir=multich"
4577                   output.wav
4578
4579   highpass
4580       Apply a high-pass filter with 3dB point frequency.  The filter can be
4581       either single-pole, or double-pole (the default).  The filter roll off
4582       at 6dB per pole per octave (20dB per pole per decade).
4583
4584       The filter accepts the following options:
4585
4586       frequency, f
4587           Set frequency in Hz. Default is 3000.
4588
4589       poles, p
4590           Set number of poles. Default is 2.
4591
4592       width_type, t
4593           Set method to specify band-width of filter.
4594
4595           h   Hz
4596
4597           q   Q-Factor
4598
4599           o   octave
4600
4601           s   slope
4602
4603           k   kHz
4604
4605       width, w
4606           Specify the band-width of a filter in width_type units.  Applies
4607           only to double-pole filter.  The default is 0.707q and gives a
4608           Butterworth response.
4609
4610       mix, m
4611           How much to use filtered signal in output. Default is 1.  Range is
4612           between 0 and 1.
4613
4614       channels, c
4615           Specify which channels to filter, by default all available are
4616           filtered.
4617
4618       normalize, n
4619           Normalize biquad coefficients, by default is disabled.  Enabling it
4620           will normalize magnitude response at DC to 0dB.
4621
4622       transform, a
4623           Set transform type of IIR filter.
4624
4625           di
4626           dii
4627           tdi
4628           tdii
4629           latt
4630           svf
4631           zdf
4632       precision, r
4633           Set precison of filtering.
4634
4635           auto
4636               Pick automatic sample format depending on surround filters.
4637
4638           s16 Always use signed 16-bit.
4639
4640           s32 Always use signed 32-bit.
4641
4642           f32 Always use float 32-bit.
4643
4644           f64 Always use float 64-bit.
4645
4646       block_size, b
4647           Set block size used for reverse IIR processing. If this value is
4648           set to high enough value (higher than impulse response length
4649           truncated when reaches near zero values) filtering will become
4650           linear phase otherwise if not big enough it will just produce nasty
4651           artifacts.
4652
4653           Note that filter delay will be exactly this many samples when set
4654           to non-zero value.
4655
4656       Commands
4657
4658       This filter supports the following commands:
4659
4660       frequency, f
4661           Change highpass frequency.  Syntax for the command is : "frequency"
4662
4663       width_type, t
4664           Change highpass width_type.  Syntax for the command is :
4665           "width_type"
4666
4667       width, w
4668           Change highpass width.  Syntax for the command is : "width"
4669
4670       mix, m
4671           Change highpass mix.  Syntax for the command is : "mix"
4672
4673   join
4674       Join multiple input streams into one multi-channel stream.
4675
4676       It accepts the following parameters:
4677
4678       inputs
4679           The number of input streams. It defaults to 2.
4680
4681       channel_layout
4682           The desired output channel layout. It defaults to stereo.
4683
4684       map Map channels from inputs to output. The argument is a '|'-separated
4685           list of mappings, each in the "input_idx.in_channel-out_channel"
4686           form. input_idx is the 0-based index of the input stream.
4687           in_channel can be either the name of the input channel (e.g. FL for
4688           front left) or its index in the specified input stream. out_channel
4689           is the name of the output channel.
4690
4691       The filter will attempt to guess the mappings when they are not
4692       specified explicitly. It does so by first trying to find an unused
4693       matching input channel and if that fails it picks the first unused
4694       input channel.
4695
4696       Join 3 inputs (with properly set channel layouts):
4697
4698               ffmpeg -i INPUT1 -i INPUT2 -i INPUT3 -filter_complex join=inputs=3 OUTPUT
4699
4700       Build a 5.1 output from 6 single-channel streams:
4701
4702               ffmpeg -i fl -i fr -i fc -i sl -i sr -i lfe -filter_complex
4703               'join=inputs=6:channel_layout=5.1:map=0.0-FL|1.0-FR|2.0-FC|3.0-SL|4.0-SR|5.0-LFE'
4704               out
4705
4706   ladspa
4707       Load a LADSPA (Linux Audio Developer's Simple Plugin API) plugin.
4708
4709       To enable compilation of this filter you need to configure FFmpeg with
4710       "--enable-ladspa".
4711
4712       file, f
4713           Specifies the name of LADSPA plugin library to load. If the
4714           environment variable LADSPA_PATH is defined, the LADSPA plugin is
4715           searched in each one of the directories specified by the colon
4716           separated list in LADSPA_PATH, otherwise in the standard LADSPA
4717           paths, which are in this order: HOME/.ladspa/lib/,
4718           /usr/local/lib/ladspa/, /usr/lib/ladspa/.
4719
4720       plugin, p
4721           Specifies the plugin within the library. Some libraries contain
4722           only one plugin, but others contain many of them. If this is not
4723           set filter will list all available plugins within the specified
4724           library.
4725
4726       controls, c
4727           Set the '|' separated list of controls which are zero or more
4728           floating point values that determine the behavior of the loaded
4729           plugin (for example delay, threshold or gain).  Controls need to be
4730           defined using the following syntax:
4731           c0=value0|c1=value1|c2=value2|..., where valuei is the value set on
4732           the i-th control.  Alternatively they can be also defined using the
4733           following syntax: value0|value1|value2|..., where valuei is the
4734           value set on the i-th control.  If controls is set to "help", all
4735           available controls and their valid ranges are printed.
4736
4737       sample_rate, s
4738           Specify the sample rate, default to 44100. Only used if plugin have
4739           zero inputs.
4740
4741       nb_samples, n
4742           Set the number of samples per channel per each output frame,
4743           default is 1024. Only used if plugin have zero inputs.
4744
4745       duration, d
4746           Set the minimum duration of the sourced audio. See the Time
4747           duration section in the ffmpeg-utils(1) manual for the accepted
4748           syntax.  Note that the resulting duration may be greater than the
4749           specified duration, as the generated audio is always cut at the end
4750           of a complete frame.  If not specified, or the expressed duration
4751           is negative, the audio is supposed to be generated forever.  Only
4752           used if plugin have zero inputs.
4753
4754       latency, l
4755           Enable latency compensation, by default is disabled.  Only used if
4756           plugin have inputs.
4757
4758       Examples
4759
4760       •   List all available plugins within amp (LADSPA example plugin)
4761           library:
4762
4763                   ladspa=file=amp
4764
4765       •   List all available controls and their valid ranges for "vcf_notch"
4766           plugin from "VCF" library:
4767
4768                   ladspa=f=vcf:p=vcf_notch:c=help
4769
4770       •   Simulate low quality audio equipment using "Computer Music Toolkit"
4771           (CMT) plugin library:
4772
4773                   ladspa=file=cmt:plugin=lofi:controls=c0=22|c1=12|c2=12
4774
4775       •   Add reverberation to the audio using TAP-plugins (Tom's Audio
4776           Processing plugins):
4777
4778                   ladspa=file=tap_reverb:tap_reverb
4779
4780       •   Generate white noise, with 0.2 amplitude:
4781
4782                   ladspa=file=cmt:noise_source_white:c=c0=.2
4783
4784       •   Generate 20 bpm clicks using plugin "C* Click - Metronome" from the
4785           "C* Audio Plugin Suite" (CAPS) library:
4786
4787                   ladspa=file=caps:Click:c=c1=20'
4788
4789       •   Apply "C* Eq10X2 - Stereo 10-band equaliser" effect:
4790
4791                   ladspa=caps:Eq10X2:c=c0=-48|c9=-24|c3=12|c4=2
4792
4793       •   Increase volume by 20dB using fast lookahead limiter from Steve
4794           Harris "SWH Plugins" collection:
4795
4796                   ladspa=fast_lookahead_limiter_1913:fastLookaheadLimiter:20|0|2
4797
4798       •   Attenuate low frequencies using Multiband EQ from Steve Harris "SWH
4799           Plugins" collection:
4800
4801                   ladspa=mbeq_1197:mbeq:-24|-24|-24|0|0|0|0|0|0|0|0|0|0|0|0
4802
4803       •   Reduce stereo image using "Narrower" from the "C* Audio Plugin
4804           Suite" (CAPS) library:
4805
4806                   ladspa=caps:Narrower
4807
4808       •   Another white noise, now using "C* Audio Plugin Suite" (CAPS)
4809           library:
4810
4811                   ladspa=caps:White:.2
4812
4813       •   Some fractal noise, using "C* Audio Plugin Suite" (CAPS) library:
4814
4815                   ladspa=caps:Fractal:c=c1=1
4816
4817       •   Dynamic volume normalization using "VLevel" plugin:
4818
4819                   ladspa=vlevel-ladspa:vlevel_mono
4820
4821       Commands
4822
4823       This filter supports the following commands:
4824
4825       cN  Modify the N-th control value.
4826
4827           If the specified value is not valid, it is ignored and prior one is
4828           kept.
4829
4830   loudnorm
4831       EBU R128 loudness normalization. Includes both dynamic and linear
4832       normalization modes.  Support for both single pass (livestreams, files)
4833       and double pass (files) modes.  This algorithm can target IL, LRA, and
4834       maximum true peak. In dynamic mode, to accurately detect true peaks,
4835       the audio stream will be upsampled to 192 kHz.  Use the "-ar" option or
4836       "aresample" filter to explicitly set an output sample rate.
4837
4838       The filter accepts the following options:
4839
4840       I, i
4841           Set integrated loudness target.  Range is -70.0 - -5.0. Default
4842           value is -24.0.
4843
4844       LRA, lra
4845           Set loudness range target.  Range is 1.0 - 50.0. Default value is
4846           7.0.
4847
4848       TP, tp
4849           Set maximum true peak.  Range is -9.0 - +0.0. Default value is
4850           -2.0.
4851
4852       measured_I, measured_i
4853           Measured IL of input file.  Range is -99.0 - +0.0.
4854
4855       measured_LRA, measured_lra
4856           Measured LRA of input file.  Range is  0.0 - 99.0.
4857
4858       measured_TP, measured_tp
4859           Measured true peak of input file.  Range is  -99.0 - +99.0.
4860
4861       measured_thresh
4862           Measured threshold of input file.  Range is -99.0 - +0.0.
4863
4864       offset
4865           Set offset gain. Gain is applied before the true-peak limiter.
4866           Range is  -99.0 - +99.0. Default is +0.0.
4867
4868       linear
4869           Normalize by linearly scaling the source audio.  "measured_I",
4870           "measured_LRA", "measured_TP", and "measured_thresh" must all be
4871           specified. Target LRA shouldn't be lower than source LRA and the
4872           change in integrated loudness shouldn't result in a true peak which
4873           exceeds the target TP. If any of these conditions aren't met,
4874           normalization mode will revert to dynamic.  Options are "true" or
4875           "false". Default is "true".
4876
4877       dual_mono
4878           Treat mono input files as "dual-mono". If a mono file is intended
4879           for playback on a stereo system, its EBU R128 measurement will be
4880           perceptually incorrect.  If set to "true", this option will
4881           compensate for this effect.  Multi-channel input files are not
4882           affected by this option.  Options are true or false. Default is
4883           false.
4884
4885       print_format
4886           Set print format for stats. Options are summary, json, or none.
4887           Default value is none.
4888
4889   lowpass
4890       Apply a low-pass filter with 3dB point frequency.  The filter can be
4891       either single-pole or double-pole (the default).  The filter roll off
4892       at 6dB per pole per octave (20dB per pole per decade).
4893
4894       The filter accepts the following options:
4895
4896       frequency, f
4897           Set frequency in Hz. Default is 500.
4898
4899       poles, p
4900           Set number of poles. Default is 2.
4901
4902       width_type, t
4903           Set method to specify band-width of filter.
4904
4905           h   Hz
4906
4907           q   Q-Factor
4908
4909           o   octave
4910
4911           s   slope
4912
4913           k   kHz
4914
4915       width, w
4916           Specify the band-width of a filter in width_type units.  Applies
4917           only to double-pole filter.  The default is 0.707q and gives a
4918           Butterworth response.
4919
4920       mix, m
4921           How much to use filtered signal in output. Default is 1.  Range is
4922           between 0 and 1.
4923
4924       channels, c
4925           Specify which channels to filter, by default all available are
4926           filtered.
4927
4928       normalize, n
4929           Normalize biquad coefficients, by default is disabled.  Enabling it
4930           will normalize magnitude response at DC to 0dB.
4931
4932       transform, a
4933           Set transform type of IIR filter.
4934
4935           di
4936           dii
4937           tdi
4938           tdii
4939           latt
4940           svf
4941           zdf
4942       precision, r
4943           Set precison of filtering.
4944
4945           auto
4946               Pick automatic sample format depending on surround filters.
4947
4948           s16 Always use signed 16-bit.
4949
4950           s32 Always use signed 32-bit.
4951
4952           f32 Always use float 32-bit.
4953
4954           f64 Always use float 64-bit.
4955
4956       block_size, b
4957           Set block size used for reverse IIR processing. If this value is
4958           set to high enough value (higher than impulse response length
4959           truncated when reaches near zero values) filtering will become
4960           linear phase otherwise if not big enough it will just produce nasty
4961           artifacts.
4962
4963           Note that filter delay will be exactly this many samples when set
4964           to non-zero value.
4965
4966       Examples
4967
4968       •   Lowpass only LFE channel, it LFE is not present it does nothing:
4969
4970                   lowpass=c=LFE
4971
4972       Commands
4973
4974       This filter supports the following commands:
4975
4976       frequency, f
4977           Change lowpass frequency.  Syntax for the command is : "frequency"
4978
4979       width_type, t
4980           Change lowpass width_type.  Syntax for the command is :
4981           "width_type"
4982
4983       width, w
4984           Change lowpass width.  Syntax for the command is : "width"
4985
4986       mix, m
4987           Change lowpass mix.  Syntax for the command is : "mix"
4988
4989   lv2
4990       Load a LV2 (LADSPA Version 2) plugin.
4991
4992       To enable compilation of this filter you need to configure FFmpeg with
4993       "--enable-lv2".
4994
4995       plugin, p
4996           Specifies the plugin URI. You may need to escape ':'.
4997
4998       controls, c
4999           Set the '|' separated list of controls which are zero or more
5000           floating point values that determine the behavior of the loaded
5001           plugin (for example delay, threshold or gain).  If controls is set
5002           to "help", all available controls and their valid ranges are
5003           printed.
5004
5005       sample_rate, s
5006           Specify the sample rate, default to 44100. Only used if plugin have
5007           zero inputs.
5008
5009       nb_samples, n
5010           Set the number of samples per channel per each output frame,
5011           default is 1024. Only used if plugin have zero inputs.
5012
5013       duration, d
5014           Set the minimum duration of the sourced audio. See the Time
5015           duration section in the ffmpeg-utils(1) manual for the accepted
5016           syntax.  Note that the resulting duration may be greater than the
5017           specified duration, as the generated audio is always cut at the end
5018           of a complete frame.  If not specified, or the expressed duration
5019           is negative, the audio is supposed to be generated forever.  Only
5020           used if plugin have zero inputs.
5021
5022       Examples
5023
5024       •   Apply bass enhancer plugin from Calf:
5025
5026                   lv2=p=http\\\\://calf.sourceforge.net/plugins/BassEnhancer:c=amount=2
5027
5028       •   Apply vinyl plugin from Calf:
5029
5030                   lv2=p=http\\\\://calf.sourceforge.net/plugins/Vinyl:c=drone=0.2|aging=0.5
5031
5032       •   Apply bit crusher plugin from ArtyFX:
5033
5034                   lv2=p=http\\\\://www.openavproductions.com/artyfx#bitta:c=crush=0.3
5035
5036       Commands
5037
5038       This filter supports all options that are exported by plugin as
5039       commands.
5040
5041   mcompand
5042       Multiband Compress or expand the audio's dynamic range.
5043
5044       The input audio is divided into bands using 4th order Linkwitz-Riley
5045       IIRs.  This is akin to the crossover of a loudspeaker, and results in
5046       flat frequency response when absent compander action.
5047
5048       It accepts the following parameters:
5049
5050       args
5051           This option syntax is: attack,decay,[attack,decay..] soft-knee
5052           points crossover_frequency [delay [initial_volume [gain]]] |
5053           attack,decay ...  For explanation of each item refer to compand
5054           filter documentation.
5055
5056   pan
5057       Mix channels with specific gain levels. The filter accepts the output
5058       channel layout followed by a set of channels definitions.
5059
5060       This filter is also designed to efficiently remap the channels of an
5061       audio stream.
5062
5063       The filter accepts parameters of the form: "l|outdef|outdef|..."
5064
5065       l   output channel layout or number of channels
5066
5067       outdef
5068           output channel specification, of the form:
5069           "out_name=[gain*]in_name[(+-)[gain*]in_name...]"
5070
5071       out_name
5072           output channel to define, either a channel name (FL, FR, etc.) or a
5073           channel number (c0, c1, etc.)
5074
5075       gain
5076           multiplicative coefficient for the channel, 1 leaving the volume
5077           unchanged
5078
5079       in_name
5080           input channel to use, see out_name for details; it is not possible
5081           to mix named and numbered input channels
5082
5083       If the `=' in a channel specification is replaced by `<', then the
5084       gains for that specification will be renormalized so that the total is
5085       1, thus avoiding clipping noise.
5086
5087       Mixing examples
5088
5089       For example, if you want to down-mix from stereo to mono, but with a
5090       bigger factor for the left channel:
5091
5092               pan=1c|c0=0.9*c0+0.1*c1
5093
5094       A customized down-mix to stereo that works automatically for 3-, 4-, 5-
5095       and 7-channels surround:
5096
5097               pan=stereo| FL < FL + 0.5*FC + 0.6*BL + 0.6*SL | FR < FR + 0.5*FC + 0.6*BR + 0.6*SR
5098
5099       Note that ffmpeg integrates a default down-mix (and up-mix) system that
5100       should be preferred (see "-ac" option) unless you have very specific
5101       needs.
5102
5103       Remapping examples
5104
5105       The channel remapping will be effective if, and only if:
5106
5107       *<gain coefficients are zeroes or ones,>
5108       *<only one input per channel output,>
5109
5110       If all these conditions are satisfied, the filter will notify the user
5111       ("Pure channel mapping detected"), and use an optimized and lossless
5112       method to do the remapping.
5113
5114       For example, if you have a 5.1 source and want a stereo audio stream by
5115       dropping the extra channels:
5116
5117               pan="stereo| c0=FL | c1=FR"
5118
5119       Given the same source, you can also switch front left and front right
5120       channels and keep the input channel layout:
5121
5122               pan="5.1| c0=c1 | c1=c0 | c2=c2 | c3=c3 | c4=c4 | c5=c5"
5123
5124       If the input is a stereo audio stream, you can mute the front left
5125       channel (and still keep the stereo channel layout) with:
5126
5127               pan="stereo|c1=c1"
5128
5129       Still with a stereo audio stream input, you can copy the right channel
5130       in both front left and right:
5131
5132               pan="stereo| c0=FR | c1=FR"
5133
5134   replaygain
5135       ReplayGain scanner filter. This filter takes an audio stream as an
5136       input and outputs it unchanged.  At end of filtering it displays
5137       "track_gain" and "track_peak".
5138
5139   resample
5140       Convert the audio sample format, sample rate and channel layout. It is
5141       not meant to be used directly.
5142
5143   rubberband
5144       Apply time-stretching and pitch-shifting with librubberband.
5145
5146       To enable compilation of this filter, you need to configure FFmpeg with
5147       "--enable-librubberband".
5148
5149       The filter accepts the following options:
5150
5151       tempo
5152           Set tempo scale factor.
5153
5154       pitch
5155           Set pitch scale factor.
5156
5157       transients
5158           Set transients detector.  Possible values are:
5159
5160           crisp
5161           mixed
5162           smooth
5163       detector
5164           Set detector.  Possible values are:
5165
5166           compound
5167           percussive
5168           soft
5169       phase
5170           Set phase.  Possible values are:
5171
5172           laminar
5173           independent
5174       window
5175           Set processing window size.  Possible values are:
5176
5177           standard
5178           short
5179           long
5180       smoothing
5181           Set smoothing.  Possible values are:
5182
5183           off
5184           on
5185       formant
5186           Enable formant preservation when shift pitching.  Possible values
5187           are:
5188
5189           shifted
5190           preserved
5191       pitchq
5192           Set pitch quality.  Possible values are:
5193
5194           quality
5195           speed
5196           consistency
5197       channels
5198           Set channels.  Possible values are:
5199
5200           apart
5201           together
5202
5203       Commands
5204
5205       This filter supports the following commands:
5206
5207       tempo
5208           Change filter tempo scale factor.  Syntax for the command is :
5209           "tempo"
5210
5211       pitch
5212           Change filter pitch scale factor.  Syntax for the command is :
5213           "pitch"
5214
5215   sidechaincompress
5216       This filter acts like normal compressor but has the ability to compress
5217       detected signal using second input signal.  It needs two input streams
5218       and returns one output stream.  First input stream will be processed
5219       depending on second stream signal.  The filtered signal then can be
5220       filtered with other filters in later stages of processing. See pan and
5221       amerge filter.
5222
5223       The filter accepts the following options:
5224
5225       level_in
5226           Set input gain. Default is 1. Range is between 0.015625 and 64.
5227
5228       mode
5229           Set mode of compressor operation. Can be "upward" or "downward".
5230           Default is "downward".
5231
5232       threshold
5233           If a signal of second stream raises above this level it will affect
5234           the gain reduction of first stream.  By default is 0.125. Range is
5235           between 0.00097563 and 1.
5236
5237       ratio
5238           Set a ratio about which the signal is reduced. 1:2 means that if
5239           the level raised 4dB above the threshold, it will be only 2dB above
5240           after the reduction.  Default is 2. Range is between 1 and 20.
5241
5242       attack
5243           Amount of milliseconds the signal has to rise above the threshold
5244           before gain reduction starts. Default is 20. Range is between 0.01
5245           and 2000.
5246
5247       release
5248           Amount of milliseconds the signal has to fall below the threshold
5249           before reduction is decreased again. Default is 250. Range is
5250           between 0.01 and 9000.
5251
5252       makeup
5253           Set the amount by how much signal will be amplified after
5254           processing.  Default is 1. Range is from 1 to 64.
5255
5256       knee
5257           Curve the sharp knee around the threshold to enter gain reduction
5258           more softly.  Default is 2.82843. Range is between 1 and 8.
5259
5260       link
5261           Choose if the "average" level between all channels of side-chain
5262           stream or the louder("maximum") channel of side-chain stream
5263           affects the reduction. Default is "average".
5264
5265       detection
5266           Should the exact signal be taken in case of "peak" or an RMS one in
5267           case of "rms". Default is "rms" which is mainly smoother.
5268
5269       level_sc
5270           Set sidechain gain. Default is 1. Range is between 0.015625 and 64.
5271
5272       mix How much to use compressed signal in output. Default is 1.  Range
5273           is between 0 and 1.
5274
5275       Commands
5276
5277       This filter supports the all above options as commands.
5278
5279       Examples
5280
5281       •   Full ffmpeg example taking 2 audio inputs, 1st input to be
5282           compressed depending on the signal of 2nd input and later
5283           compressed signal to be merged with 2nd input:
5284
5285                   ffmpeg -i main.flac -i sidechain.flac -filter_complex "[1:a]asplit=2[sc][mix];[0:a][sc]sidechaincompress[compr];[compr][mix]amerge"
5286
5287   sidechaingate
5288       A sidechain gate acts like a normal (wideband) gate but has the ability
5289       to filter the detected signal before sending it to the gain reduction
5290       stage.  Normally a gate uses the full range signal to detect a level
5291       above the threshold.  For example: If you cut all lower frequencies
5292       from your sidechain signal the gate will decrease the volume of your
5293       track only if not enough highs appear. With this technique you are able
5294       to reduce the resonation of a natural drum or remove "rumbling" of
5295       muted strokes from a heavily distorted guitar.  It needs two input
5296       streams and returns one output stream.  First input stream will be
5297       processed depending on second stream signal.
5298
5299       The filter accepts the following options:
5300
5301       level_in
5302           Set input level before filtering.  Default is 1. Allowed range is
5303           from 0.015625 to 64.
5304
5305       mode
5306           Set the mode of operation. Can be "upward" or "downward".  Default
5307           is "downward". If set to "upward" mode, higher parts of signal will
5308           be amplified, expanding dynamic range in upward direction.
5309           Otherwise, in case of "downward" lower parts of signal will be
5310           reduced.
5311
5312       range
5313           Set the level of gain reduction when the signal is below the
5314           threshold.  Default is 0.06125. Allowed range is from 0 to 1.
5315           Setting this to 0 disables reduction and then filter behaves like
5316           expander.
5317
5318       threshold
5319           If a signal rises above this level the gain reduction is released.
5320           Default is 0.125. Allowed range is from 0 to 1.
5321
5322       ratio
5323           Set a ratio about which the signal is reduced.  Default is 2.
5324           Allowed range is from 1 to 9000.
5325
5326       attack
5327           Amount of milliseconds the signal has to rise above the threshold
5328           before gain reduction stops.  Default is 20 milliseconds. Allowed
5329           range is from 0.01 to 9000.
5330
5331       release
5332           Amount of milliseconds the signal has to fall below the threshold
5333           before the reduction is increased again. Default is 250
5334           milliseconds.  Allowed range is from 0.01 to 9000.
5335
5336       makeup
5337           Set amount of amplification of signal after processing.  Default is
5338           1. Allowed range is from 1 to 64.
5339
5340       knee
5341           Curve the sharp knee around the threshold to enter gain reduction
5342           more softly.  Default is 2.828427125. Allowed range is from 1 to 8.
5343
5344       detection
5345           Choose if exact signal should be taken for detection or an RMS like
5346           one.  Default is rms. Can be peak or rms.
5347
5348       link
5349           Choose if the average level between all channels or the louder
5350           channel affects the reduction.  Default is average. Can be average
5351           or maximum.
5352
5353       level_sc
5354           Set sidechain gain. Default is 1. Range is from 0.015625 to 64.
5355
5356       Commands
5357
5358       This filter supports the all above options as commands.
5359
5360   silencedetect
5361       Detect silence in an audio stream.
5362
5363       This filter logs a message when it detects that the input audio volume
5364       is less or equal to a noise tolerance value for a duration greater or
5365       equal to the minimum detected noise duration.
5366
5367       The printed times and duration are expressed in seconds. The
5368       "lavfi.silence_start" or "lavfi.silence_start.X" metadata key is set on
5369       the first frame whose timestamp equals or exceeds the detection
5370       duration and it contains the timestamp of the first frame of the
5371       silence.
5372
5373       The "lavfi.silence_duration" or "lavfi.silence_duration.X" and
5374       "lavfi.silence_end" or "lavfi.silence_end.X" metadata keys are set on
5375       the first frame after the silence. If mono is enabled, and each channel
5376       is evaluated separately, the ".X" suffixed keys are used, and "X"
5377       corresponds to the channel number.
5378
5379       The filter accepts the following options:
5380
5381       noise, n
5382           Set noise tolerance. Can be specified in dB (in case "dB" is
5383           appended to the specified value) or amplitude ratio. Default is
5384           -60dB, or 0.001.
5385
5386       duration, d
5387           Set silence duration until notification (default is 2 seconds). See
5388           the Time duration section in the ffmpeg-utils(1) manual for the
5389           accepted syntax.
5390
5391       mono, m
5392           Process each channel separately, instead of combined. By default is
5393           disabled.
5394
5395       Examples
5396
5397       •   Detect 5 seconds of silence with -50dB noise tolerance:
5398
5399                   silencedetect=n=-50dB:d=5
5400
5401       •   Complete example with ffmpeg to detect silence with 0.0001 noise
5402           tolerance in silence.mp3:
5403
5404                   ffmpeg -i silence.mp3 -af silencedetect=noise=0.0001 -f null -
5405
5406   silenceremove
5407       Remove silence from the beginning, middle or end of the audio.
5408
5409       The filter accepts the following options:
5410
5411       start_periods
5412           This value is used to indicate if audio should be trimmed at
5413           beginning of the audio. A value of zero indicates no silence should
5414           be trimmed from the beginning. When specifying a non-zero value, it
5415           trims audio up until it finds non-silence. Normally, when trimming
5416           silence from beginning of audio the start_periods will be 1 but it
5417           can be increased to higher values to trim all audio up to specific
5418           count of non-silence periods.  Default value is 0.
5419
5420       start_duration
5421           Specify the amount of time that non-silence must be detected before
5422           it stops trimming audio. By increasing the duration, bursts of
5423           noises can be treated as silence and trimmed off. Default value is
5424           0.
5425
5426       start_threshold
5427           This indicates what sample value should be treated as silence. For
5428           digital audio, a value of 0 may be fine but for audio recorded from
5429           analog, you may wish to increase the value to account for
5430           background noise.  Can be specified in dB (in case "dB" is appended
5431           to the specified value) or amplitude ratio. Default value is 0.
5432
5433       start_silence
5434           Specify max duration of silence at beginning that will be kept
5435           after trimming. Default is 0, which is equal to trimming all
5436           samples detected as silence.
5437
5438       start_mode
5439           Specify mode of detection of silence end in start of multi-channel
5440           audio.  Can be any or all. Default is any.  With any, any sample
5441           that is detected as non-silence will cause stopped trimming of
5442           silence.  With all, only if all channels are detected as non-
5443           silence will cause stopped trimming of silence.
5444
5445       stop_periods
5446           Set the count for trimming silence from the end of audio.  To
5447           remove silence from the middle of a file, specify a stop_periods
5448           that is negative. This value is then treated as a positive value
5449           and is used to indicate the effect should restart processing as
5450           specified by start_periods, making it suitable for removing periods
5451           of silence in the middle of the audio.  Default value is 0.
5452
5453       stop_duration
5454           Specify a duration of silence that must exist before audio is not
5455           copied any more. By specifying a higher duration, silence that is
5456           wanted can be left in the audio.  Default value is 0.
5457
5458       stop_threshold
5459           This is the same as start_threshold but for trimming silence from
5460           the end of audio.  Can be specified in dB (in case "dB" is appended
5461           to the specified value) or amplitude ratio. Default value is 0.
5462
5463       stop_silence
5464           Specify max duration of silence at end that will be kept after
5465           trimming. Default is 0, which is equal to trimming all samples
5466           detected as silence.
5467
5468       stop_mode
5469           Specify mode of detection of silence start in end of multi-channel
5470           audio.  Can be any or all. Default is any.  With any, any sample
5471           that is detected as non-silence will cause stopped trimming of
5472           silence.  With all, only if all channels are detected as non-
5473           silence will cause stopped trimming of silence.
5474
5475       detection
5476           Set how is silence detected. Can be "rms" or "peak". Second is
5477           faster and works better with digital silence which is exactly 0.
5478           Default value is "rms".
5479
5480       window
5481           Set duration in number of seconds used to calculate size of window
5482           in number of samples for detecting silence.  Default value is 0.02.
5483           Allowed range is from 0 to 10.
5484
5485       Examples
5486
5487       •   The following example shows how this filter can be used to start a
5488           recording that does not contain the delay at the start which
5489           usually occurs between pressing the record button and the start of
5490           the performance:
5491
5492                   silenceremove=start_periods=1:start_duration=5:start_threshold=0.02
5493
5494       •   Trim all silence encountered from beginning to end where there is
5495           more than 1 second of silence in audio:
5496
5497                   silenceremove=stop_periods=-1:stop_duration=1:stop_threshold=-90dB
5498
5499       •   Trim all digital silence samples, using peak detection, from
5500           beginning to end where there is more than 0 samples of digital
5501           silence in audio and digital silence is detected in all channels at
5502           same positions in stream:
5503
5504                   silenceremove=window=0:detection=peak:stop_mode=all:start_mode=all:stop_periods=-1:stop_threshold=0
5505
5506   sofalizer
5507       SOFAlizer uses head-related transfer functions (HRTFs) to create
5508       virtual loudspeakers around the user for binaural listening via
5509       headphones (audio formats up to 9 channels supported).  The HRTFs are
5510       stored in SOFA files (see <http://www.sofacoustics.org/> for a
5511       database).  SOFAlizer is developed at the Acoustics Research Institute
5512       (ARI) of the Austrian Academy of Sciences.
5513
5514       To enable compilation of this filter you need to configure FFmpeg with
5515       "--enable-libmysofa".
5516
5517       The filter accepts the following options:
5518
5519       sofa
5520           Set the SOFA file used for rendering.
5521
5522       gain
5523           Set gain applied to audio. Value is in dB. Default is 0.
5524
5525       rotation
5526           Set rotation of virtual loudspeakers in deg. Default is 0.
5527
5528       elevation
5529           Set elevation of virtual speakers in deg. Default is 0.
5530
5531       radius
5532           Set distance in meters between loudspeakers and the listener with
5533           near-field HRTFs. Default is 1.
5534
5535       type
5536           Set processing type. Can be time or freq. time is processing audio
5537           in time domain which is slow.  freq is processing audio in
5538           frequency domain which is fast.  Default is freq.
5539
5540       speakers
5541           Set custom positions of virtual loudspeakers. Syntax for this
5542           option is: <CH> <AZIM> <ELEV>[|<CH> <AZIM> <ELEV>|...].  Each
5543           virtual loudspeaker is described with short channel name following
5544           with azimuth and elevation in degrees.  Each virtual loudspeaker
5545           description is separated by '|'.  For example to override front
5546           left and front right channel positions use: 'speakers=FL 45 15|FR
5547           345 15'.  Descriptions with unrecognised channel names are ignored.
5548
5549       lfegain
5550           Set custom gain for LFE channels. Value is in dB. Default is 0.
5551
5552       framesize
5553           Set custom frame size in number of samples. Default is 1024.
5554           Allowed range is from 1024 to 96000. Only used if option type is
5555           set to freq.
5556
5557       normalize
5558           Should all IRs be normalized upon importing SOFA file.  By default
5559           is enabled.
5560
5561       interpolate
5562           Should nearest IRs be interpolated with neighbor IRs if exact
5563           position does not match. By default is disabled.
5564
5565       minphase
5566           Minphase all IRs upon loading of SOFA file. By default is disabled.
5567
5568       anglestep
5569           Set neighbor search angle step. Only used if option interpolate is
5570           enabled.
5571
5572       radstep
5573           Set neighbor search radius step. Only used if option interpolate is
5574           enabled.
5575
5576       Examples
5577
5578       •   Using ClubFritz6 sofa file:
5579
5580                   sofalizer=sofa=/path/to/ClubFritz6.sofa:type=freq:radius=1
5581
5582       •   Using ClubFritz12 sofa file and bigger radius with small rotation:
5583
5584                   sofalizer=sofa=/path/to/ClubFritz12.sofa:type=freq:radius=2:rotation=5
5585
5586       •   Similar as above but with custom speaker positions for front left,
5587           front right, back left and back right and also with custom gain:
5588
5589                   "sofalizer=sofa=/path/to/ClubFritz6.sofa:type=freq:radius=2:speakers=FL 45|FR 315|BL 135|BR 225:gain=28"
5590
5591   speechnorm
5592       Speech Normalizer.
5593
5594       This filter expands or compresses each half-cycle of audio samples
5595       (local set of samples all above or all below zero and between two
5596       nearest zero crossings) depending on threshold value, so audio reaches
5597       target peak value under conditions controlled by below options.
5598
5599       The filter accepts the following options:
5600
5601       peak, p
5602           Set the expansion target peak value. This specifies the highest
5603           allowed absolute amplitude level for the normalized audio input.
5604           Default value is 0.95. Allowed range is from 0.0 to 1.0.
5605
5606       expansion, e
5607           Set the maximum expansion factor. Allowed range is from 1.0 to
5608           50.0. Default value is 2.0.  This option controls maximum local
5609           half-cycle of samples expansion. The maximum expansion would be
5610           such that local peak value reaches target peak value but never to
5611           surpass it and that ratio between new and previous peak value does
5612           not surpass this option value.
5613
5614       compression, c
5615           Set the maximum compression factor. Allowed range is from 1.0 to
5616           50.0. Default value is 2.0.  This option controls maximum local
5617           half-cycle of samples compression. This option is used only if
5618           threshold option is set to value greater than 0.0, then in such
5619           cases when local peak is lower or same as value set by threshold
5620           all samples belonging to that peak's half-cycle will be compressed
5621           by current compression factor.
5622
5623       threshold, t
5624           Set the threshold value. Default value is 0.0. Allowed range is
5625           from 0.0 to 1.0.  This option specifies which half-cycles of
5626           samples will be compressed and which will be expanded.  Any half-
5627           cycle samples with their local peak value below or same as this
5628           option value will be compressed by current compression factor,
5629           otherwise, if greater than threshold value they will be expanded
5630           with expansion factor so that it could reach peak target value but
5631           never surpass it.
5632
5633       raise, r
5634           Set the expansion raising amount per each half-cycle of samples.
5635           Default value is 0.001.  Allowed range is from 0.0 to 1.0. This
5636           controls how fast expansion factor is raised per each new half-
5637           cycle until it reaches expansion value.  Setting this options too
5638           high may lead to distortions.
5639
5640       fall, f
5641           Set the compression raising amount per each half-cycle of samples.
5642           Default value is 0.001.  Allowed range is from 0.0 to 1.0. This
5643           controls how fast compression factor is raised per each new half-
5644           cycle until it reaches compression value.
5645
5646       channels, h
5647           Specify which channels to filter, by default all available channels
5648           are filtered.
5649
5650       invert, i
5651           Enable inverted filtering, by default is disabled. This inverts
5652           interpretation of threshold option. When enabled any half-cycle of
5653           samples with their local peak value below or same as threshold
5654           option will be expanded otherwise it will be compressed.
5655
5656       link, l
5657           Link channels when calculating gain applied to each filtered
5658           channel sample, by default is disabled.  When disabled each
5659           filtered channel gain calculation is independent, otherwise when
5660           this option is enabled the minimum of all possible gains for each
5661           filtered channel is used.
5662
5663       Commands
5664
5665       This filter supports the all above options as commands.
5666
5667   stereotools
5668       This filter has some handy utilities to manage stereo signals, for
5669       converting M/S stereo recordings to L/R signal while having control
5670       over the parameters or spreading the stereo image of master track.
5671
5672       The filter accepts the following options:
5673
5674       level_in
5675           Set input level before filtering for both channels. Defaults is 1.
5676           Allowed range is from 0.015625 to 64.
5677
5678       level_out
5679           Set output level after filtering for both channels. Defaults is 1.
5680           Allowed range is from 0.015625 to 64.
5681
5682       balance_in
5683           Set input balance between both channels. Default is 0.  Allowed
5684           range is from -1 to 1.
5685
5686       balance_out
5687           Set output balance between both channels. Default is 0.  Allowed
5688           range is from -1 to 1.
5689
5690       softclip
5691           Enable softclipping. Results in analog distortion instead of harsh
5692           digital 0dB clipping. Disabled by default.
5693
5694       mutel
5695           Mute the left channel. Disabled by default.
5696
5697       muter
5698           Mute the right channel. Disabled by default.
5699
5700       phasel
5701           Change the phase of the left channel. Disabled by default.
5702
5703       phaser
5704           Change the phase of the right channel. Disabled by default.
5705
5706       mode
5707           Set stereo mode. Available values are:
5708
5709           lr>lr
5710               Left/Right to Left/Right, this is default.
5711
5712           lr>ms
5713               Left/Right to Mid/Side.
5714
5715           ms>lr
5716               Mid/Side to Left/Right.
5717
5718           lr>ll
5719               Left/Right to Left/Left.
5720
5721           lr>rr
5722               Left/Right to Right/Right.
5723
5724           lr>l+r
5725               Left/Right to Left + Right.
5726
5727           lr>rl
5728               Left/Right to Right/Left.
5729
5730           ms>ll
5731               Mid/Side to Left/Left.
5732
5733           ms>rr
5734               Mid/Side to Right/Right.
5735
5736           ms>rl
5737               Mid/Side to Right/Left.
5738
5739           lr>l-r
5740               Left/Right to Left - Right.
5741
5742       slev
5743           Set level of side signal. Default is 1.  Allowed range is from
5744           0.015625 to 64.
5745
5746       sbal
5747           Set balance of side signal. Default is 0.  Allowed range is from -1
5748           to 1.
5749
5750       mlev
5751           Set level of the middle signal. Default is 1.  Allowed range is
5752           from 0.015625 to 64.
5753
5754       mpan
5755           Set middle signal pan. Default is 0. Allowed range is from -1 to 1.
5756
5757       base
5758           Set stereo base between mono and inversed channels. Default is 0.
5759           Allowed range is from -1 to 1.
5760
5761       delay
5762           Set delay in milliseconds how much to delay left from right channel
5763           and vice versa. Default is 0. Allowed range is from -20 to 20.
5764
5765       sclevel
5766           Set S/C level. Default is 1. Allowed range is from 1 to 100.
5767
5768       phase
5769           Set the stereo phase in degrees. Default is 0. Allowed range is
5770           from 0 to 360.
5771
5772       bmode_in, bmode_out
5773           Set balance mode for balance_in/balance_out option.
5774
5775           Can be one of the following:
5776
5777           balance
5778               Classic balance mode. Attenuate one channel at time.  Gain is
5779               raised up to 1.
5780
5781           amplitude
5782               Similar as classic mode above but gain is raised up to 2.
5783
5784           power
5785               Equal power distribution, from -6dB to +6dB range.
5786
5787       Commands
5788
5789       This filter supports the all above options as commands.
5790
5791       Examples
5792
5793       •   Apply karaoke like effect:
5794
5795                   stereotools=mlev=0.015625
5796
5797       •   Convert M/S signal to L/R:
5798
5799                   "stereotools=mode=ms>lr"
5800
5801   stereowiden
5802       This filter enhance the stereo effect by suppressing signal common to
5803       both channels and by delaying the signal of left into right and vice
5804       versa, thereby widening the stereo effect.
5805
5806       The filter accepts the following options:
5807
5808       delay
5809           Time in milliseconds of the delay of left signal into right and
5810           vice versa.  Default is 20 milliseconds.
5811
5812       feedback
5813           Amount of gain in delayed signal into right and vice versa. Gives a
5814           delay effect of left signal in right output and vice versa which
5815           gives widening effect. Default is 0.3.
5816
5817       crossfeed
5818           Cross feed of left into right with inverted phase. This helps in
5819           suppressing the mono. If the value is 1 it will cancel all the
5820           signal common to both channels. Default is 0.3.
5821
5822       drymix
5823           Set level of input signal of original channel. Default is 0.8.
5824
5825       Commands
5826
5827       This filter supports the all above options except "delay" as commands.
5828
5829   superequalizer
5830       Apply 18 band equalizer.
5831
5832       The filter accepts the following options:
5833
5834       1b  Set 65Hz band gain.
5835
5836       2b  Set 92Hz band gain.
5837
5838       3b  Set 131Hz band gain.
5839
5840       4b  Set 185Hz band gain.
5841
5842       5b  Set 262Hz band gain.
5843
5844       6b  Set 370Hz band gain.
5845
5846       7b  Set 523Hz band gain.
5847
5848       8b  Set 740Hz band gain.
5849
5850       9b  Set 1047Hz band gain.
5851
5852       10b Set 1480Hz band gain.
5853
5854       11b Set 2093Hz band gain.
5855
5856       12b Set 2960Hz band gain.
5857
5858       13b Set 4186Hz band gain.
5859
5860       14b Set 5920Hz band gain.
5861
5862       15b Set 8372Hz band gain.
5863
5864       16b Set 11840Hz band gain.
5865
5866       17b Set 16744Hz band gain.
5867
5868       18b Set 20000Hz band gain.
5869
5870   surround
5871       Apply audio surround upmix filter.
5872
5873       This filter allows to produce multichannel output from audio stream.
5874
5875       The filter accepts the following options:
5876
5877       chl_out
5878           Set output channel layout. By default, this is 5.1.
5879
5880           See the Channel Layout section in the ffmpeg-utils(1) manual for
5881           the required syntax.
5882
5883       chl_in
5884           Set input channel layout. By default, this is stereo.
5885
5886           See the Channel Layout section in the ffmpeg-utils(1) manual for
5887           the required syntax.
5888
5889       level_in
5890           Set input volume level. By default, this is 1.
5891
5892       level_out
5893           Set output volume level. By default, this is 1.
5894
5895       lfe Enable LFE channel output if output channel layout has it. By
5896           default, this is enabled.
5897
5898       lfe_low
5899           Set LFE low cut off frequency. By default, this is 128 Hz.
5900
5901       lfe_high
5902           Set LFE high cut off frequency. By default, this is 256 Hz.
5903
5904       lfe_mode
5905           Set LFE mode, can be add or sub. Default is add.  In add mode, LFE
5906           channel is created from input audio and added to output.  In sub
5907           mode, LFE channel is created from input audio and added to output
5908           but also all non-LFE output channels are subtracted with output LFE
5909           channel.
5910
5911       angle
5912           Set angle of stereo surround transform, Allowed range is from 0 to
5913           360.  Default is 90.
5914
5915       fc_in
5916           Set front center input volume. By default, this is 1.
5917
5918       fc_out
5919           Set front center output volume. By default, this is 1.
5920
5921       fl_in
5922           Set front left input volume. By default, this is 1.
5923
5924       fl_out
5925           Set front left output volume. By default, this is 1.
5926
5927       fr_in
5928           Set front right input volume. By default, this is 1.
5929
5930       fr_out
5931           Set front right output volume. By default, this is 1.
5932
5933       sl_in
5934           Set side left input volume. By default, this is 1.
5935
5936       sl_out
5937           Set side left output volume. By default, this is 1.
5938
5939       sr_in
5940           Set side right input volume. By default, this is 1.
5941
5942       sr_out
5943           Set side right output volume. By default, this is 1.
5944
5945       bl_in
5946           Set back left input volume. By default, this is 1.
5947
5948       bl_out
5949           Set back left output volume. By default, this is 1.
5950
5951       br_in
5952           Set back right input volume. By default, this is 1.
5953
5954       br_out
5955           Set back right output volume. By default, this is 1.
5956
5957       bc_in
5958           Set back center input volume. By default, this is 1.
5959
5960       bc_out
5961           Set back center output volume. By default, this is 1.
5962
5963       lfe_in
5964           Set LFE input volume. By default, this is 1.
5965
5966       lfe_out
5967           Set LFE output volume. By default, this is 1.
5968
5969       allx
5970           Set spread usage of stereo image across X axis for all channels.
5971           Allowed range is from -1 to 15.  By default this value is negative
5972           -1, and thus unused.
5973
5974       ally
5975           Set spread usage of stereo image across Y axis for all channels.
5976           Allowed range is from -1 to 15.  By default this value is negative
5977           -1, and thus unused.
5978
5979       fcx, flx, frx, blx, brx, slx, srx, bcx
5980           Set spread usage of stereo image across X axis for each channel.
5981           Allowed range is from 0.06 to 15.  By default this value is 0.5.
5982
5983       fcy, fly, fry, bly, bry, sly, sry, bcy
5984           Set spread usage of stereo image across Y axis for each channel.
5985           Allowed range is from 0.06 to 15.  By default this value is 0.5.
5986
5987       win_size
5988           Set window size. Allowed range is from 1024 to 65536. Default size
5989           is 4096.
5990
5991       win_func
5992           Set window function.
5993
5994           It accepts the following values:
5995
5996           rect
5997           bartlett
5998           hann, hanning
5999           hamming
6000           blackman
6001           welch
6002           flattop
6003           bharris
6004           bnuttall
6005           bhann
6006           sine
6007           nuttall
6008           lanczos
6009           gauss
6010           tukey
6011           dolph
6012           cauchy
6013           parzen
6014           poisson
6015           bohman
6016
6017           Default is "hann".
6018
6019       overlap
6020           Set window overlap. If set to 1, the recommended overlap for
6021           selected window function will be picked. Default is 0.5.
6022
6023   tiltshelf
6024       Boost or cut the lower frequencies and cut or boost higher frequencies
6025       of the audio using a two-pole shelving filter with a response similar
6026       to that of a standard hi-fi's tone-controls.  This is also known as
6027       shelving equalisation (EQ).
6028
6029       The filter accepts the following options:
6030
6031       gain, g
6032           Give the gain at 0 Hz. Its useful range is about -20 (for a large
6033           cut) to +20 (for a large boost).  Beware of clipping when using a
6034           positive gain.
6035
6036       frequency, f
6037           Set the filter's central frequency and so can be used to extend or
6038           reduce the frequency range to be boosted or cut.  The default value
6039           is 3000 Hz.
6040
6041       width_type, t
6042           Set method to specify band-width of filter.
6043
6044           h   Hz
6045
6046           q   Q-Factor
6047
6048           o   octave
6049
6050           s   slope
6051
6052           k   kHz
6053
6054       width, w
6055           Determine how steep is the filter's shelf transition.
6056
6057       poles, p
6058           Set number of poles. Default is 2.
6059
6060       mix, m
6061           How much to use filtered signal in output. Default is 1.  Range is
6062           between 0 and 1.
6063
6064       channels, c
6065           Specify which channels to filter, by default all available are
6066           filtered.
6067
6068       normalize, n
6069           Normalize biquad coefficients, by default is disabled.  Enabling it
6070           will normalize magnitude response at DC to 0dB.
6071
6072       transform, a
6073           Set transform type of IIR filter.
6074
6075           di
6076           dii
6077           tdi
6078           tdii
6079           latt
6080           svf
6081           zdf
6082       precision, r
6083           Set precison of filtering.
6084
6085           auto
6086               Pick automatic sample format depending on surround filters.
6087
6088           s16 Always use signed 16-bit.
6089
6090           s32 Always use signed 32-bit.
6091
6092           f32 Always use float 32-bit.
6093
6094           f64 Always use float 64-bit.
6095
6096       block_size, b
6097           Set block size used for reverse IIR processing. If this value is
6098           set to high enough value (higher than impulse response length
6099           truncated when reaches near zero values) filtering will become
6100           linear phase otherwise if not big enough it will just produce nasty
6101           artifacts.
6102
6103           Note that filter delay will be exactly this many samples when set
6104           to non-zero value.
6105
6106       Commands
6107
6108       This filter supports some options as commands.
6109
6110   treble, highshelf
6111       Boost or cut treble (upper) frequencies of the audio using a two-pole
6112       shelving filter with a response similar to that of a standard hi-fi's
6113       tone-controls. This is also known as shelving equalisation (EQ).
6114
6115       The filter accepts the following options:
6116
6117       gain, g
6118           Give the gain at whichever is the lower of ~22 kHz and the Nyquist
6119           frequency. Its useful range is about -20 (for a large cut) to +20
6120           (for a large boost). Beware of clipping when using a positive gain.
6121
6122       frequency, f
6123           Set the filter's central frequency and so can be used to extend or
6124           reduce the frequency range to be boosted or cut.  The default value
6125           is 3000 Hz.
6126
6127       width_type, t
6128           Set method to specify band-width of filter.
6129
6130           h   Hz
6131
6132           q   Q-Factor
6133
6134           o   octave
6135
6136           s   slope
6137
6138           k   kHz
6139
6140       width, w
6141           Determine how steep is the filter's shelf transition.
6142
6143       poles, p
6144           Set number of poles. Default is 2.
6145
6146       mix, m
6147           How much to use filtered signal in output. Default is 1.  Range is
6148           between 0 and 1.
6149
6150       channels, c
6151           Specify which channels to filter, by default all available are
6152           filtered.
6153
6154       normalize, n
6155           Normalize biquad coefficients, by default is disabled.  Enabling it
6156           will normalize magnitude response at DC to 0dB.
6157
6158       transform, a
6159           Set transform type of IIR filter.
6160
6161           di
6162           dii
6163           tdi
6164           tdii
6165           latt
6166           svf
6167           zdf
6168       precision, r
6169           Set precison of filtering.
6170
6171           auto
6172               Pick automatic sample format depending on surround filters.
6173
6174           s16 Always use signed 16-bit.
6175
6176           s32 Always use signed 32-bit.
6177
6178           f32 Always use float 32-bit.
6179
6180           f64 Always use float 64-bit.
6181
6182       block_size, b
6183           Set block size used for reverse IIR processing. If this value is
6184           set to high enough value (higher than impulse response length
6185           truncated when reaches near zero values) filtering will become
6186           linear phase otherwise if not big enough it will just produce nasty
6187           artifacts.
6188
6189           Note that filter delay will be exactly this many samples when set
6190           to non-zero value.
6191
6192       Commands
6193
6194       This filter supports the following commands:
6195
6196       frequency, f
6197           Change treble frequency.  Syntax for the command is : "frequency"
6198
6199       width_type, t
6200           Change treble width_type.  Syntax for the command is : "width_type"
6201
6202       width, w
6203           Change treble width.  Syntax for the command is : "width"
6204
6205       gain, g
6206           Change treble gain.  Syntax for the command is : "gain"
6207
6208       mix, m
6209           Change treble mix.  Syntax for the command is : "mix"
6210
6211   tremolo
6212       Sinusoidal amplitude modulation.
6213
6214       The filter accepts the following options:
6215
6216       f   Modulation frequency in Hertz. Modulation frequencies in the
6217           subharmonic range (20 Hz or lower) will result in a tremolo effect.
6218           This filter may also be used as a ring modulator by specifying a
6219           modulation frequency higher than 20 Hz.  Range is 0.1 - 20000.0.
6220           Default value is 5.0 Hz.
6221
6222       d   Depth of modulation as a percentage. Range is 0.0 - 1.0.  Default
6223           value is 0.5.
6224
6225   vibrato
6226       Sinusoidal phase modulation.
6227
6228       The filter accepts the following options:
6229
6230       f   Modulation frequency in Hertz.  Range is 0.1 - 20000.0. Default
6231           value is 5.0 Hz.
6232
6233       d   Depth of modulation as a percentage. Range is 0.0 - 1.0.  Default
6234           value is 0.5.
6235
6236   virtualbass
6237       Apply audio Virtual Bass filter.
6238
6239       This filter accepts stereo input and produce stereo with LFE (2.1)
6240       channels output.  The newly produced LFE channel have enhanced virtual
6241       bass originally obtained from both stereo channels.  This filter
6242       outputs front left and front right channels unchanged as available in
6243       stereo input.
6244
6245       The filter accepts the following options:
6246
6247       cutoff
6248           Set the virtual bass cutoff frequency. Default value is 250 Hz.
6249           Allowed range is from 100 to 500 Hz.
6250
6251       strength
6252           Set the virtual bass strength. Allowed range is from 0.5 to 3.
6253           Default value is 3.
6254
6255   volume
6256       Adjust the input audio volume.
6257
6258       It accepts the following parameters:
6259
6260       volume
6261           Set audio volume expression.
6262
6263           Output values are clipped to the maximum value.
6264
6265           The output audio volume is given by the relation:
6266
6267                   <output_volume> = <volume> * <input_volume>
6268
6269           The default value for volume is "1.0".
6270
6271       precision
6272           This parameter represents the mathematical precision.
6273
6274           It determines which input sample formats will be allowed, which
6275           affects the precision of the volume scaling.
6276
6277           fixed
6278               8-bit fixed-point; this limits input sample format to U8, S16,
6279               and S32.
6280
6281           float
6282               32-bit floating-point; this limits input sample format to FLT.
6283               (default)
6284
6285           double
6286               64-bit floating-point; this limits input sample format to DBL.
6287
6288       replaygain
6289           Choose the behaviour on encountering ReplayGain side data in input
6290           frames.
6291
6292           drop
6293               Remove ReplayGain side data, ignoring its contents (the
6294               default).
6295
6296           ignore
6297               Ignore ReplayGain side data, but leave it in the frame.
6298
6299           track
6300               Prefer the track gain, if present.
6301
6302           album
6303               Prefer the album gain, if present.
6304
6305       replaygain_preamp
6306           Pre-amplification gain in dB to apply to the selected replaygain
6307           gain.
6308
6309           Default value for replaygain_preamp is 0.0.
6310
6311       replaygain_noclip
6312           Prevent clipping by limiting the gain applied.
6313
6314           Default value for replaygain_noclip is 1.
6315
6316       eval
6317           Set when the volume expression is evaluated.
6318
6319           It accepts the following values:
6320
6321           once
6322               only evaluate expression once during the filter initialization,
6323               or when the volume command is sent
6324
6325           frame
6326               evaluate expression for each incoming frame
6327
6328           Default value is once.
6329
6330       The volume expression can contain the following parameters.
6331
6332       n   frame number (starting at zero)
6333
6334       nb_channels
6335           number of channels
6336
6337       nb_consumed_samples
6338           number of samples consumed by the filter
6339
6340       nb_samples
6341           number of samples in the current frame
6342
6343       pos original frame position in the file
6344
6345       pts frame PTS
6346
6347       sample_rate
6348           sample rate
6349
6350       startpts
6351           PTS at start of stream
6352
6353       startt
6354           time at start of stream
6355
6356       t   frame time
6357
6358       tb  timestamp timebase
6359
6360       volume
6361           last set volume value
6362
6363       Note that when eval is set to once only the sample_rate and tb
6364       variables are available, all other variables will evaluate to NAN.
6365
6366       Commands
6367
6368       This filter supports the following commands:
6369
6370       volume
6371           Modify the volume expression.  The command accepts the same syntax
6372           of the corresponding option.
6373
6374           If the specified expression is not valid, it is kept at its current
6375           value.
6376
6377       Examples
6378
6379       •   Halve the input audio volume:
6380
6381                   volume=volume=0.5
6382                   volume=volume=1/2
6383                   volume=volume=-6.0206dB
6384
6385           In all the above example the named key for volume can be omitted,
6386           for example like in:
6387
6388                   volume=0.5
6389
6390       •   Increase input audio power by 6 decibels using fixed-point
6391           precision:
6392
6393                   volume=volume=6dB:precision=fixed
6394
6395       •   Fade volume after time 10 with an annihilation period of 5 seconds:
6396
6397                   volume='if(lt(t,10),1,max(1-(t-10)/5,0))':eval=frame
6398
6399   volumedetect
6400       Detect the volume of the input video.
6401
6402       The filter has no parameters. It supports only 16-bit signed integer
6403       samples, so the input will be converted when needed. Statistics about
6404       the volume will be printed in the log when the input stream end is
6405       reached.
6406
6407       In particular it will show the mean volume (root mean square), maximum
6408       volume (on a per-sample basis), and the beginning of a histogram of the
6409       registered volume values (from the maximum value to a cumulated 1/1000
6410       of the samples).
6411
6412       All volumes are in decibels relative to the maximum PCM value.
6413
6414       Examples
6415
6416       Here is an excerpt of the output:
6417
6418               [Parsed_volumedetect_0  0xa23120] mean_volume: -27 dB
6419               [Parsed_volumedetect_0  0xa23120] max_volume: -4 dB
6420               [Parsed_volumedetect_0  0xa23120] histogram_4db: 6
6421               [Parsed_volumedetect_0  0xa23120] histogram_5db: 62
6422               [Parsed_volumedetect_0  0xa23120] histogram_6db: 286
6423               [Parsed_volumedetect_0  0xa23120] histogram_7db: 1042
6424               [Parsed_volumedetect_0  0xa23120] histogram_8db: 2551
6425               [Parsed_volumedetect_0  0xa23120] histogram_9db: 4609
6426               [Parsed_volumedetect_0  0xa23120] histogram_10db: 8409
6427
6428       It means that:
6429
6430       •   The mean square energy is approximately -27 dB, or 10^-2.7.
6431
6432       •   The largest sample is at -4 dB, or more precisely between -4 dB and
6433           -5 dB.
6434
6435       •   There are 6 samples at -4 dB, 62 at -5 dB, 286 at -6 dB, etc.
6436
6437       In other words, raising the volume by +4 dB does not cause any
6438       clipping, raising it by +5 dB causes clipping for 6 samples, etc.
6439

AUDIO SOURCES

6441       Below is a description of the currently available audio sources.
6442
6443   abuffer
6444       Buffer audio frames, and make them available to the filter chain.
6445
6446       This source is mainly intended for a programmatic use, in particular
6447       through the interface defined in libavfilter/buffersrc.h.
6448
6449       It accepts the following parameters:
6450
6451       time_base
6452           The timebase which will be used for timestamps of submitted frames.
6453           It must be either a floating-point number or in
6454           numerator/denominator form.
6455
6456       sample_rate
6457           The sample rate of the incoming audio buffers.
6458
6459       sample_fmt
6460           The sample format of the incoming audio buffers.  Either a sample
6461           format name or its corresponding integer representation from the
6462           enum AVSampleFormat in libavutil/samplefmt.h
6463
6464       channel_layout
6465           The channel layout of the incoming audio buffers.  Either a channel
6466           layout name from channel_layout_map in libavutil/channel_layout.c
6467           or its corresponding integer representation from the AV_CH_LAYOUT_*
6468           macros in libavutil/channel_layout.h
6469
6470       channels
6471           The number of channels of the incoming audio buffers.  If both
6472           channels and channel_layout are specified, then they must be
6473           consistent.
6474
6475       Examples
6476
6477               abuffer=sample_rate=44100:sample_fmt=s16p:channel_layout=stereo
6478
6479       will instruct the source to accept planar 16bit signed stereo at
6480       44100Hz.  Since the sample format with name "s16p" corresponds to the
6481       number 6 and the "stereo" channel layout corresponds to the value 0x3,
6482       this is equivalent to:
6483
6484               abuffer=sample_rate=44100:sample_fmt=6:channel_layout=0x3
6485
6486   aevalsrc
6487       Generate an audio signal specified by an expression.
6488
6489       This source accepts in input one or more expressions (one for each
6490       channel), which are evaluated and used to generate a corresponding
6491       audio signal.
6492
6493       This source accepts the following options:
6494
6495       exprs
6496           Set the '|'-separated expressions list for each separate channel.
6497           In case the channel_layout option is not specified, the selected
6498           channel layout depends on the number of provided expressions.
6499           Otherwise the last specified expression is applied to the remaining
6500           output channels.
6501
6502       channel_layout, c
6503           Set the channel layout. The number of channels in the specified
6504           layout must be equal to the number of specified expressions.
6505
6506       duration, d
6507           Set the minimum duration of the sourced audio. See the Time
6508           duration section in the ffmpeg-utils(1) manual for the accepted
6509           syntax.  Note that the resulting duration may be greater than the
6510           specified duration, as the generated audio is always cut at the end
6511           of a complete frame.
6512
6513           If not specified, or the expressed duration is negative, the audio
6514           is supposed to be generated forever.
6515
6516       nb_samples, n
6517           Set the number of samples per channel per each output frame,
6518           default to 1024.
6519
6520       sample_rate, s
6521           Specify the sample rate, default to 44100.
6522
6523       Each expression in exprs can contain the following constants:
6524
6525       n   number of the evaluated sample, starting from 0
6526
6527       t   time of the evaluated sample expressed in seconds, starting from 0
6528
6529       s   sample rate
6530
6531       Examples
6532
6533       •   Generate silence:
6534
6535                   aevalsrc=0
6536
6537       •   Generate a sin signal with frequency of 440 Hz, set sample rate to
6538           8000 Hz:
6539
6540                   aevalsrc="sin(440*2*PI*t):s=8000"
6541
6542       •   Generate a two channels signal, specify the channel layout (Front
6543           Center + Back Center) explicitly:
6544
6545                   aevalsrc="sin(420*2*PI*t)|cos(430*2*PI*t):c=FC|BC"
6546
6547       •   Generate white noise:
6548
6549                   aevalsrc="-2+random(0)"
6550
6551       •   Generate an amplitude modulated signal:
6552
6553                   aevalsrc="sin(10*2*PI*t)*sin(880*2*PI*t)"
6554
6555       •   Generate 2.5 Hz binaural beats on a 360 Hz carrier:
6556
6557                   aevalsrc="0.1*sin(2*PI*(360-2.5/2)*t) | 0.1*sin(2*PI*(360+2.5/2)*t)"
6558
6559   afirsrc
6560       Generate a FIR coefficients using frequency sampling method.
6561
6562       The resulting stream can be used with afir filter for filtering the
6563       audio signal.
6564
6565       The filter accepts the following options:
6566
6567       taps, t
6568           Set number of filter coefficents in output audio stream.  Default
6569           value is 1025.
6570
6571       frequency, f
6572           Set frequency points from where magnitude and phase are set.  This
6573           must be in non decreasing order, and first element must be 0, while
6574           last element must be 1. Elements are separated by white spaces.
6575
6576       magnitude, m
6577           Set magnitude value for every frequency point set by frequency.
6578           Number of values must be same as number of frequency points.
6579           Values are separated by white spaces.
6580
6581       phase, p
6582           Set phase value for every frequency point set by frequency.  Number
6583           of values must be same as number of frequency points.  Values are
6584           separated by white spaces.
6585
6586       sample_rate, r
6587           Set sample rate, default is 44100.
6588
6589       nb_samples, n
6590           Set number of samples per each frame. Default is 1024.
6591
6592       win_func, w
6593           Set window function. Default is blackman.
6594
6595   anullsrc
6596       The null audio source, return unprocessed audio frames. It is mainly
6597       useful as a template and to be employed in analysis / debugging tools,
6598       or as the source for filters which ignore the input data (for example
6599       the sox synth filter).
6600
6601       This source accepts the following options:
6602
6603       channel_layout, cl
6604           Specifies the channel layout, and can be either an integer or a
6605           string representing a channel layout. The default value of
6606           channel_layout is "stereo".
6607
6608           Check the channel_layout_map definition in
6609           libavutil/channel_layout.c for the mapping between strings and
6610           channel layout values.
6611
6612       sample_rate, r
6613           Specifies the sample rate, and defaults to 44100.
6614
6615       nb_samples, n
6616           Set the number of samples per requested frames.
6617
6618       duration, d
6619           Set the duration of the sourced audio. See the Time duration
6620           section in the ffmpeg-utils(1) manual for the accepted syntax.
6621
6622           If not specified, or the expressed duration is negative, the audio
6623           is supposed to be generated forever.
6624
6625       Examples
6626
6627       •   Set the sample rate to 48000 Hz and the channel layout to
6628           AV_CH_LAYOUT_MONO.
6629
6630                   anullsrc=r=48000:cl=4
6631
6632       •   Do the same operation with a more obvious syntax:
6633
6634                   anullsrc=r=48000:cl=mono
6635
6636       All the parameters need to be explicitly defined.
6637
6638   flite
6639       Synthesize a voice utterance using the libflite library.
6640
6641       To enable compilation of this filter you need to configure FFmpeg with
6642       "--enable-libflite".
6643
6644       Note that versions of the flite library prior to 2.0 are not thread-
6645       safe.
6646
6647       The filter accepts the following options:
6648
6649       list_voices
6650           If set to 1, list the names of the available voices and exit
6651           immediately. Default value is 0.
6652
6653       nb_samples, n
6654           Set the maximum number of samples per frame. Default value is 512.
6655
6656       textfile
6657           Set the filename containing the text to speak.
6658
6659       text
6660           Set the text to speak.
6661
6662       voice, v
6663           Set the voice to use for the speech synthesis. Default value is
6664           "kal". See also the list_voices option.
6665
6666       Examples
6667
6668       •   Read from file speech.txt, and synthesize the text using the
6669           standard flite voice:
6670
6671                   flite=textfile=speech.txt
6672
6673       •   Read the specified text selecting the "slt" voice:
6674
6675                   flite=text='So fare thee well, poor devil of a Sub-Sub, whose commentator I am':voice=slt
6676
6677       •   Input text to ffmpeg:
6678
6679                   ffmpeg -f lavfi -i flite=text='So fare thee well, poor devil of a Sub-Sub, whose commentator I am':voice=slt
6680
6681       •   Make ffplay speak the specified text, using "flite" and the "lavfi"
6682           device:
6683
6684                   ffplay -f lavfi flite=text='No more be grieved for which that thou hast done.'
6685
6686       For more information about libflite, check:
6687       <http://www.festvox.org/flite/>
6688
6689   anoisesrc
6690       Generate a noise audio signal.
6691
6692       The filter accepts the following options:
6693
6694       sample_rate, r
6695           Specify the sample rate. Default value is 48000 Hz.
6696
6697       amplitude, a
6698           Specify the amplitude (0.0 - 1.0) of the generated audio stream.
6699           Default value is 1.0.
6700
6701       duration, d
6702           Specify the duration of the generated audio stream. Not specifying
6703           this option results in noise with an infinite length.
6704
6705       color, colour, c
6706           Specify the color of noise. Available noise colors are white, pink,
6707           brown, blue, violet and velvet. Default color is white.
6708
6709       seed, s
6710           Specify a value used to seed the PRNG.
6711
6712       nb_samples, n
6713           Set the number of samples per each output frame, default is 1024.
6714
6715       Examples
6716
6717       •   Generate 60 seconds of pink noise, with a 44.1 kHz sampling rate
6718           and an amplitude of 0.5:
6719
6720                   anoisesrc=d=60:c=pink:r=44100:a=0.5
6721
6722   hilbert
6723       Generate odd-tap Hilbert transform FIR coefficients.
6724
6725       The resulting stream can be used with afir filter for phase-shifting
6726       the signal by 90 degrees.
6727
6728       This is used in many matrix coding schemes and for analytic signal
6729       generation.  The process is often written as a multiplication by i (or
6730       j), the imaginary unit.
6731
6732       The filter accepts the following options:
6733
6734       sample_rate, s
6735           Set sample rate, default is 44100.
6736
6737       taps, t
6738           Set length of FIR filter, default is 22051.
6739
6740       nb_samples, n
6741           Set number of samples per each frame.
6742
6743       win_func, w
6744           Set window function to be used when generating FIR coefficients.
6745
6746   sinc
6747       Generate a sinc kaiser-windowed low-pass, high-pass, band-pass, or
6748       band-reject FIR coefficients.
6749
6750       The resulting stream can be used with afir filter for filtering the
6751       audio signal.
6752
6753       The filter accepts the following options:
6754
6755       sample_rate, r
6756           Set sample rate, default is 44100.
6757
6758       nb_samples, n
6759           Set number of samples per each frame. Default is 1024.
6760
6761       hp  Set high-pass frequency. Default is 0.
6762
6763       lp  Set low-pass frequency. Default is 0.  If high-pass frequency is
6764           lower than low-pass frequency and low-pass frequency is higher than
6765           0 then filter will create band-pass filter coefficients, otherwise
6766           band-reject filter coefficients.
6767
6768       phase
6769           Set filter phase response. Default is 50. Allowed range is from 0
6770           to 100.
6771
6772       beta
6773           Set Kaiser window beta.
6774
6775       att Set stop-band attenuation. Default is 120dB, allowed range is from
6776           40 to 180 dB.
6777
6778       round
6779           Enable rounding, by default is disabled.
6780
6781       hptaps
6782           Set number of taps for high-pass filter.
6783
6784       lptaps
6785           Set number of taps for low-pass filter.
6786
6787   sine
6788       Generate an audio signal made of a sine wave with amplitude 1/8.
6789
6790       The audio signal is bit-exact.
6791
6792       The filter accepts the following options:
6793
6794       frequency, f
6795           Set the carrier frequency. Default is 440 Hz.
6796
6797       beep_factor, b
6798           Enable a periodic beep every second with frequency beep_factor
6799           times the carrier frequency. Default is 0, meaning the beep is
6800           disabled.
6801
6802       sample_rate, r
6803           Specify the sample rate, default is 44100.
6804
6805       duration, d
6806           Specify the duration of the generated audio stream.
6807
6808       samples_per_frame
6809           Set the number of samples per output frame.
6810
6811           The expression can contain the following constants:
6812
6813           n   The (sequential) number of the output audio frame, starting
6814               from 0.
6815
6816           pts The PTS (Presentation TimeStamp) of the output audio frame,
6817               expressed in TB units.
6818
6819           t   The PTS of the output audio frame, expressed in seconds.
6820
6821           TB  The timebase of the output audio frames.
6822
6823           Default is 1024.
6824
6825       Examples
6826
6827       •   Generate a simple 440 Hz sine wave:
6828
6829                   sine
6830
6831       •   Generate a 220 Hz sine wave with a 880 Hz beep each second, for 5
6832           seconds:
6833
6834                   sine=220:4:d=5
6835                   sine=f=220:b=4:d=5
6836                   sine=frequency=220:beep_factor=4:duration=5
6837
6838       •   Generate a 1 kHz sine wave following "1602,1601,1602,1601,1602"
6839           NTSC pattern:
6840
6841                   sine=1000:samples_per_frame='st(0,mod(n,5)); 1602-not(not(eq(ld(0),1)+eq(ld(0),3)))'
6842

AUDIO SINKS

6844       Below is a description of the currently available audio sinks.
6845
6846   abuffersink
6847       Buffer audio frames, and make them available to the end of filter
6848       chain.
6849
6850       This sink is mainly intended for programmatic use, in particular
6851       through the interface defined in libavfilter/buffersink.h or the
6852       options system.
6853
6854       It accepts a pointer to an AVABufferSinkContext structure, which
6855       defines the incoming buffers' formats, to be passed as the opaque
6856       parameter to "avfilter_init_filter" for initialization.
6857
6858   anullsink
6859       Null audio sink; do absolutely nothing with the input audio. It is
6860       mainly useful as a template and for use in analysis / debugging tools.
6861

VIDEO FILTERS

6863       When you configure your FFmpeg build, you can disable any of the
6864       existing filters using "--disable-filters".  The configure output will
6865       show the video filters included in your build.
6866
6867       Below is a description of the currently available video filters.
6868
6869   addroi
6870       Mark a region of interest in a video frame.
6871
6872       The frame data is passed through unchanged, but metadata is attached to
6873       the frame indicating regions of interest which can affect the behaviour
6874       of later encoding.  Multiple regions can be marked by applying the
6875       filter multiple times.
6876
6877       x   Region distance in pixels from the left edge of the frame.
6878
6879       y   Region distance in pixels from the top edge of the frame.
6880
6881       w   Region width in pixels.
6882
6883       h   Region height in pixels.
6884
6885           The parameters x, y, w and h are expressions, and may contain the
6886           following variables:
6887
6888           iw  Width of the input frame.
6889
6890           ih  Height of the input frame.
6891
6892       qoffset
6893           Quantisation offset to apply within the region.
6894
6895           This must be a real value in the range -1 to +1.  A value of zero
6896           indicates no quality change.  A negative value asks for better
6897           quality (less quantisation), while a positive value asks for worse
6898           quality (greater quantisation).
6899
6900           The range is calibrated so that the extreme values indicate the
6901           largest possible offset - if the rest of the frame is encoded with
6902           the worst possible quality, an offset of -1 indicates that this
6903           region should be encoded with the best possible quality anyway.
6904           Intermediate values are then interpolated in some codec-dependent
6905           way.
6906
6907           For example, in 10-bit H.264 the quantisation parameter varies
6908           between -12 and 51.  A typical qoffset value of -1/10 therefore
6909           indicates that this region should be encoded with a QP around one-
6910           tenth of the full range better than the rest of the frame.  So, if
6911           most of the frame were to be encoded with a QP of around 30, this
6912           region would get a QP of around 24 (an offset of approximately
6913           -1/10 * (51 - -12) = -6.3).  An extreme value of -1 would indicate
6914           that this region should be encoded with the best possible quality
6915           regardless of the treatment of the rest of the frame - that is,
6916           should be encoded at a QP of -12.
6917
6918       clear
6919           If set to true, remove any existing regions of interest marked on
6920           the frame before adding the new one.
6921
6922       Examples
6923
6924       •   Mark the centre quarter of the frame as interesting.
6925
6926                   addroi=iw/4:ih/4:iw/2:ih/2:-1/10
6927
6928       •   Mark the 100-pixel-wide region on the left edge of the frame as
6929           very uninteresting (to be encoded at much lower quality than the
6930           rest of the frame).
6931
6932                   addroi=0:0:100:ih:+1/5
6933
6934   alphaextract
6935       Extract the alpha component from the input as a grayscale video. This
6936       is especially useful with the alphamerge filter.
6937
6938   alphamerge
6939       Add or replace the alpha component of the primary input with the
6940       grayscale value of a second input. This is intended for use with
6941       alphaextract to allow the transmission or storage of frame sequences
6942       that have alpha in a format that doesn't support an alpha channel.
6943
6944       For example, to reconstruct full frames from a normal YUV-encoded video
6945       and a separate video created with alphaextract, you might use:
6946
6947               movie=in_alpha.mkv [alpha]; [in][alpha] alphamerge [out]
6948
6949   amplify
6950       Amplify differences between current pixel and pixels of adjacent frames
6951       in same pixel location.
6952
6953       This filter accepts the following options:
6954
6955       radius
6956           Set frame radius. Default is 2. Allowed range is from 1 to 63.  For
6957           example radius of 3 will instruct filter to calculate average of 7
6958           frames.
6959
6960       factor
6961           Set factor to amplify difference. Default is 2. Allowed range is
6962           from 0 to 65535.
6963
6964       threshold
6965           Set threshold for difference amplification. Any difference greater
6966           or equal to this value will not alter source pixel. Default is 10.
6967           Allowed range is from 0 to 65535.
6968
6969       tolerance
6970           Set tolerance for difference amplification. Any difference lower to
6971           this value will not alter source pixel. Default is 0.  Allowed
6972           range is from 0 to 65535.
6973
6974       low Set lower limit for changing source pixel. Default is 65535.
6975           Allowed range is from 0 to 65535.  This option controls maximum
6976           possible value that will decrease source pixel value.
6977
6978       high
6979           Set high limit for changing source pixel. Default is 65535. Allowed
6980           range is from 0 to 65535.  This option controls maximum possible
6981           value that will increase source pixel value.
6982
6983       planes
6984           Set which planes to filter. Default is all. Allowed range is from 0
6985           to 15.
6986
6987       Commands
6988
6989       This filter supports the following commands that corresponds to option
6990       of same name:
6991
6992       factor
6993       threshold
6994       tolerance
6995       low
6996       high
6997       planes
6998
6999   ass
7000       Same as the subtitles filter, except that it doesn't require libavcodec
7001       and libavformat to work. On the other hand, it is limited to ASS
7002       (Advanced Substation Alpha) subtitles files.
7003
7004       This filter accepts the following option in addition to the common
7005       options from the subtitles filter:
7006
7007       shaping
7008           Set the shaping engine
7009
7010           Available values are:
7011
7012           auto
7013               The default libass shaping engine, which is the best available.
7014
7015           simple
7016               Fast, font-agnostic shaper that can do only substitutions
7017
7018           complex
7019               Slower shaper using OpenType for substitutions and positioning
7020
7021           The default is "auto".
7022
7023   atadenoise
7024       Apply an Adaptive Temporal Averaging Denoiser to the video input.
7025
7026       The filter accepts the following options:
7027
7028       0a  Set threshold A for 1st plane. Default is 0.02.  Valid range is 0
7029           to 0.3.
7030
7031       0b  Set threshold B for 1st plane. Default is 0.04.  Valid range is 0
7032           to 5.
7033
7034       1a  Set threshold A for 2nd plane. Default is 0.02.  Valid range is 0
7035           to 0.3.
7036
7037       1b  Set threshold B for 2nd plane. Default is 0.04.  Valid range is 0
7038           to 5.
7039
7040       2a  Set threshold A for 3rd plane. Default is 0.02.  Valid range is 0
7041           to 0.3.
7042
7043       2b  Set threshold B for 3rd plane. Default is 0.04.  Valid range is 0
7044           to 5.
7045
7046           Threshold A is designed to react on abrupt changes in the input
7047           signal and threshold B is designed to react on continuous changes
7048           in the input signal.
7049
7050       s   Set number of frames filter will use for averaging. Default is 9.
7051           Must be odd number in range [5, 129].
7052
7053       p   Set what planes of frame filter will use for averaging. Default is
7054           all.
7055
7056       a   Set what variant of algorithm filter will use for averaging.
7057           Default is "p" parallel.  Alternatively can be set to "s" serial.
7058
7059           Parallel can be faster then serial, while other way around is never
7060           true.  Parallel will abort early on first change being greater then
7061           thresholds, while serial will continue processing other side of
7062           frames if they are equal or below thresholds.
7063
7064       0s
7065       1s
7066       2s  Set sigma for 1st plane, 2nd plane or 3rd plane. Default is 32767.
7067           Valid range is from 0 to 32767.  This options controls weight for
7068           each pixel in radius defined by size.  Default value means every
7069           pixel have same weight.  Setting this option to 0 effectively
7070           disables filtering.
7071
7072       Commands
7073
7074       This filter supports same commands as options except option "s".  The
7075       command accepts the same syntax of the corresponding option.
7076
7077   avgblur
7078       Apply average blur filter.
7079
7080       The filter accepts the following options:
7081
7082       sizeX
7083           Set horizontal radius size.
7084
7085       planes
7086           Set which planes to filter. By default all planes are filtered.
7087
7088       sizeY
7089           Set vertical radius size, if zero it will be same as "sizeX".
7090           Default is 0.
7091
7092       Commands
7093
7094       This filter supports same commands as options.  The command accepts the
7095       same syntax of the corresponding option.
7096
7097       If the specified expression is not valid, it is kept at its current
7098       value.
7099
7100   bbox
7101       Compute the bounding box for the non-black pixels in the input frame
7102       luminance plane.
7103
7104       This filter computes the bounding box containing all the pixels with a
7105       luminance value greater than the minimum allowed value.  The parameters
7106       describing the bounding box are printed on the filter log.
7107
7108       The filter accepts the following option:
7109
7110       min_val
7111           Set the minimal luminance value. Default is 16.
7112
7113       Commands
7114
7115       This filter supports the all above options as commands.
7116
7117   bilateral
7118       Apply bilateral filter, spatial smoothing while preserving edges.
7119
7120       The filter accepts the following options:
7121
7122       sigmaS
7123           Set sigma of gaussian function to calculate spatial weight.
7124           Allowed range is 0 to 512. Default is 0.1.
7125
7126       sigmaR
7127           Set sigma of gaussian function to calculate range weight.  Allowed
7128           range is 0 to 1. Default is 0.1.
7129
7130       planes
7131           Set planes to filter. Default is first only.
7132
7133       Commands
7134
7135       This filter supports the all above options as commands.
7136
7137   bitplanenoise
7138       Show and measure bit plane noise.
7139
7140       The filter accepts the following options:
7141
7142       bitplane
7143           Set which plane to analyze. Default is 1.
7144
7145       filter
7146           Filter out noisy pixels from "bitplane" set above.  Default is
7147           disabled.
7148
7149   blackdetect
7150       Detect video intervals that are (almost) completely black. Can be
7151       useful to detect chapter transitions, commercials, or invalid
7152       recordings.
7153
7154       The filter outputs its detection analysis to both the log as well as
7155       frame metadata. If a black segment of at least the specified minimum
7156       duration is found, a line with the start and end timestamps as well as
7157       duration is printed to the log with level "info". In addition, a log
7158       line with level "debug" is printed per frame showing the black amount
7159       detected for that frame.
7160
7161       The filter also attaches metadata to the first frame of a black segment
7162       with key "lavfi.black_start" and to the first frame after the black
7163       segment ends with key "lavfi.black_end". The value is the frame's
7164       timestamp. This metadata is added regardless of the minimum duration
7165       specified.
7166
7167       The filter accepts the following options:
7168
7169       black_min_duration, d
7170           Set the minimum detected black duration expressed in seconds. It
7171           must be a non-negative floating point number.
7172
7173           Default value is 2.0.
7174
7175       picture_black_ratio_th, pic_th
7176           Set the threshold for considering a picture "black".  Express the
7177           minimum value for the ratio:
7178
7179                   <nb_black_pixels> / <nb_pixels>
7180
7181           for which a picture is considered black.  Default value is 0.98.
7182
7183       pixel_black_th, pix_th
7184           Set the threshold for considering a pixel "black".
7185
7186           The threshold expresses the maximum pixel luminance value for which
7187           a pixel is considered "black". The provided value is scaled
7188           according to the following equation:
7189
7190                   <absolute_threshold> = <luminance_minimum_value> + <pixel_black_th> * <luminance_range_size>
7191
7192           luminance_range_size and luminance_minimum_value depend on the
7193           input video format, the range is [0-255] for YUV full-range formats
7194           and [16-235] for YUV non full-range formats.
7195
7196           Default value is 0.10.
7197
7198       The following example sets the maximum pixel threshold to the minimum
7199       value, and detects only black intervals of 2 or more seconds:
7200
7201               blackdetect=d=2:pix_th=0.00
7202
7203   blackframe
7204       Detect frames that are (almost) completely black. Can be useful to
7205       detect chapter transitions or commercials. Output lines consist of the
7206       frame number of the detected frame, the percentage of blackness, the
7207       position in the file if known or -1 and the timestamp in seconds.
7208
7209       In order to display the output lines, you need to set the loglevel at
7210       least to the AV_LOG_INFO value.
7211
7212       This filter exports frame metadata "lavfi.blackframe.pblack".  The
7213       value represents the percentage of pixels in the picture that are below
7214       the threshold value.
7215
7216       It accepts the following parameters:
7217
7218       amount
7219           The percentage of the pixels that have to be below the threshold;
7220           it defaults to 98.
7221
7222       threshold, thresh
7223           The threshold below which a pixel value is considered black; it
7224           defaults to 32.
7225
7226   blend
7227       Blend two video frames into each other.
7228
7229       The "blend" filter takes two input streams and outputs one stream, the
7230       first input is the "top" layer and second input is "bottom" layer.  By
7231       default, the output terminates when the longest input terminates.
7232
7233       The "tblend" (time blend) filter takes two consecutive frames from one
7234       single stream, and outputs the result obtained by blending the new
7235       frame on top of the old frame.
7236
7237       A description of the accepted options follows.
7238
7239       c0_mode
7240       c1_mode
7241       c2_mode
7242       c3_mode
7243       all_mode
7244           Set blend mode for specific pixel component or all pixel components
7245           in case of all_mode. Default value is "normal".
7246
7247           Available values for component modes are:
7248
7249           addition
7250           and
7251           average
7252           bleach
7253           burn
7254           darken
7255           difference
7256           divide
7257           dodge
7258           exclusion
7259           extremity
7260           freeze
7261           geometric
7262           glow
7263           grainextract
7264           grainmerge
7265           hardlight
7266           hardmix
7267           hardoverlay
7268           harmonic
7269           heat
7270           interpolate
7271           lighten
7272           linearlight
7273           multiply
7274           multiply128
7275           negation
7276           normal
7277           or
7278           overlay
7279           phoenix
7280           pinlight
7281           reflect
7282           screen
7283           softdifference
7284           softlight
7285           stain
7286           subtract
7287           vividlight
7288           xor
7289       c0_opacity
7290       c1_opacity
7291       c2_opacity
7292       c3_opacity
7293       all_opacity
7294           Set blend opacity for specific pixel component or all pixel
7295           components in case of all_opacity. Only used in combination with
7296           pixel component blend modes.
7297
7298       c0_expr
7299       c1_expr
7300       c2_expr
7301       c3_expr
7302       all_expr
7303           Set blend expression for specific pixel component or all pixel
7304           components in case of all_expr. Note that related mode options will
7305           be ignored if those are set.
7306
7307           The expressions can use the following variables:
7308
7309           N   The sequential number of the filtered frame, starting from 0.
7310
7311           X
7312           Y   the coordinates of the current sample
7313
7314           W
7315           H   the width and height of currently filtered plane
7316
7317           SW
7318           SH  Width and height scale for the plane being filtered. It is the
7319               ratio between the dimensions of the current plane to the luma
7320               plane, e.g. for a "yuv420p" frame, the values are "1,1" for the
7321               luma plane and "0.5,0.5" for the chroma planes.
7322
7323           T   Time of the current frame, expressed in seconds.
7324
7325           TOP, A
7326               Value of pixel component at current location for first video
7327               frame (top layer).
7328
7329           BOTTOM, B
7330               Value of pixel component at current location for second video
7331               frame (bottom layer).
7332
7333       The "blend" filter also supports the framesync options.
7334
7335       Examples
7336
7337       •   Apply transition from bottom layer to top layer in first 10
7338           seconds:
7339
7340                   blend=all_expr='A*(if(gte(T,10),1,T/10))+B*(1-(if(gte(T,10),1,T/10)))'
7341
7342       •   Apply linear horizontal transition from top layer to bottom layer:
7343
7344                   blend=all_expr='A*(X/W)+B*(1-X/W)'
7345
7346       •   Apply 1x1 checkerboard effect:
7347
7348                   blend=all_expr='if(eq(mod(X,2),mod(Y,2)),A,B)'
7349
7350       •   Apply uncover left effect:
7351
7352                   blend=all_expr='if(gte(N*SW+X,W),A,B)'
7353
7354       •   Apply uncover down effect:
7355
7356                   blend=all_expr='if(gte(Y-N*SH,0),A,B)'
7357
7358       •   Apply uncover up-left effect:
7359
7360                   blend=all_expr='if(gte(T*SH*40+Y,H)*gte((T*40*SW+X)*W/H,W),A,B)'
7361
7362       •   Split diagonally video and shows top and bottom layer on each side:
7363
7364                   blend=all_expr='if(gt(X,Y*(W/H)),A,B)'
7365
7366       •   Display differences between the current and the previous frame:
7367
7368                   tblend=all_mode=grainextract
7369
7370       Commands
7371
7372       This filter supports same commands as options.
7373
7374   blockdetect
7375       Determines blockiness of frames without altering the input frames.
7376
7377       Based on Remco Muijs and Ihor Kirenko: "A no-reference blocking
7378       artifact measure for adaptive video processing." 2005 13th European
7379       signal processing conference.
7380
7381       The filter accepts the following options:
7382
7383       period_min
7384       period_max
7385           Set minimum and maximum values for determining pixel grids
7386           (periods).  Default values are [3,24].
7387
7388       planes
7389           Set planes to filter. Default is first only.
7390
7391       Examples
7392
7393       •   Determine blockiness for the first plane and search for periods
7394           within [8,32]:
7395
7396                   blockdetect=period_min=8:period_max=32:planes=1
7397
7398   blurdetect
7399       Determines blurriness of frames without altering the input frames.
7400
7401       Based on Marziliano, Pina, et al. "A no-reference perceptual blur
7402       metric."  Allows for a block-based abbreviation.
7403
7404       The filter accepts the following options:
7405
7406       low
7407       high
7408           Set low and high threshold values used by the Canny thresholding
7409           algorithm.
7410
7411           The high threshold selects the "strong" edge pixels, which are then
7412           connected through 8-connectivity with the "weak" edge pixels
7413           selected by the low threshold.
7414
7415           low and high threshold values must be chosen in the range [0,1],
7416           and low should be lesser or equal to high.
7417
7418           Default value for low is "20/255", and default value for high is
7419           "50/255".
7420
7421       radius
7422           Define the radius to search around an edge pixel for local maxima.
7423
7424       block_pct
7425           Determine blurriness only for the most significant blocks, given in
7426           percentage.
7427
7428       block_width
7429           Determine blurriness for blocks of width block_width. If set to any
7430           value smaller 1, no blocks are used and the whole image is
7431           processed as one no matter of block_height.
7432
7433       block_height
7434           Determine blurriness for blocks of height block_height. If set to
7435           any value smaller 1, no blocks are used and the whole image is
7436           processed as one no matter of block_width.
7437
7438       planes
7439           Set planes to filter. Default is first only.
7440
7441       Examples
7442
7443       •   Determine blur for 80% of most significant 32x32 blocks:
7444
7445                   blurdetect=block_width=32:block_height=32:block_pct=80
7446
7447   bm3d
7448       Denoise frames using Block-Matching 3D algorithm.
7449
7450       The filter accepts the following options.
7451
7452       sigma
7453           Set denoising strength. Default value is 1.  Allowed range is from
7454           0 to 999.9.  The denoising algorithm is very sensitive to sigma, so
7455           adjust it according to the source.
7456
7457       block
7458           Set local patch size. This sets dimensions in 2D.
7459
7460       bstep
7461           Set sliding step for processing blocks. Default value is 4.
7462           Allowed range is from 1 to 64.  Smaller values allows processing
7463           more reference blocks and is slower.
7464
7465       group
7466           Set maximal number of similar blocks for 3rd dimension. Default
7467           value is 1.  When set to 1, no block matching is done. Larger
7468           values allows more blocks in single group.  Allowed range is from 1
7469           to 256.
7470
7471       range
7472           Set radius for search block matching. Default is 9.  Allowed range
7473           is from 1 to INT32_MAX.
7474
7475       mstep
7476           Set step between two search locations for block matching. Default
7477           is 1.  Allowed range is from 1 to 64. Smaller is slower.
7478
7479       thmse
7480           Set threshold of mean square error for block matching. Valid range
7481           is 0 to INT32_MAX.
7482
7483       hdthr
7484           Set thresholding parameter for hard thresholding in 3D transformed
7485           domain.  Larger values results in stronger hard-thresholding
7486           filtering in frequency domain.
7487
7488       estim
7489           Set filtering estimation mode. Can be "basic" or "final".  Default
7490           is "basic".
7491
7492       ref If enabled, filter will use 2nd stream for block matching.  Default
7493           is disabled for "basic" value of estim option, and always enabled
7494           if value of estim is "final".
7495
7496       planes
7497           Set planes to filter. Default is all available except alpha.
7498
7499       Examples
7500
7501       •   Basic filtering with bm3d:
7502
7503                   bm3d=sigma=3:block=4:bstep=2:group=1:estim=basic
7504
7505       •   Same as above, but filtering only luma:
7506
7507                   bm3d=sigma=3:block=4:bstep=2:group=1:estim=basic:planes=1
7508
7509       •   Same as above, but with both estimation modes:
7510
7511                   split[a][b],[a]bm3d=sigma=3:block=4:bstep=2:group=1:estim=basic[a],[b][a]bm3d=sigma=3:block=4:bstep=2:group=16:estim=final:ref=1
7512
7513       •   Same as above, but prefilter with nlmeans filter instead:
7514
7515                   split[a][b],[a]nlmeans=s=3:r=7:p=3[a],[b][a]bm3d=sigma=3:block=4:bstep=2:group=16:estim=final:ref=1
7516
7517   boxblur
7518       Apply a boxblur algorithm to the input video.
7519
7520       It accepts the following parameters:
7521
7522       luma_radius, lr
7523       luma_power, lp
7524       chroma_radius, cr
7525       chroma_power, cp
7526       alpha_radius, ar
7527       alpha_power, ap
7528
7529       A description of the accepted options follows.
7530
7531       luma_radius, lr
7532       chroma_radius, cr
7533       alpha_radius, ar
7534           Set an expression for the box radius in pixels used for blurring
7535           the corresponding input plane.
7536
7537           The radius value must be a non-negative number, and must not be
7538           greater than the value of the expression "min(w,h)/2" for the luma
7539           and alpha planes, and of "min(cw,ch)/2" for the chroma planes.
7540
7541           Default value for luma_radius is "2". If not specified,
7542           chroma_radius and alpha_radius default to the corresponding value
7543           set for luma_radius.
7544
7545           The expressions can contain the following constants:
7546
7547           w
7548           h   The input width and height in pixels.
7549
7550           cw
7551           ch  The input chroma image width and height in pixels.
7552
7553           hsub
7554           vsub
7555               The horizontal and vertical chroma subsample values. For
7556               example, for the pixel format "yuv422p", hsub is 2 and vsub is
7557               1.
7558
7559       luma_power, lp
7560       chroma_power, cp
7561       alpha_power, ap
7562           Specify how many times the boxblur filter is applied to the
7563           corresponding plane.
7564
7565           Default value for luma_power is 2. If not specified, chroma_power
7566           and alpha_power default to the corresponding value set for
7567           luma_power.
7568
7569           A value of 0 will disable the effect.
7570
7571       Examples
7572
7573       •   Apply a boxblur filter with the luma, chroma, and alpha radii set
7574           to 2:
7575
7576                   boxblur=luma_radius=2:luma_power=1
7577                   boxblur=2:1
7578
7579       •   Set the luma radius to 2, and alpha and chroma radius to 0:
7580
7581                   boxblur=2:1:cr=0:ar=0
7582
7583       •   Set the luma and chroma radii to a fraction of the video dimension:
7584
7585                   boxblur=luma_radius=min(h\,w)/10:luma_power=1:chroma_radius=min(cw\,ch)/10:chroma_power=1
7586
7587   bwdif
7588       Deinterlace the input video ("bwdif" stands for "Bob Weaver
7589       Deinterlacing Filter").
7590
7591       Motion adaptive deinterlacing based on yadif with the use of w3fdif and
7592       cubic interpolation algorithms.  It accepts the following parameters:
7593
7594       mode
7595           The interlacing mode to adopt. It accepts one of the following
7596           values:
7597
7598           0, send_frame
7599               Output one frame for each frame.
7600
7601           1, send_field
7602               Output one frame for each field.
7603
7604           The default value is "send_field".
7605
7606       parity
7607           The picture field parity assumed for the input interlaced video. It
7608           accepts one of the following values:
7609
7610           0, tff
7611               Assume the top field is first.
7612
7613           1, bff
7614               Assume the bottom field is first.
7615
7616           -1, auto
7617               Enable automatic detection of field parity.
7618
7619           The default value is "auto".  If the interlacing is unknown or the
7620           decoder does not export this information, top field first will be
7621           assumed.
7622
7623       deint
7624           Specify which frames to deinterlace. Accepts one of the following
7625           values:
7626
7627           0, all
7628               Deinterlace all frames.
7629
7630           1, interlaced
7631               Only deinterlace frames marked as interlaced.
7632
7633           The default value is "all".
7634
7635   cas
7636       Apply Contrast Adaptive Sharpen filter to video stream.
7637
7638       The filter accepts the following options:
7639
7640       strength
7641           Set the sharpening strength. Default value is 0.
7642
7643       planes
7644           Set planes to filter. Default value is to filter all planes except
7645           alpha plane.
7646
7647       Commands
7648
7649       This filter supports same commands as options.
7650
7651   chromahold
7652       Remove all color information for all colors except for certain one.
7653
7654       The filter accepts the following options:
7655
7656       color
7657           The color which will not be replaced with neutral chroma.
7658
7659       similarity
7660           Similarity percentage with the above color.  0.01 matches only the
7661           exact key color, while 1.0 matches everything.
7662
7663       blend
7664           Blend percentage.  0.0 makes pixels either fully gray, or not gray
7665           at all.  Higher values result in more preserved color.
7666
7667       yuv Signals that the color passed is already in YUV instead of RGB.
7668
7669           Literal colors like "green" or "red" don't make sense with this
7670           enabled anymore.  This can be used to pass exact YUV values as
7671           hexadecimal numbers.
7672
7673       Commands
7674
7675       This filter supports same commands as options.  The command accepts the
7676       same syntax of the corresponding option.
7677
7678       If the specified expression is not valid, it is kept at its current
7679       value.
7680
7681   chromakey
7682       YUV colorspace color/chroma keying.
7683
7684       The filter accepts the following options:
7685
7686       color
7687           The color which will be replaced with transparency.
7688
7689       similarity
7690           Similarity percentage with the key color.
7691
7692           0.01 matches only the exact key color, while 1.0 matches
7693           everything.
7694
7695       blend
7696           Blend percentage.
7697
7698           0.0 makes pixels either fully transparent, or not transparent at
7699           all.
7700
7701           Higher values result in semi-transparent pixels, with a higher
7702           transparency the more similar the pixels color is to the key color.
7703
7704       yuv Signals that the color passed is already in YUV instead of RGB.
7705
7706           Literal colors like "green" or "red" don't make sense with this
7707           enabled anymore.  This can be used to pass exact YUV values as
7708           hexadecimal numbers.
7709
7710       Commands
7711
7712       This filter supports same commands as options.  The command accepts the
7713       same syntax of the corresponding option.
7714
7715       If the specified expression is not valid, it is kept at its current
7716       value.
7717
7718       Examples
7719
7720       •   Make every green pixel in the input image transparent:
7721
7722                   ffmpeg -i input.png -vf chromakey=green out.png
7723
7724       •   Overlay a greenscreen-video on top of a static black background.
7725
7726                   ffmpeg -f lavfi -i color=c=black:s=1280x720 -i video.mp4 -shortest -filter_complex "[1:v]chromakey=0x70de77:0.1:0.2[ckout];[0:v][ckout]overlay[out]" -map "[out]" output.mkv
7727
7728   chromakey_cuda
7729       CUDA accelerated YUV colorspace color/chroma keying.
7730
7731       This filter works like normal chromakey filter but operates on CUDA
7732       frames.  for more details and parameters see chromakey.
7733
7734       Examples
7735
7736       •   Make all the green pixels in the input video transparent and use it
7737           as an overlay for another video:
7738
7739                   ./ffmpeg \
7740                       -hwaccel cuda -hwaccel_output_format cuda -i input_green.mp4  \
7741                       -hwaccel cuda -hwaccel_output_format cuda -i base_video.mp4 \
7742                       -init_hw_device cuda \
7743                       -filter_complex \
7744                       " \
7745                           [0:v]chromakey_cuda=0x25302D:0.1:0.12:1[overlay_video]; \
7746                           [1:v]scale_cuda=format=yuv420p[base]; \
7747                           [base][overlay_video]overlay_cuda" \
7748                       -an -sn -c:v h264_nvenc -cq 20 output.mp4
7749
7750       •   Process two software sources, explicitly uploading the frames:
7751
7752                   ./ffmpeg -init_hw_device cuda=cuda -filter_hw_device cuda \
7753                       -f lavfi -i color=size=800x600:color=white,format=yuv420p \
7754                       -f lavfi -i yuvtestsrc=size=200x200,format=yuv420p \
7755                       -filter_complex \
7756                       " \
7757                           [0]hwupload[under]; \
7758                           [1]hwupload,chromakey_cuda=green:0.1:0.12[over]; \
7759                           [under][over]overlay_cuda" \
7760                       -c:v hevc_nvenc -cq 18 -preset slow output.mp4
7761
7762   chromanr
7763       Reduce chrominance noise.
7764
7765       The filter accepts the following options:
7766
7767       thres
7768           Set threshold for averaging chrominance values.  Sum of absolute
7769           difference of Y, U and V pixel components of current pixel and
7770           neighbour pixels lower than this threshold will be used in
7771           averaging. Luma component is left unchanged and is copied to
7772           output.  Default value is 30. Allowed range is from 1 to 200.
7773
7774       sizew
7775           Set horizontal radius of rectangle used for averaging.  Allowed
7776           range is from 1 to 100. Default value is 5.
7777
7778       sizeh
7779           Set vertical radius of rectangle used for averaging.  Allowed range
7780           is from 1 to 100. Default value is 5.
7781
7782       stepw
7783           Set horizontal step when averaging. Default value is 1.  Allowed
7784           range is from 1 to 50.  Mostly useful to speed-up filtering.
7785
7786       steph
7787           Set vertical step when averaging. Default value is 1.  Allowed
7788           range is from 1 to 50.  Mostly useful to speed-up filtering.
7789
7790       threy
7791           Set Y threshold for averaging chrominance values.  Set finer
7792           control for max allowed difference between Y components of current
7793           pixel and neigbour pixels.  Default value is 200. Allowed range is
7794           from 1 to 200.
7795
7796       threu
7797           Set U threshold for averaging chrominance values.  Set finer
7798           control for max allowed difference between U components of current
7799           pixel and neigbour pixels.  Default value is 200. Allowed range is
7800           from 1 to 200.
7801
7802       threv
7803           Set V threshold for averaging chrominance values.  Set finer
7804           control for max allowed difference between V components of current
7805           pixel and neigbour pixels.  Default value is 200. Allowed range is
7806           from 1 to 200.
7807
7808       distance
7809           Set distance type used in calculations.
7810
7811           manhattan
7812               Absolute difference.
7813
7814           euclidean
7815               Difference squared.
7816
7817           Default distance type is manhattan.
7818
7819       Commands
7820
7821       This filter supports same commands as options.  The command accepts the
7822       same syntax of the corresponding option.
7823
7824   chromashift
7825       Shift chroma pixels horizontally and/or vertically.
7826
7827       The filter accepts the following options:
7828
7829       cbh Set amount to shift chroma-blue horizontally.
7830
7831       cbv Set amount to shift chroma-blue vertically.
7832
7833       crh Set amount to shift chroma-red horizontally.
7834
7835       crv Set amount to shift chroma-red vertically.
7836
7837       edge
7838           Set edge mode, can be smear, default, or warp.
7839
7840       Commands
7841
7842       This filter supports the all above options as commands.
7843
7844   ciescope
7845       Display CIE color diagram with pixels overlaid onto it.
7846
7847       The filter accepts the following options:
7848
7849       system
7850           Set color system.
7851
7852           ntsc, 470m
7853           ebu, 470bg
7854           smpte
7855           240m
7856           apple
7857           widergb
7858           cie1931
7859           rec709, hdtv
7860           uhdtv, rec2020
7861           dcip3
7862       cie Set CIE system.
7863
7864           xyy
7865           ucs
7866           luv
7867       gamuts
7868           Set what gamuts to draw.
7869
7870           See "system" option for available values.
7871
7872       size, s
7873           Set ciescope size, by default set to 512.
7874
7875       intensity, i
7876           Set intensity used to map input pixel values to CIE diagram.
7877
7878       contrast
7879           Set contrast used to draw tongue colors that are out of active
7880           color system gamut.
7881
7882       corrgamma
7883           Correct gamma displayed on scope, by default enabled.
7884
7885       showwhite
7886           Show white point on CIE diagram, by default disabled.
7887
7888       gamma
7889           Set input gamma. Used only with XYZ input color space.
7890
7891       fill
7892           Fill with CIE colors. By default is enabled.
7893
7894   codecview
7895       Visualize information exported by some codecs.
7896
7897       Some codecs can export information through frames using side-data or
7898       other means. For example, some MPEG based codecs export motion vectors
7899       through the export_mvs flag in the codec flags2 option.
7900
7901       The filter accepts the following option:
7902
7903       block
7904           Display block partition structure using the luma plane.
7905
7906       mv  Set motion vectors to visualize.
7907
7908           Available flags for mv are:
7909
7910           pf  forward predicted MVs of P-frames
7911
7912           bf  forward predicted MVs of B-frames
7913
7914           bb  backward predicted MVs of B-frames
7915
7916       qp  Display quantization parameters using the chroma planes.
7917
7918       mv_type, mvt
7919           Set motion vectors type to visualize. Includes MVs from all frames
7920           unless specified by frame_type option.
7921
7922           Available flags for mv_type are:
7923
7924           fp  forward predicted MVs
7925
7926           bp  backward predicted MVs
7927
7928       frame_type, ft
7929           Set frame type to visualize motion vectors of.
7930
7931           Available flags for frame_type are:
7932
7933           if  intra-coded frames (I-frames)
7934
7935           pf  predicted frames (P-frames)
7936
7937           bf  bi-directionally predicted frames (B-frames)
7938
7939       Examples
7940
7941       •   Visualize forward predicted MVs of all frames using ffplay:
7942
7943                   ffplay -flags2 +export_mvs input.mp4 -vf codecview=mv_type=fp
7944
7945       •   Visualize multi-directionals MVs of P and B-Frames using ffplay:
7946
7947                   ffplay -flags2 +export_mvs input.mp4 -vf codecview=mv=pf+bf+bb
7948
7949   colorbalance
7950       Modify intensity of primary colors (red, green and blue) of input
7951       frames.
7952
7953       The filter allows an input frame to be adjusted in the shadows,
7954       midtones or highlights regions for the red-cyan, green-magenta or blue-
7955       yellow balance.
7956
7957       A positive adjustment value shifts the balance towards the primary
7958       color, a negative value towards the complementary color.
7959
7960       The filter accepts the following options:
7961
7962       rs
7963       gs
7964       bs  Adjust red, green and blue shadows (darkest pixels).
7965
7966       rm
7967       gm
7968       bm  Adjust red, green and blue midtones (medium pixels).
7969
7970       rh
7971       gh
7972       bh  Adjust red, green and blue highlights (brightest pixels).
7973
7974           Allowed ranges for options are "[-1.0, 1.0]". Defaults are 0.
7975
7976       pl  Preserve lightness when changing color balance. Default is
7977           disabled.
7978
7979       Examples
7980
7981       •   Add red color cast to shadows:
7982
7983                   colorbalance=rs=.3
7984
7985       Commands
7986
7987       This filter supports the all above options as commands.
7988
7989   colorcontrast
7990       Adjust color contrast between RGB components.
7991
7992       The filter accepts the following options:
7993
7994       rc  Set the red-cyan contrast. Defaults is 0.0. Allowed range is from
7995           -1.0 to 1.0.
7996
7997       gm  Set the green-magenta contrast. Defaults is 0.0. Allowed range is
7998           from -1.0 to 1.0.
7999
8000       by  Set the blue-yellow contrast. Defaults is 0.0. Allowed range is
8001           from -1.0 to 1.0.
8002
8003       rcw
8004       gmw
8005       byw Set the weight of each "rc", "gm", "by" option value. Default value
8006           is 0.0.  Allowed range is from 0.0 to 1.0. If all weights are 0.0
8007           filtering is disabled.
8008
8009       pl  Set the amount of preserving lightness. Default value is 0.0.
8010           Allowed range is from 0.0 to 1.0.
8011
8012       Commands
8013
8014       This filter supports the all above options as commands.
8015
8016   colorcorrect
8017       Adjust color white balance selectively for blacks and whites.  This
8018       filter operates in YUV colorspace.
8019
8020       The filter accepts the following options:
8021
8022       rl  Set the red shadow spot. Allowed range is from -1.0 to 1.0.
8023           Default value is 0.
8024
8025       bl  Set the blue shadow spot. Allowed range is from -1.0 to 1.0.
8026           Default value is 0.
8027
8028       rh  Set the red highlight spot. Allowed range is from -1.0 to 1.0.
8029           Default value is 0.
8030
8031       bh  Set the red highlight spot. Allowed range is from -1.0 to 1.0.
8032           Default value is 0.
8033
8034       saturation
8035           Set the amount of saturation. Allowed range is from -3.0 to 3.0.
8036           Default value is 1.
8037
8038       analyze
8039           If set to anything other than "manual" it will analyze every frame
8040           and use derived parameters for filtering output frame.
8041
8042           Possible values are:
8043
8044           manual
8045           average
8046           minmax
8047           median
8048
8049           Default value is "manual".
8050
8051       Commands
8052
8053       This filter supports the all above options as commands.
8054
8055   colorchannelmixer
8056       Adjust video input frames by re-mixing color channels.
8057
8058       This filter modifies a color channel by adding the values associated to
8059       the other channels of the same pixels. For example if the value to
8060       modify is red, the output value will be:
8061
8062               <red>=<red>*<rr> + <blue>*<rb> + <green>*<rg> + <alpha>*<ra>
8063
8064       The filter accepts the following options:
8065
8066       rr
8067       rg
8068       rb
8069       ra  Adjust contribution of input red, green, blue and alpha channels
8070           for output red channel.  Default is 1 for rr, and 0 for rg, rb and
8071           ra.
8072
8073       gr
8074       gg
8075       gb
8076       ga  Adjust contribution of input red, green, blue and alpha channels
8077           for output green channel.  Default is 1 for gg, and 0 for gr, gb
8078           and ga.
8079
8080       br
8081       bg
8082       bb
8083       ba  Adjust contribution of input red, green, blue and alpha channels
8084           for output blue channel.  Default is 1 for bb, and 0 for br, bg and
8085           ba.
8086
8087       ar
8088       ag
8089       ab
8090       aa  Adjust contribution of input red, green, blue and alpha channels
8091           for output alpha channel.  Default is 1 for aa, and 0 for ar, ag
8092           and ab.
8093
8094           Allowed ranges for options are "[-2.0, 2.0]".
8095
8096       pc  Set preserve color mode. The accepted values are:
8097
8098           none
8099               Disable color preserving, this is default.
8100
8101           lum Preserve luminance.
8102
8103           max Preserve max value of RGB triplet.
8104
8105           avg Preserve average value of RGB triplet.
8106
8107           sum Preserve sum value of RGB triplet.
8108
8109           nrm Preserve normalized value of RGB triplet.
8110
8111           pwr Preserve power value of RGB triplet.
8112
8113       pa  Set the preserve color amount when changing colors. Allowed range
8114           is from "[0.0, 1.0]".  Default is 0.0, thus disabled.
8115
8116       Examples
8117
8118       •   Convert source to grayscale:
8119
8120                   colorchannelmixer=.3:.4:.3:0:.3:.4:.3:0:.3:.4:.3
8121
8122       •   Simulate sepia tones:
8123
8124                   colorchannelmixer=.393:.769:.189:0:.349:.686:.168:0:.272:.534:.131
8125
8126       Commands
8127
8128       This filter supports the all above options as commands.
8129
8130   colorize
8131       Overlay a solid color on the video stream.
8132
8133       The filter accepts the following options:
8134
8135       hue Set the color hue. Allowed range is from 0 to 360.  Default value
8136           is 0.
8137
8138       saturation
8139           Set the color saturation. Allowed range is from 0 to 1.  Default
8140           value is 0.5.
8141
8142       lightness
8143           Set the color lightness. Allowed range is from 0 to 1.  Default
8144           value is 0.5.
8145
8146       mix Set the mix of source lightness. By default is set to 1.0.  Allowed
8147           range is from 0.0 to 1.0.
8148
8149       Commands
8150
8151       This filter supports the all above options as commands.
8152
8153   colorkey
8154       RGB colorspace color keying.  This filter operates on 8-bit RGB format
8155       frames by setting the alpha component of each pixel which falls within
8156       the similarity radius of the key color to 0. The alpha value for pixels
8157       outside the similarity radius depends on the value of the blend option.
8158
8159       The filter accepts the following options:
8160
8161       color
8162           Set the color for which alpha will be set to 0 (full transparency).
8163           See "Color" section in the ffmpeg-utils manual.  Default is
8164           "black".
8165
8166       similarity
8167           Set the radius from the key color within which other colors also
8168           have full transparency.  The computed distance is related to the
8169           unit fractional distance in 3D space between the RGB values of the
8170           key color and the pixel's color. Range is 0.01 to 1.0. 0.01 matches
8171           within a very small radius around the exact key color, while 1.0
8172           matches everything.  Default is 0.01.
8173
8174       blend
8175           Set how the alpha value for pixels that fall outside the similarity
8176           radius is computed.  0.0 makes pixels either fully transparent or
8177           fully opaque.  Higher values result in semi-transparent pixels,
8178           with greater transparency the more similar the pixel color is to
8179           the key color.  Range is 0.0 to 1.0. Default is 0.0.
8180
8181       Examples
8182
8183       •   Make every green pixel in the input image transparent:
8184
8185                   ffmpeg -i input.png -vf colorkey=green out.png
8186
8187       •   Overlay a greenscreen-video on top of a static background image.
8188
8189                   ffmpeg -i background.png -i video.mp4 -filter_complex "[1:v]colorkey=0x3BBD1E:0.3:0.2[ckout];[0:v][ckout]overlay[out]" -map "[out]" output.flv
8190
8191       Commands
8192
8193       This filter supports same commands as options.  The command accepts the
8194       same syntax of the corresponding option.
8195
8196       If the specified expression is not valid, it is kept at its current
8197       value.
8198
8199   colorhold
8200       Remove all color information for all RGB colors except for certain one.
8201
8202       The filter accepts the following options:
8203
8204       color
8205           The color which will not be replaced with neutral gray.
8206
8207       similarity
8208           Similarity percentage with the above color.  0.01 matches only the
8209           exact key color, while 1.0 matches everything.
8210
8211       blend
8212           Blend percentage. 0.0 makes pixels fully gray.  Higher values
8213           result in more preserved color.
8214
8215       Commands
8216
8217       This filter supports same commands as options.  The command accepts the
8218       same syntax of the corresponding option.
8219
8220       If the specified expression is not valid, it is kept at its current
8221       value.
8222
8223   colorlevels
8224       Adjust video input frames using levels.
8225
8226       The filter accepts the following options:
8227
8228       rimin
8229       gimin
8230       bimin
8231       aimin
8232           Adjust red, green, blue and alpha input black point.  Allowed
8233           ranges for options are "[-1.0, 1.0]". Defaults are 0.
8234
8235       rimax
8236       gimax
8237       bimax
8238       aimax
8239           Adjust red, green, blue and alpha input white point.  Allowed
8240           ranges for options are "[-1.0, 1.0]". Defaults are 1.
8241
8242           Input levels are used to lighten highlights (bright tones), darken
8243           shadows (dark tones), change the balance of bright and dark tones.
8244
8245       romin
8246       gomin
8247       bomin
8248       aomin
8249           Adjust red, green, blue and alpha output black point.  Allowed
8250           ranges for options are "[0, 1.0]". Defaults are 0.
8251
8252       romax
8253       gomax
8254       bomax
8255       aomax
8256           Adjust red, green, blue and alpha output white point.  Allowed
8257           ranges for options are "[0, 1.0]". Defaults are 1.
8258
8259           Output levels allows manual selection of a constrained output level
8260           range.
8261
8262       preserve
8263           Set preserve color mode. The accepted values are:
8264
8265           none
8266               Disable color preserving, this is default.
8267
8268           lum Preserve luminance.
8269
8270           max Preserve max value of RGB triplet.
8271
8272           avg Preserve average value of RGB triplet.
8273
8274           sum Preserve sum value of RGB triplet.
8275
8276           nrm Preserve normalized value of RGB triplet.
8277
8278           pwr Preserve power value of RGB triplet.
8279
8280       Examples
8281
8282       •   Make video output darker:
8283
8284                   colorlevels=rimin=0.058:gimin=0.058:bimin=0.058
8285
8286       •   Increase contrast:
8287
8288                   colorlevels=rimin=0.039:gimin=0.039:bimin=0.039:rimax=0.96:gimax=0.96:bimax=0.96
8289
8290       •   Make video output lighter:
8291
8292                   colorlevels=rimax=0.902:gimax=0.902:bimax=0.902
8293
8294       •   Increase brightness:
8295
8296                   colorlevels=romin=0.5:gomin=0.5:bomin=0.5
8297
8298       Commands
8299
8300       This filter supports the all above options as commands.
8301
8302   colormap
8303       Apply custom color maps to video stream.
8304
8305       This filter needs three input video streams.  First stream is video
8306       stream that is going to be filtered out.  Second and third video stream
8307       specify color patches for source color to target color mapping.
8308
8309       The filter accepts the following options:
8310
8311       patch_size
8312           Set the source and target video stream patch size in pixels.
8313
8314       nb_patches
8315           Set the max number of used patches from source and target video
8316           stream.  Default value is number of patches available in additional
8317           video streams.  Max allowed number of patches is 64.
8318
8319       type
8320           Set the adjustments used for target colors. Can be "relative" or
8321           "absolute".  Defaults is "absolute".
8322
8323       kernel
8324           Set the kernel used to measure color differences between mapped
8325           colors.
8326
8327           The accepted values are:
8328
8329           euclidean
8330           weuclidean
8331
8332           Default is "euclidean".
8333
8334   colormatrix
8335       Convert color matrix.
8336
8337       The filter accepts the following options:
8338
8339       src
8340       dst Specify the source and destination color matrix. Both values must
8341           be specified.
8342
8343           The accepted values are:
8344
8345           bt709
8346               BT.709
8347
8348           fcc FCC
8349
8350           bt601
8351               BT.601
8352
8353           bt470
8354               BT.470
8355
8356           bt470bg
8357               BT.470BG
8358
8359           smpte170m
8360               SMPTE-170M
8361
8362           smpte240m
8363               SMPTE-240M
8364
8365           bt2020
8366               BT.2020
8367
8368       For example to convert from BT.601 to SMPTE-240M, use the command:
8369
8370               colormatrix=bt601:smpte240m
8371
8372   colorspace
8373       Convert colorspace, transfer characteristics or color primaries.  Input
8374       video needs to have an even size.
8375
8376       The filter accepts the following options:
8377
8378       all Specify all color properties at once.
8379
8380           The accepted values are:
8381
8382           bt470m
8383               BT.470M
8384
8385           bt470bg
8386               BT.470BG
8387
8388           bt601-6-525
8389               BT.601-6 525
8390
8391           bt601-6-625
8392               BT.601-6 625
8393
8394           bt709
8395               BT.709
8396
8397           smpte170m
8398               SMPTE-170M
8399
8400           smpte240m
8401               SMPTE-240M
8402
8403           bt2020
8404               BT.2020
8405
8406       space
8407           Specify output colorspace.
8408
8409           The accepted values are:
8410
8411           bt709
8412               BT.709
8413
8414           fcc FCC
8415
8416           bt470bg
8417               BT.470BG or BT.601-6 625
8418
8419           smpte170m
8420               SMPTE-170M or BT.601-6 525
8421
8422           smpte240m
8423               SMPTE-240M
8424
8425           ycgco
8426               YCgCo
8427
8428           bt2020ncl
8429               BT.2020 with non-constant luminance
8430
8431       trc Specify output transfer characteristics.
8432
8433           The accepted values are:
8434
8435           bt709
8436               BT.709
8437
8438           bt470m
8439               BT.470M
8440
8441           bt470bg
8442               BT.470BG
8443
8444           gamma22
8445               Constant gamma of 2.2
8446
8447           gamma28
8448               Constant gamma of 2.8
8449
8450           smpte170m
8451               SMPTE-170M, BT.601-6 625 or BT.601-6 525
8452
8453           smpte240m
8454               SMPTE-240M
8455
8456           srgb
8457               SRGB
8458
8459           iec61966-2-1
8460               iec61966-2-1
8461
8462           iec61966-2-4
8463               iec61966-2-4
8464
8465           xvycc
8466               xvycc
8467
8468           bt2020-10
8469               BT.2020 for 10-bits content
8470
8471           bt2020-12
8472               BT.2020 for 12-bits content
8473
8474       primaries
8475           Specify output color primaries.
8476
8477           The accepted values are:
8478
8479           bt709
8480               BT.709
8481
8482           bt470m
8483               BT.470M
8484
8485           bt470bg
8486               BT.470BG or BT.601-6 625
8487
8488           smpte170m
8489               SMPTE-170M or BT.601-6 525
8490
8491           smpte240m
8492               SMPTE-240M
8493
8494           film
8495               film
8496
8497           smpte431
8498               SMPTE-431
8499
8500           smpte432
8501               SMPTE-432
8502
8503           bt2020
8504               BT.2020
8505
8506           jedec-p22
8507               JEDEC P22 phosphors
8508
8509       range
8510           Specify output color range.
8511
8512           The accepted values are:
8513
8514           tv  TV (restricted) range
8515
8516           mpeg
8517               MPEG (restricted) range
8518
8519           pc  PC (full) range
8520
8521           jpeg
8522               JPEG (full) range
8523
8524       format
8525           Specify output color format.
8526
8527           The accepted values are:
8528
8529           yuv420p
8530               YUV 4:2:0 planar 8-bits
8531
8532           yuv420p10
8533               YUV 4:2:0 planar 10-bits
8534
8535           yuv420p12
8536               YUV 4:2:0 planar 12-bits
8537
8538           yuv422p
8539               YUV 4:2:2 planar 8-bits
8540
8541           yuv422p10
8542               YUV 4:2:2 planar 10-bits
8543
8544           yuv422p12
8545               YUV 4:2:2 planar 12-bits
8546
8547           yuv444p
8548               YUV 4:4:4 planar 8-bits
8549
8550           yuv444p10
8551               YUV 4:4:4 planar 10-bits
8552
8553           yuv444p12
8554               YUV 4:4:4 planar 12-bits
8555
8556       fast
8557           Do a fast conversion, which skips gamma/primary correction. This
8558           will take significantly less CPU, but will be mathematically
8559           incorrect. To get output compatible with that produced by the
8560           colormatrix filter, use fast=1.
8561
8562       dither
8563           Specify dithering mode.
8564
8565           The accepted values are:
8566
8567           none
8568               No dithering
8569
8570           fsb Floyd-Steinberg dithering
8571
8572       wpadapt
8573           Whitepoint adaptation mode.
8574
8575           The accepted values are:
8576
8577           bradford
8578               Bradford whitepoint adaptation
8579
8580           vonkries
8581               von Kries whitepoint adaptation
8582
8583           identity
8584               identity whitepoint adaptation (i.e. no whitepoint adaptation)
8585
8586       iall
8587           Override all input properties at once. Same accepted values as all.
8588
8589       ispace
8590           Override input colorspace. Same accepted values as space.
8591
8592       iprimaries
8593           Override input color primaries. Same accepted values as primaries.
8594
8595       itrc
8596           Override input transfer characteristics. Same accepted values as
8597           trc.
8598
8599       irange
8600           Override input color range. Same accepted values as range.
8601
8602       The filter converts the transfer characteristics, color space and color
8603       primaries to the specified user values. The output value, if not
8604       specified, is set to a default value based on the "all" property. If
8605       that property is also not specified, the filter will log an error. The
8606       output color range and format default to the same value as the input
8607       color range and format. The input transfer characteristics, color
8608       space, color primaries and color range should be set on the input data.
8609       If any of these are missing, the filter will log an error and no
8610       conversion will take place.
8611
8612       For example to convert the input to SMPTE-240M, use the command:
8613
8614               colorspace=smpte240m
8615
8616   colortemperature
8617       Adjust color temperature in video to simulate variations in ambient
8618       color temperature.
8619
8620       The filter accepts the following options:
8621
8622       temperature
8623           Set the temperature in Kelvin. Allowed range is from 1000 to 40000.
8624           Default value is 6500 K.
8625
8626       mix Set mixing with filtered output. Allowed range is from 0 to 1.
8627           Default value is 1.
8628
8629       pl  Set the amount of preserving lightness. Allowed range is from 0 to
8630           1.  Default value is 0.
8631
8632       Commands
8633
8634       This filter supports same commands as options.
8635
8636   convolution
8637       Apply convolution of 3x3, 5x5, 7x7 or horizontal/vertical up to 49
8638       elements.
8639
8640       The filter accepts the following options:
8641
8642       0m
8643       1m
8644       2m
8645       3m  Set matrix for each plane.  Matrix is sequence of 9, 25 or 49
8646           signed integers in square mode, and from 1 to 49 odd number of
8647           signed integers in row mode.
8648
8649       0rdiv
8650       1rdiv
8651       2rdiv
8652       3rdiv
8653           Set multiplier for calculated value for each plane.  If unset or 0,
8654           it will be sum of all matrix elements.
8655
8656       0bias
8657       1bias
8658       2bias
8659       3bias
8660           Set bias for each plane. This value is added to the result of the
8661           multiplication.  Useful for making the overall image brighter or
8662           darker. Default is 0.0.
8663
8664       0mode
8665       1mode
8666       2mode
8667       3mode
8668           Set matrix mode for each plane. Can be square, row or column.
8669           Default is square.
8670
8671       Commands
8672
8673       This filter supports the all above options as commands.
8674
8675       Examples
8676
8677       •   Apply sharpen:
8678
8679                   convolution="0 -1 0 -1 5 -1 0 -1 0:0 -1 0 -1 5 -1 0 -1 0:0 -1 0 -1 5 -1 0 -1 0:0 -1 0 -1 5 -1 0 -1 0"
8680
8681       •   Apply blur:
8682
8683                   convolution="1 1 1 1 1 1 1 1 1:1 1 1 1 1 1 1 1 1:1 1 1 1 1 1 1 1 1:1 1 1 1 1 1 1 1 1:1/9:1/9:1/9:1/9"
8684
8685       •   Apply edge enhance:
8686
8687                   convolution="0 0 0 -1 1 0 0 0 0:0 0 0 -1 1 0 0 0 0:0 0 0 -1 1 0 0 0 0:0 0 0 -1 1 0 0 0 0:5:1:1:1:0:128:128:128"
8688
8689       •   Apply edge detect:
8690
8691                   convolution="0 1 0 1 -4 1 0 1 0:0 1 0 1 -4 1 0 1 0:0 1 0 1 -4 1 0 1 0:0 1 0 1 -4 1 0 1 0:5:5:5:1:0:128:128:128"
8692
8693       •   Apply laplacian edge detector which includes diagonals:
8694
8695                   convolution="1 1 1 1 -8 1 1 1 1:1 1 1 1 -8 1 1 1 1:1 1 1 1 -8 1 1 1 1:1 1 1 1 -8 1 1 1 1:5:5:5:1:0:128:128:0"
8696
8697       •   Apply emboss:
8698
8699                   convolution="-2 -1 0 -1 1 1 0 1 2:-2 -1 0 -1 1 1 0 1 2:-2 -1 0 -1 1 1 0 1 2:-2 -1 0 -1 1 1 0 1 2"
8700
8701   convolve
8702       Apply 2D convolution of video stream in frequency domain using second
8703       stream as impulse.
8704
8705       The filter accepts the following options:
8706
8707       planes
8708           Set which planes to process.
8709
8710       impulse
8711           Set which impulse video frames will be processed, can be first or
8712           all. Default is all.
8713
8714       The "convolve" filter also supports the framesync options.
8715
8716   copy
8717       Copy the input video source unchanged to the output. This is mainly
8718       useful for testing purposes.
8719
8720   coreimage
8721       Video filtering on GPU using Apple's CoreImage API on OSX.
8722
8723       Hardware acceleration is based on an OpenGL context. Usually, this
8724       means it is processed by video hardware. However, software-based OpenGL
8725       implementations exist which means there is no guarantee for hardware
8726       processing. It depends on the respective OSX.
8727
8728       There are many filters and image generators provided by Apple that come
8729       with a large variety of options. The filter has to be referenced by its
8730       name along with its options.
8731
8732       The coreimage filter accepts the following options:
8733
8734       list_filters
8735           List all available filters and generators along with all their
8736           respective options as well as possible minimum and maximum values
8737           along with the default values.
8738
8739                   list_filters=true
8740
8741       filter
8742           Specify all filters by their respective name and options.  Use
8743           list_filters to determine all valid filter names and options.
8744           Numerical options are specified by a float value and are
8745           automatically clamped to their respective value range.  Vector and
8746           color options have to be specified by a list of space separated
8747           float values. Character escaping has to be done.  A special option
8748           name "default" is available to use default options for a filter.
8749
8750           It is required to specify either "default" or at least one of the
8751           filter options.  All omitted options are used with their default
8752           values.  The syntax of the filter string is as follows:
8753
8754                   filter=<NAME>@<OPTION>=<VALUE>[@<OPTION>=<VALUE>][@...][#<NAME>@<OPTION>=<VALUE>[@<OPTION>=<VALUE>][@...]][#...]
8755
8756       output_rect
8757           Specify a rectangle where the output of the filter chain is copied
8758           into the input image. It is given by a list of space separated
8759           float values:
8760
8761                   output_rect=x\ y\ width\ height
8762
8763           If not given, the output rectangle equals the dimensions of the
8764           input image.  The output rectangle is automatically cropped at the
8765           borders of the input image. Negative values are valid for each
8766           component.
8767
8768                   output_rect=25\ 25\ 100\ 100
8769
8770       Several filters can be chained for successive processing without GPU-
8771       HOST transfers allowing for fast processing of complex filter chains.
8772       Currently, only filters with zero (generators) or exactly one (filters)
8773       input image and one output image are supported. Also, transition
8774       filters are not yet usable as intended.
8775
8776       Some filters generate output images with additional padding depending
8777       on the respective filter kernel. The padding is automatically removed
8778       to ensure the filter output has the same size as the input image.
8779
8780       For image generators, the size of the output image is determined by the
8781       previous output image of the filter chain or the input image of the
8782       whole filterchain, respectively. The generators do not use the pixel
8783       information of this image to generate their output. However, the
8784       generated output is blended onto this image, resulting in partial or
8785       complete coverage of the output image.
8786
8787       The coreimagesrc video source can be used for generating input images
8788       which are directly fed into the filter chain. By using it, providing
8789       input images by another video source or an input video is not required.
8790
8791       Examples
8792
8793       •   List all filters available:
8794
8795                   coreimage=list_filters=true
8796
8797       •   Use the CIBoxBlur filter with default options to blur an image:
8798
8799                   coreimage=filter=CIBoxBlur@default
8800
8801       •   Use a filter chain with CISepiaTone at default values and
8802           CIVignetteEffect with its center at 100x100 and a radius of 50
8803           pixels:
8804
8805                   coreimage=filter=CIBoxBlur@default#CIVignetteEffect@inputCenter=100\ 100@inputRadius=50
8806
8807       •   Use nullsrc and CIQRCodeGenerator to create a QR code for the
8808           FFmpeg homepage, given as complete and escaped command-line for
8809           Apple's standard bash shell:
8810
8811                   ffmpeg -f lavfi -i nullsrc=s=100x100,coreimage=filter=CIQRCodeGenerator@inputMessage=https\\\\\://FFmpeg.org/@inputCorrectionLevel=H -frames:v 1 QRCode.png
8812
8813   cover_rect
8814       Cover a rectangular object
8815
8816       It accepts the following options:
8817
8818       cover
8819           Filepath of the optional cover image, needs to be in yuv420.
8820
8821       mode
8822           Set covering mode.
8823
8824           It accepts the following values:
8825
8826           cover
8827               cover it by the supplied image
8828
8829           blur
8830               cover it by interpolating the surrounding pixels
8831
8832           Default value is blur.
8833
8834       Examples
8835
8836       •   Cover a rectangular object by the supplied image of a given video
8837           using ffmpeg:
8838
8839                   ffmpeg -i file.ts -vf find_rect=newref.pgm,cover_rect=cover.jpg:mode=cover new.mkv
8840
8841   crop
8842       Crop the input video to given dimensions.
8843
8844       It accepts the following parameters:
8845
8846       w, out_w
8847           The width of the output video. It defaults to "iw".  This
8848           expression is evaluated only once during the filter configuration,
8849           or when the w or out_w command is sent.
8850
8851       h, out_h
8852           The height of the output video. It defaults to "ih".  This
8853           expression is evaluated only once during the filter configuration,
8854           or when the h or out_h command is sent.
8855
8856       x   The horizontal position, in the input video, of the left edge of
8857           the output video. It defaults to "(in_w-out_w)/2".  This expression
8858           is evaluated per-frame.
8859
8860       y   The vertical position, in the input video, of the top edge of the
8861           output video.  It defaults to "(in_h-out_h)/2".  This expression is
8862           evaluated per-frame.
8863
8864       keep_aspect
8865           If set to 1 will force the output display aspect ratio to be the
8866           same of the input, by changing the output sample aspect ratio. It
8867           defaults to 0.
8868
8869       exact
8870           Enable exact cropping. If enabled, subsampled videos will be
8871           cropped at exact width/height/x/y as specified and will not be
8872           rounded to nearest smaller value.  It defaults to 0.
8873
8874       The out_w, out_h, x, y parameters are expressions containing the
8875       following constants:
8876
8877       x
8878       y   The computed values for x and y. They are evaluated for each new
8879           frame.
8880
8881       in_w
8882       in_h
8883           The input width and height.
8884
8885       iw
8886       ih  These are the same as in_w and in_h.
8887
8888       out_w
8889       out_h
8890           The output (cropped) width and height.
8891
8892       ow
8893       oh  These are the same as out_w and out_h.
8894
8895       a   same as iw / ih
8896
8897       sar input sample aspect ratio
8898
8899       dar input display aspect ratio, it is the same as (iw / ih) * sar
8900
8901       hsub
8902       vsub
8903           horizontal and vertical chroma subsample values. For example for
8904           the pixel format "yuv422p" hsub is 2 and vsub is 1.
8905
8906       n   The number of the input frame, starting from 0.
8907
8908       pos the position in the file of the input frame, NAN if unknown
8909
8910       t   The timestamp expressed in seconds. It's NAN if the input timestamp
8911           is unknown.
8912
8913       The expression for out_w may depend on the value of out_h, and the
8914       expression for out_h may depend on out_w, but they cannot depend on x
8915       and y, as x and y are evaluated after out_w and out_h.
8916
8917       The x and y parameters specify the expressions for the position of the
8918       top-left corner of the output (non-cropped) area. They are evaluated
8919       for each frame. If the evaluated value is not valid, it is approximated
8920       to the nearest valid value.
8921
8922       The expression for x may depend on y, and the expression for y may
8923       depend on x.
8924
8925       Examples
8926
8927       •   Crop area with size 100x100 at position (12,34).
8928
8929                   crop=100:100:12:34
8930
8931           Using named options, the example above becomes:
8932
8933                   crop=w=100:h=100:x=12:y=34
8934
8935       •   Crop the central input area with size 100x100:
8936
8937                   crop=100:100
8938
8939       •   Crop the central input area with size 2/3 of the input video:
8940
8941                   crop=2/3*in_w:2/3*in_h
8942
8943       •   Crop the input video central square:
8944
8945                   crop=out_w=in_h
8946                   crop=in_h
8947
8948       •   Delimit the rectangle with the top-left corner placed at position
8949           100:100 and the right-bottom corner corresponding to the right-
8950           bottom corner of the input image.
8951
8952                   crop=in_w-100:in_h-100:100:100
8953
8954       •   Crop 10 pixels from the left and right borders, and 20 pixels from
8955           the top and bottom borders
8956
8957                   crop=in_w-2*10:in_h-2*20
8958
8959       •   Keep only the bottom right quarter of the input image:
8960
8961                   crop=in_w/2:in_h/2:in_w/2:in_h/2
8962
8963       •   Crop height for getting Greek harmony:
8964
8965                   crop=in_w:1/PHI*in_w
8966
8967       •   Apply trembling effect:
8968
8969                   crop=in_w/2:in_h/2:(in_w-out_w)/2+((in_w-out_w)/2)*sin(n/10):(in_h-out_h)/2 +((in_h-out_h)/2)*sin(n/7)
8970
8971       •   Apply erratic camera effect depending on timestamp:
8972
8973                   crop=in_w/2:in_h/2:(in_w-out_w)/2+((in_w-out_w)/2)*sin(t*10):(in_h-out_h)/2 +((in_h-out_h)/2)*sin(t*13)"
8974
8975       •   Set x depending on the value of y:
8976
8977                   crop=in_w/2:in_h/2:y:10+10*sin(n/10)
8978
8979       Commands
8980
8981       This filter supports the following commands:
8982
8983       w, out_w
8984       h, out_h
8985       x
8986       y   Set width/height of the output video and the horizontal/vertical
8987           position in the input video.  The command accepts the same syntax
8988           of the corresponding option.
8989
8990           If the specified expression is not valid, it is kept at its current
8991           value.
8992
8993   cropdetect
8994       Auto-detect the crop size.
8995
8996       It calculates the necessary cropping parameters and prints the
8997       recommended parameters via the logging system. The detected dimensions
8998       correspond to the non-black area of the input video.
8999
9000       It accepts the following parameters:
9001
9002       limit
9003           Set higher black value threshold, which can be optionally specified
9004           from nothing (0) to everything (255 for 8-bit based formats). An
9005           intensity value greater to the set value is considered non-black.
9006           It defaults to 24.  You can also specify a value between 0.0 and
9007           1.0 which will be scaled depending on the bitdepth of the pixel
9008           format.
9009
9010       round
9011           The value which the width/height should be divisible by. It
9012           defaults to 16. The offset is automatically adjusted to center the
9013           video. Use 2 to get only even dimensions (needed for 4:2:2 video).
9014           16 is best when encoding to most video codecs.
9015
9016       skip
9017           Set the number of initial frames for which evaluation is skipped.
9018           Default is 2. Range is 0 to INT_MAX.
9019
9020       reset_count, reset
9021           Set the counter that determines after how many frames cropdetect
9022           will reset the previously detected largest video area and start
9023           over to detect the current optimal crop area. Default value is 0.
9024
9025           This can be useful when channel logos distort the video area. 0
9026           indicates 'never reset', and returns the largest area encountered
9027           during playback.
9028
9029   cue
9030       Delay video filtering until a given wallclock timestamp. The filter
9031       first passes on preroll amount of frames, then it buffers at most
9032       buffer amount of frames and waits for the cue. After reaching the cue
9033       it forwards the buffered frames and also any subsequent frames coming
9034       in its input.
9035
9036       The filter can be used synchronize the output of multiple ffmpeg
9037       processes for realtime output devices like decklink. By putting the
9038       delay in the filtering chain and pre-buffering frames the process can
9039       pass on data to output almost immediately after the target wallclock
9040       timestamp is reached.
9041
9042       Perfect frame accuracy cannot be guaranteed, but the result is good
9043       enough for some use cases.
9044
9045       cue The cue timestamp expressed in a UNIX timestamp in microseconds.
9046           Default is 0.
9047
9048       preroll
9049           The duration of content to pass on as preroll expressed in seconds.
9050           Default is 0.
9051
9052       buffer
9053           The maximum duration of content to buffer before waiting for the
9054           cue expressed in seconds. Default is 0.
9055
9056   curves
9057       Apply color adjustments using curves.
9058
9059       This filter is similar to the Adobe Photoshop and GIMP curves tools.
9060       Each component (red, green and blue) has its values defined by N key
9061       points tied from each other using a smooth curve. The x-axis represents
9062       the pixel values from the input frame, and the y-axis the new pixel
9063       values to be set for the output frame.
9064
9065       By default, a component curve is defined by the two points (0;0) and
9066       (1;1). This creates a straight line where each original pixel value is
9067       "adjusted" to its own value, which means no change to the image.
9068
9069       The filter allows you to redefine these two points and add some more. A
9070       new curve (using a natural cubic spline interpolation) will be define
9071       to pass smoothly through all these new coordinates. The new defined
9072       points needs to be strictly increasing over the x-axis, and their x and
9073       y values must be in the [0;1] interval.  If the computed curves
9074       happened to go outside the vector spaces, the values will be clipped
9075       accordingly.
9076
9077       The filter accepts the following options:
9078
9079       preset
9080           Select one of the available color presets. This option can be used
9081           in addition to the r, g, b parameters; in this case, the later
9082           options takes priority on the preset values.  Available presets
9083           are:
9084
9085           none
9086           color_negative
9087           cross_process
9088           darker
9089           increase_contrast
9090           lighter
9091           linear_contrast
9092           medium_contrast
9093           negative
9094           strong_contrast
9095           vintage
9096
9097           Default is "none".
9098
9099       master, m
9100           Set the master key points. These points will define a second pass
9101           mapping. It is sometimes called a "luminance" or "value" mapping.
9102           It can be used with r, g, b or all since it acts like a post-
9103           processing LUT.
9104
9105       red, r
9106           Set the key points for the red component.
9107
9108       green, g
9109           Set the key points for the green component.
9110
9111       blue, b
9112           Set the key points for the blue component.
9113
9114       all Set the key points for all components (not including master).  Can
9115           be used in addition to the other key points component options. In
9116           this case, the unset component(s) will fallback on this all
9117           setting.
9118
9119       psfile
9120           Specify a Photoshop curves file (".acv") to import the settings
9121           from.
9122
9123       plot
9124           Save Gnuplot script of the curves in specified file.
9125
9126       To avoid some filtergraph syntax conflicts, each key points list need
9127       to be defined using the following syntax: "x0/y0 x1/y1 x2/y2 ...".
9128
9129       Commands
9130
9131       This filter supports same commands as options.
9132
9133       Examples
9134
9135       •   Increase slightly the middle level of blue:
9136
9137                   curves=blue='0/0 0.5/0.58 1/1'
9138
9139       •   Vintage effect:
9140
9141                   curves=r='0/0.11 .42/.51 1/0.95':g='0/0 0.50/0.48 1/1':b='0/0.22 .49/.44 1/0.8'
9142
9143           Here we obtain the following coordinates for each components:
9144
9145           red "(0;0.11) (0.42;0.51) (1;0.95)"
9146
9147           green
9148               "(0;0) (0.50;0.48) (1;1)"
9149
9150           blue
9151               "(0;0.22) (0.49;0.44) (1;0.80)"
9152
9153       •   The previous example can also be achieved with the associated
9154           built-in preset:
9155
9156                   curves=preset=vintage
9157
9158       •   Or simply:
9159
9160                   curves=vintage
9161
9162       •   Use a Photoshop preset and redefine the points of the green
9163           component:
9164
9165                   curves=psfile='MyCurvesPresets/purple.acv':green='0/0 0.45/0.53 1/1'
9166
9167       •   Check out the curves of the "cross_process" profile using ffmpeg
9168           and gnuplot:
9169
9170                   ffmpeg -f lavfi -i color -vf curves=cross_process:plot=/tmp/curves.plt -frames:v 1 -f null -
9171                   gnuplot -p /tmp/curves.plt
9172
9173   datascope
9174       Video data analysis filter.
9175
9176       This filter shows hexadecimal pixel values of part of video.
9177
9178       The filter accepts the following options:
9179
9180       size, s
9181           Set output video size.
9182
9183       x   Set x offset from where to pick pixels.
9184
9185       y   Set y offset from where to pick pixels.
9186
9187       mode
9188           Set scope mode, can be one of the following:
9189
9190           mono
9191               Draw hexadecimal pixel values with white color on black
9192               background.
9193
9194           color
9195               Draw hexadecimal pixel values with input video pixel color on
9196               black background.
9197
9198           color2
9199               Draw hexadecimal pixel values on color background picked from
9200               input video, the text color is picked in such way so its always
9201               visible.
9202
9203       axis
9204           Draw rows and columns numbers on left and top of video.
9205
9206       opacity
9207           Set background opacity.
9208
9209       format
9210           Set display number format. Can be "hex", or "dec". Default is
9211           "hex".
9212
9213       components
9214           Set pixel components to display. By default all pixel components
9215           are displayed.
9216
9217       Commands
9218
9219       This filter supports same commands as options excluding "size" option.
9220
9221   dblur
9222       Apply Directional blur filter.
9223
9224       The filter accepts the following options:
9225
9226       angle
9227           Set angle of directional blur. Default is 45.
9228
9229       radius
9230           Set radius of directional blur. Default is 5.
9231
9232       planes
9233           Set which planes to filter. By default all planes are filtered.
9234
9235       Commands
9236
9237       This filter supports same commands as options.  The command accepts the
9238       same syntax of the corresponding option.
9239
9240       If the specified expression is not valid, it is kept at its current
9241       value.
9242
9243   dctdnoiz
9244       Denoise frames using 2D DCT (frequency domain filtering).
9245
9246       This filter is not designed for real time.
9247
9248       The filter accepts the following options:
9249
9250       sigma, s
9251           Set the noise sigma constant.
9252
9253           This sigma defines a hard threshold of "3 * sigma"; every DCT
9254           coefficient (absolute value) below this threshold with be dropped.
9255
9256           If you need a more advanced filtering, see expr.
9257
9258           Default is 0.
9259
9260       overlap
9261           Set number overlapping pixels for each block. Since the filter can
9262           be slow, you may want to reduce this value, at the cost of a less
9263           effective filter and the risk of various artefacts.
9264
9265           If the overlapping value doesn't permit processing the whole input
9266           width or height, a warning will be displayed and according borders
9267           won't be denoised.
9268
9269           Default value is blocksize-1, which is the best possible setting.
9270
9271       expr, e
9272           Set the coefficient factor expression.
9273
9274           For each coefficient of a DCT block, this expression will be
9275           evaluated as a multiplier value for the coefficient.
9276
9277           If this is option is set, the sigma option will be ignored.
9278
9279           The absolute value of the coefficient can be accessed through the c
9280           variable.
9281
9282       n   Set the blocksize using the number of bits. "1<<n" defines the
9283           blocksize, which is the width and height of the processed blocks.
9284
9285           The default value is 3 (8x8) and can be raised to 4 for a blocksize
9286           of 16x16. Note that changing this setting has huge consequences on
9287           the speed processing. Also, a larger block size does not
9288           necessarily means a better de-noising.
9289
9290       Examples
9291
9292       Apply a denoise with a sigma of 4.5:
9293
9294               dctdnoiz=4.5
9295
9296       The same operation can be achieved using the expression system:
9297
9298               dctdnoiz=e='gte(c, 4.5*3)'
9299
9300       Violent denoise using a block size of "16x16":
9301
9302               dctdnoiz=15:n=4
9303
9304   deband
9305       Remove banding artifacts from input video.  It works by replacing
9306       banded pixels with average value of referenced pixels.
9307
9308       The filter accepts the following options:
9309
9310       1thr
9311       2thr
9312       3thr
9313       4thr
9314           Set banding detection threshold for each plane. Default is 0.02.
9315           Valid range is 0.00003 to 0.5.  If difference between current pixel
9316           and reference pixel is less than threshold, it will be considered
9317           as banded.
9318
9319       range, r
9320           Banding detection range in pixels. Default is 16. If positive,
9321           random number in range 0 to set value will be used. If negative,
9322           exact absolute value will be used.  The range defines square of
9323           four pixels around current pixel.
9324
9325       direction, d
9326           Set direction in radians from which four pixel will be compared. If
9327           positive, random direction from 0 to set direction will be picked.
9328           If negative, exact of absolute value will be picked. For example
9329           direction 0, -PI or -2*PI radians will pick only pixels on same row
9330           and -PI/2 will pick only pixels on same column.
9331
9332       blur, b
9333           If enabled, current pixel is compared with average value of all
9334           four surrounding pixels. The default is enabled. If disabled
9335           current pixel is compared with all four surrounding pixels. The
9336           pixel is considered banded if only all four differences with
9337           surrounding pixels are less than threshold.
9338
9339       coupling, c
9340           If enabled, current pixel is changed if and only if all pixel
9341           components are banded, e.g. banding detection threshold is
9342           triggered for all color components.  The default is disabled.
9343
9344       Commands
9345
9346       This filter supports the all above options as commands.
9347
9348   deblock
9349       Remove blocking artifacts from input video.
9350
9351       The filter accepts the following options:
9352
9353       filter
9354           Set filter type, can be weak or strong. Default is strong.  This
9355           controls what kind of deblocking is applied.
9356
9357       block
9358           Set size of block, allowed range is from 4 to 512. Default is 8.
9359
9360       alpha
9361       beta
9362       gamma
9363       delta
9364           Set blocking detection thresholds. Allowed range is 0 to 1.
9365           Defaults are: 0.098 for alpha and 0.05 for the rest.  Using higher
9366           threshold gives more deblocking strength.  Setting alpha controls
9367           threshold detection at exact edge of block.  Remaining options
9368           controls threshold detection near the edge. Each one for
9369           below/above or left/right. Setting any of those to 0 disables
9370           deblocking.
9371
9372       planes
9373           Set planes to filter. Default is to filter all available planes.
9374
9375       Examples
9376
9377       •   Deblock using weak filter and block size of 4 pixels.
9378
9379                   deblock=filter=weak:block=4
9380
9381       •   Deblock using strong filter, block size of 4 pixels and custom
9382           thresholds for deblocking more edges.
9383
9384                   deblock=filter=strong:block=4:alpha=0.12:beta=0.07:gamma=0.06:delta=0.05
9385
9386       •   Similar as above, but filter only first plane.
9387
9388                   deblock=filter=strong:block=4:alpha=0.12:beta=0.07:gamma=0.06:delta=0.05:planes=1
9389
9390       •   Similar as above, but filter only second and third plane.
9391
9392                   deblock=filter=strong:block=4:alpha=0.12:beta=0.07:gamma=0.06:delta=0.05:planes=6
9393
9394       Commands
9395
9396       This filter supports the all above options as commands.
9397
9398   decimate
9399       Drop duplicated frames at regular intervals.
9400
9401       The filter accepts the following options:
9402
9403       cycle
9404           Set the number of frames from which one will be dropped. Setting
9405           this to N means one frame in every batch of N frames will be
9406           dropped.  Default is 5.
9407
9408       dupthresh
9409           Set the threshold for duplicate detection. If the difference metric
9410           for a frame is less than or equal to this value, then it is
9411           declared as duplicate. Default is 1.1
9412
9413       scthresh
9414           Set scene change threshold. Default is 15.
9415
9416       blockx
9417       blocky
9418           Set the size of the x and y-axis blocks used during metric
9419           calculations.  Larger blocks give better noise suppression, but
9420           also give worse detection of small movements. Must be a power of
9421           two. Default is 32.
9422
9423       ppsrc
9424           Mark main input as a pre-processed input and activate clean source
9425           input stream. This allows the input to be pre-processed with
9426           various filters to help the metrics calculation while keeping the
9427           frame selection lossless. When set to 1, the first stream is for
9428           the pre-processed input, and the second stream is the clean source
9429           from where the kept frames are chosen. Default is 0.
9430
9431       chroma
9432           Set whether or not chroma is considered in the metric calculations.
9433           Default is 1.
9434
9435   deconvolve
9436       Apply 2D deconvolution of video stream in frequency domain using second
9437       stream as impulse.
9438
9439       The filter accepts the following options:
9440
9441       planes
9442           Set which planes to process.
9443
9444       impulse
9445           Set which impulse video frames will be processed, can be first or
9446           all. Default is all.
9447
9448       noise
9449           Set noise when doing divisions. Default is 0.0000001. Useful when
9450           width and height are not same and not power of 2 or if stream prior
9451           to convolving had noise.
9452
9453       The "deconvolve" filter also supports the framesync options.
9454
9455   dedot
9456       Reduce cross-luminance (dot-crawl) and cross-color (rainbows) from
9457       video.
9458
9459       It accepts the following options:
9460
9461       m   Set mode of operation. Can be combination of dotcrawl for cross-
9462           luminance reduction and/or rainbows for cross-color reduction.
9463
9464       lt  Set spatial luma threshold. Lower values increases reduction of
9465           cross-luminance.
9466
9467       tl  Set tolerance for temporal luma. Higher values increases reduction
9468           of cross-luminance.
9469
9470       tc  Set tolerance for chroma temporal variation. Higher values
9471           increases reduction of cross-color.
9472
9473       ct  Set temporal chroma threshold. Lower values increases reduction of
9474           cross-color.
9475
9476   deflate
9477       Apply deflate effect to the video.
9478
9479       This filter replaces the pixel by the local(3x3) average by taking into
9480       account only values lower than the pixel.
9481
9482       It accepts the following options:
9483
9484       threshold0
9485       threshold1
9486       threshold2
9487       threshold3
9488           Limit the maximum change for each plane, default is 65535.  If 0,
9489           plane will remain unchanged.
9490
9491       Commands
9492
9493       This filter supports the all above options as commands.
9494
9495   deflicker
9496       Remove temporal frame luminance variations.
9497
9498       It accepts the following options:
9499
9500       size, s
9501           Set moving-average filter size in frames. Default is 5. Allowed
9502           range is 2 - 129.
9503
9504       mode, m
9505           Set averaging mode to smooth temporal luminance variations.
9506
9507           Available values are:
9508
9509           am  Arithmetic mean
9510
9511           gm  Geometric mean
9512
9513           hm  Harmonic mean
9514
9515           qm  Quadratic mean
9516
9517           cm  Cubic mean
9518
9519           pm  Power mean
9520
9521           median
9522               Median
9523
9524       bypass
9525           Do not actually modify frame. Useful when one only wants metadata.
9526
9527   dejudder
9528       Remove judder produced by partially interlaced telecined content.
9529
9530       Judder can be introduced, for instance, by pullup filter. If the
9531       original source was partially telecined content then the output of
9532       "pullup,dejudder" will have a variable frame rate. May change the
9533       recorded frame rate of the container. Aside from that change, this
9534       filter will not affect constant frame rate video.
9535
9536       The option available in this filter is:
9537
9538       cycle
9539           Specify the length of the window over which the judder repeats.
9540
9541           Accepts any integer greater than 1. Useful values are:
9542
9543           4   If the original was telecined from 24 to 30 fps (Film to NTSC).
9544
9545           5   If the original was telecined from 25 to 30 fps (PAL to NTSC).
9546
9547           20  If a mixture of the two.
9548
9549           The default is 4.
9550
9551   delogo
9552       Suppress a TV station logo by a simple interpolation of the surrounding
9553       pixels. Just set a rectangle covering the logo and watch it disappear
9554       (and sometimes something even uglier appear - your mileage may vary).
9555
9556       It accepts the following parameters:
9557
9558       x
9559       y   Specify the top left corner coordinates of the logo. They must be
9560           specified.
9561
9562       w
9563       h   Specify the width and height of the logo to clear. They must be
9564           specified.
9565
9566       show
9567           When set to 1, a green rectangle is drawn on the screen to simplify
9568           finding the right x, y, w, and h parameters.  The default value is
9569           0.
9570
9571           The rectangle is drawn on the outermost pixels which will be
9572           (partly) replaced with interpolated values. The values of the next
9573           pixels immediately outside this rectangle in each direction will be
9574           used to compute the interpolated pixel values inside the rectangle.
9575
9576       Examples
9577
9578       •   Set a rectangle covering the area with top left corner coordinates
9579           0,0 and size 100x77:
9580
9581                   delogo=x=0:y=0:w=100:h=77
9582
9583   derain
9584       Remove the rain in the input image/video by applying the derain methods
9585       based on convolutional neural networks. Supported models:
9586
9587       •   Recurrent Squeeze-and-Excitation Context Aggregation Net (RESCAN).
9588           See
9589           <http://openaccess.thecvf.com/content_ECCV_2018/papers/Xia_Li_Recurrent_Squeeze-and-Excitation_Context_ECCV_2018_paper.pdf>.
9590
9591       Training as well as model generation scripts are provided in the
9592       repository at <https://github.com/XueweiMeng/derain_filter.git>.
9593
9594       Native model files (.model) can be generated from TensorFlow model
9595       files (.pb) by using tools/python/convert.py
9596
9597       The filter accepts the following options:
9598
9599       filter_type
9600           Specify which filter to use. This option accepts the following
9601           values:
9602
9603           derain
9604               Derain filter. To conduct derain filter, you need to use a
9605               derain model.
9606
9607           dehaze
9608               Dehaze filter. To conduct dehaze filter, you need to use a
9609               dehaze model.
9610
9611           Default value is derain.
9612
9613       dnn_backend
9614           Specify which DNN backend to use for model loading and execution.
9615           This option accepts the following values:
9616
9617           native
9618               Native implementation of DNN loading and execution.
9619
9620           tensorflow
9621               TensorFlow backend. To enable this backend you need to install
9622               the TensorFlow for C library (see
9623               <https://www.tensorflow.org/install/lang_c>) and configure
9624               FFmpeg with "--enable-libtensorflow"
9625
9626           Default value is native.
9627
9628       model
9629           Set path to model file specifying network architecture and its
9630           parameters.  Note that different backends use different file
9631           formats. TensorFlow and native backend can load files for only its
9632           format.
9633
9634       To get full functionality (such as async execution), please use the
9635       dnn_processing filter.
9636
9637   deshake
9638       Attempt to fix small changes in horizontal and/or vertical shift. This
9639       filter helps remove camera shake from hand-holding a camera, bumping a
9640       tripod, moving on a vehicle, etc.
9641
9642       The filter accepts the following options:
9643
9644       x
9645       y
9646       w
9647       h   Specify a rectangular area where to limit the search for motion
9648           vectors.  If desired the search for motion vectors can be limited
9649           to a rectangular area of the frame defined by its top left corner,
9650           width and height. These parameters have the same meaning as the
9651           drawbox filter which can be used to visualise the position of the
9652           bounding box.
9653
9654           This is useful when simultaneous movement of subjects within the
9655           frame might be confused for camera motion by the motion vector
9656           search.
9657
9658           If any or all of x, y, w and h are set to -1 then the full frame is
9659           used. This allows later options to be set without specifying the
9660           bounding box for the motion vector search.
9661
9662           Default - search the whole frame.
9663
9664       rx
9665       ry  Specify the maximum extent of movement in x and y directions in the
9666           range 0-64 pixels. Default 16.
9667
9668       edge
9669           Specify how to generate pixels to fill blanks at the edge of the
9670           frame. Available values are:
9671
9672           blank, 0
9673               Fill zeroes at blank locations
9674
9675           original, 1
9676               Original image at blank locations
9677
9678           clamp, 2
9679               Extruded edge value at blank locations
9680
9681           mirror, 3
9682               Mirrored edge at blank locations
9683
9684           Default value is mirror.
9685
9686       blocksize
9687           Specify the blocksize to use for motion search. Range 4-128 pixels,
9688           default 8.
9689
9690       contrast
9691           Specify the contrast threshold for blocks. Only blocks with more
9692           than the specified contrast (difference between darkest and
9693           lightest pixels) will be considered. Range 1-255, default 125.
9694
9695       search
9696           Specify the search strategy. Available values are:
9697
9698           exhaustive, 0
9699               Set exhaustive search
9700
9701           less, 1
9702               Set less exhaustive search.
9703
9704           Default value is exhaustive.
9705
9706       filename
9707           If set then a detailed log of the motion search is written to the
9708           specified file.
9709
9710   despill
9711       Remove unwanted contamination of foreground colors, caused by reflected
9712       color of greenscreen or bluescreen.
9713
9714       This filter accepts the following options:
9715
9716       type
9717           Set what type of despill to use.
9718
9719       mix Set how spillmap will be generated.
9720
9721       expand
9722           Set how much to get rid of still remaining spill.
9723
9724       red Controls amount of red in spill area.
9725
9726       green
9727           Controls amount of green in spill area.  Should be -1 for
9728           greenscreen.
9729
9730       blue
9731           Controls amount of blue in spill area.  Should be -1 for
9732           bluescreen.
9733
9734       brightness
9735           Controls brightness of spill area, preserving colors.
9736
9737       alpha
9738           Modify alpha from generated spillmap.
9739
9740       Commands
9741
9742       This filter supports the all above options as commands.
9743
9744   detelecine
9745       Apply an exact inverse of the telecine operation. It requires a
9746       predefined pattern specified using the pattern option which must be the
9747       same as that passed to the telecine filter.
9748
9749       This filter accepts the following options:
9750
9751       first_field
9752           top, t
9753               top field first
9754
9755           bottom, b
9756               bottom field first The default value is "top".
9757
9758       pattern
9759           A string of numbers representing the pulldown pattern you wish to
9760           apply.  The default value is 23.
9761
9762       start_frame
9763           A number representing position of the first frame with respect to
9764           the telecine pattern. This is to be used if the stream is cut. The
9765           default value is 0.
9766
9767   dilation
9768       Apply dilation effect to the video.
9769
9770       This filter replaces the pixel by the local(3x3) maximum.
9771
9772       It accepts the following options:
9773
9774       threshold0
9775       threshold1
9776       threshold2
9777       threshold3
9778           Limit the maximum change for each plane, default is 65535.  If 0,
9779           plane will remain unchanged.
9780
9781       coordinates
9782           Flag which specifies the pixel to refer to. Default is 255 i.e. all
9783           eight pixels are used.
9784
9785           Flags to local 3x3 coordinates maps like this:
9786
9787               1 2 3
9788               4   5
9789               6 7 8
9790
9791       Commands
9792
9793       This filter supports the all above options as commands.
9794
9795   displace
9796       Displace pixels as indicated by second and third input stream.
9797
9798       It takes three input streams and outputs one stream, the first input is
9799       the source, and second and third input are displacement maps.
9800
9801       The second input specifies how much to displace pixels along the
9802       x-axis, while the third input specifies how much to displace pixels
9803       along the y-axis.  If one of displacement map streams terminates, last
9804       frame from that displacement map will be used.
9805
9806       Note that once generated, displacements maps can be reused over and
9807       over again.
9808
9809       A description of the accepted options follows.
9810
9811       edge
9812           Set displace behavior for pixels that are out of range.
9813
9814           Available values are:
9815
9816           blank
9817               Missing pixels are replaced by black pixels.
9818
9819           smear
9820               Adjacent pixels will spread out to replace missing pixels.
9821
9822           wrap
9823               Out of range pixels are wrapped so they point to pixels of
9824               other side.
9825
9826           mirror
9827               Out of range pixels will be replaced with mirrored pixels.
9828
9829           Default is smear.
9830
9831       Examples
9832
9833       •   Add ripple effect to rgb input of video size hd720:
9834
9835                   ffmpeg -i INPUT -f lavfi -i nullsrc=s=hd720,lutrgb=128:128:128 -f lavfi -i nullsrc=s=hd720,geq='r=128+30*sin(2*PI*X/400+T):g=128+30*sin(2*PI*X/400+T):b=128+30*sin(2*PI*X/400+T)' -lavfi '[0][1][2]displace' OUTPUT
9836
9837       •   Add wave effect to rgb input of video size hd720:
9838
9839                   ffmpeg -i INPUT -f lavfi -i nullsrc=hd720,geq='r=128+80*(sin(sqrt((X-W/2)*(X-W/2)+(Y-H/2)*(Y-H/2))/220*2*PI+T)):g=128+80*(sin(sqrt((X-W/2)*(X-W/2)+(Y-H/2)*(Y-H/2))/220*2*PI+T)):b=128+80*(sin(sqrt((X-W/2)*(X-W/2)+(Y-H/2)*(Y-H/2))/220*2*PI+T))' -lavfi '[1]split[x][y],[0][x][y]displace' OUTPUT
9840
9841   dnn_classify
9842       Do classification with deep neural networks based on bounding boxes.
9843
9844       The filter accepts the following options:
9845
9846       dnn_backend
9847           Specify which DNN backend to use for model loading and execution.
9848           This option accepts only openvino now, tensorflow backends will be
9849           added.
9850
9851       model
9852           Set path to model file specifying network architecture and its
9853           parameters.  Note that different backends use different file
9854           formats.
9855
9856       input
9857           Set the input name of the dnn network.
9858
9859       output
9860           Set the output name of the dnn network.
9861
9862       confidence
9863           Set the confidence threshold (default: 0.5).
9864
9865       labels
9866           Set path to label file specifying the mapping between label id and
9867           name.  Each label name is written in one line, tailing spaces and
9868           empty lines are skipped.  The first line is the name of label id 0,
9869           and the second line is the name of label id 1, etc.  The label id
9870           is considered as name if the label file is not provided.
9871
9872       backend_configs
9873           Set the configs to be passed into backend
9874
9875           For tensorflow backend, you can set its configs with sess_config
9876           options, please use tools/python/tf_sess_config.py to get the
9877           configs for your system.
9878
9879   dnn_detect
9880       Do object detection with deep neural networks.
9881
9882       The filter accepts the following options:
9883
9884       dnn_backend
9885           Specify which DNN backend to use for model loading and execution.
9886           This option accepts only openvino now, tensorflow backends will be
9887           added.
9888
9889       model
9890           Set path to model file specifying network architecture and its
9891           parameters.  Note that different backends use different file
9892           formats.
9893
9894       input
9895           Set the input name of the dnn network.
9896
9897       output
9898           Set the output name of the dnn network.
9899
9900       confidence
9901           Set the confidence threshold (default: 0.5).
9902
9903       labels
9904           Set path to label file specifying the mapping between label id and
9905           name.  Each label name is written in one line, tailing spaces and
9906           empty lines are skipped.  The first line is the name of label id 0
9907           (usually it is 'background'), and the second line is the name of
9908           label id 1, etc.  The label id is considered as name if the label
9909           file is not provided.
9910
9911       backend_configs
9912           Set the configs to be passed into backend. To use async execution,
9913           set async (default: set).  Roll back to sync execution if the
9914           backend does not support async.
9915
9916   dnn_processing
9917       Do image processing with deep neural networks. It works together with
9918       another filter which converts the pixel format of the Frame to what the
9919       dnn network requires.
9920
9921       The filter accepts the following options:
9922
9923       dnn_backend
9924           Specify which DNN backend to use for model loading and execution.
9925           This option accepts the following values:
9926
9927           native
9928               Native implementation of DNN loading and execution.
9929
9930           tensorflow
9931               TensorFlow backend. To enable this backend you need to install
9932               the TensorFlow for C library (see
9933               <https://www.tensorflow.org/install/lang_c>) and configure
9934               FFmpeg with "--enable-libtensorflow"
9935
9936           openvino
9937               OpenVINO backend. To enable this backend you need to build and
9938               install the OpenVINO for C library (see
9939               <https://github.com/openvinotoolkit/openvino/blob/master/build-instruction.md>)
9940               and configure FFmpeg with "--enable-libopenvino"
9941               (--extra-cflags=-I... --extra-ldflags=-L... might be needed if
9942               the header files and libraries are not installed into system
9943               path)
9944
9945           Default value is native.
9946
9947       model
9948           Set path to model file specifying network architecture and its
9949           parameters.  Note that different backends use different file
9950           formats. TensorFlow, OpenVINO and native backend can load files for
9951           only its format.
9952
9953           Native model file (.model) can be generated from TensorFlow model
9954           file (.pb) by using tools/python/convert.py
9955
9956       input
9957           Set the input name of the dnn network.
9958
9959       output
9960           Set the output name of the dnn network.
9961
9962       backend_configs
9963           Set the configs to be passed into backend. To use async execution,
9964           set async (default: set).  Roll back to sync execution if the
9965           backend does not support async.
9966
9967           For tensorflow backend, you can set its configs with sess_config
9968           options, please use tools/python/tf_sess_config.py to get the
9969           configs of TensorFlow backend for your system.
9970
9971       Examples
9972
9973       •   Remove rain in rgb24 frame with can.pb (see derain filter):
9974
9975                   ./ffmpeg -i rain.jpg -vf format=rgb24,dnn_processing=dnn_backend=tensorflow:model=can.pb:input=x:output=y derain.jpg
9976
9977       •   Halve the pixel value of the frame with format gray32f:
9978
9979                   ffmpeg -i input.jpg -vf format=grayf32,dnn_processing=model=halve_gray_float.model:input=dnn_in:output=dnn_out:dnn_backend=native -y out.native.png
9980
9981       •   Handle the Y channel with srcnn.pb (see sr filter) for frame with
9982           yuv420p (planar YUV formats supported):
9983
9984                   ./ffmpeg -i 480p.jpg -vf format=yuv420p,scale=w=iw*2:h=ih*2,dnn_processing=dnn_backend=tensorflow:model=srcnn.pb:input=x:output=y -y srcnn.jpg
9985
9986       •   Handle the Y channel with espcn.pb (see sr filter), which changes
9987           frame size, for format yuv420p (planar YUV formats supported),
9988           please use tools/python/tf_sess_config.py to get the configs of
9989           TensorFlow backend for your system.
9990
9991                   ./ffmpeg -i 480p.jpg -vf format=yuv420p,dnn_processing=dnn_backend=tensorflow:model=espcn.pb:input=x:output=y:backend_configs=sess_config=0x10022805320e09cdccccccccccec3f20012a01303801 -y tmp.espcn.jpg
9992
9993   drawbox
9994       Draw a colored box on the input image.
9995
9996       It accepts the following parameters:
9997
9998       x
9999       y   The expressions which specify the top left corner coordinates of
10000           the box. It defaults to 0.
10001
10002       width, w
10003       height, h
10004           The expressions which specify the width and height of the box; if 0
10005           they are interpreted as the input width and height. It defaults to
10006           0.
10007
10008       color, c
10009           Specify the color of the box to write. For the general syntax of
10010           this option, check the "Color" section in the ffmpeg-utils manual.
10011           If the special value "invert" is used, the box edge color is the
10012           same as the video with inverted luma.
10013
10014       thickness, t
10015           The expression which sets the thickness of the box edge.  A value
10016           of "fill" will create a filled box. Default value is 3.
10017
10018           See below for the list of accepted constants.
10019
10020       replace
10021           Applicable if the input has alpha. With value 1, the pixels of the
10022           painted box will overwrite the video's color and alpha pixels.
10023           Default is 0, which composites the box onto the input, leaving the
10024           video's alpha intact.
10025
10026       The parameters for x, y, w and h and t are expressions containing the
10027       following constants:
10028
10029       dar The input display aspect ratio, it is the same as (w / h) * sar.
10030
10031       hsub
10032       vsub
10033           horizontal and vertical chroma subsample values. For example for
10034           the pixel format "yuv422p" hsub is 2 and vsub is 1.
10035
10036       in_h, ih
10037       in_w, iw
10038           The input width and height.
10039
10040       sar The input sample aspect ratio.
10041
10042       x
10043       y   The x and y offset coordinates where the box is drawn.
10044
10045       w
10046       h   The width and height of the drawn box.
10047
10048       box_source
10049           Box source can be set as side_data_detection_bboxes if you want to
10050           use box data in detection bboxes of side data.
10051
10052           If box_source is set, the x, y, width and height will be ignored
10053           and still use box data in detection bboxes of side data. So please
10054           do not use this parameter if you were not sure about the box
10055           source.
10056
10057       t   The thickness of the drawn box.
10058
10059           These constants allow the x, y, w, h and t expressions to refer to
10060           each other, so you may for example specify "y=x/dar" or "h=w/dar".
10061
10062       Examples
10063
10064       •   Draw a black box around the edge of the input image:
10065
10066                   drawbox
10067
10068       •   Draw a box with color red and an opacity of 50%:
10069
10070                   drawbox=10:20:200:60:red@0.5
10071
10072           The previous example can be specified as:
10073
10074                   drawbox=x=10:y=20:w=200:h=60:color=red@0.5
10075
10076       •   Fill the box with pink color:
10077
10078                   drawbox=x=10:y=10:w=100:h=100:color=pink@0.5:t=fill
10079
10080       •   Draw a 2-pixel red 2.40:1 mask:
10081
10082                   drawbox=x=-t:y=0.5*(ih-iw/2.4)-t:w=iw+t*2:h=iw/2.4+t*2:t=2:c=red
10083
10084       Commands
10085
10086       This filter supports same commands as options.  The command accepts the
10087       same syntax of the corresponding option.
10088
10089       If the specified expression is not valid, it is kept at its current
10090       value.
10091
10092   drawgraph
10093       Draw a graph using input video metadata.
10094
10095       It accepts the following parameters:
10096
10097       m1  Set 1st frame metadata key from which metadata values will be used
10098           to draw a graph.
10099
10100       fg1 Set 1st foreground color expression.
10101
10102       m2  Set 2nd frame metadata key from which metadata values will be used
10103           to draw a graph.
10104
10105       fg2 Set 2nd foreground color expression.
10106
10107       m3  Set 3rd frame metadata key from which metadata values will be used
10108           to draw a graph.
10109
10110       fg3 Set 3rd foreground color expression.
10111
10112       m4  Set 4th frame metadata key from which metadata values will be used
10113           to draw a graph.
10114
10115       fg4 Set 4th foreground color expression.
10116
10117       min Set minimal value of metadata value.
10118
10119       max Set maximal value of metadata value.
10120
10121       bg  Set graph background color. Default is white.
10122
10123       mode
10124           Set graph mode.
10125
10126           Available values for mode is:
10127
10128           bar
10129           dot
10130           line
10131
10132           Default is "line".
10133
10134       slide
10135           Set slide mode.
10136
10137           Available values for slide is:
10138
10139           frame
10140               Draw new frame when right border is reached.
10141
10142           replace
10143               Replace old columns with new ones.
10144
10145           scroll
10146               Scroll from right to left.
10147
10148           rscroll
10149               Scroll from left to right.
10150
10151           picture
10152               Draw single picture.
10153
10154           Default is "frame".
10155
10156       size
10157           Set size of graph video. For the syntax of this option, check the
10158           "Video size" section in the ffmpeg-utils manual.  The default value
10159           is "900x256".
10160
10161       rate, r
10162           Set the output frame rate. Default value is 25.
10163
10164           The foreground color expressions can use the following variables:
10165
10166           MIN Minimal value of metadata value.
10167
10168           MAX Maximal value of metadata value.
10169
10170           VAL Current metadata key value.
10171
10172           The color is defined as 0xAABBGGRR.
10173
10174       Example using metadata from signalstats filter:
10175
10176               signalstats,drawgraph=lavfi.signalstats.YAVG:min=0:max=255
10177
10178       Example using metadata from ebur128 filter:
10179
10180               ebur128=metadata=1,adrawgraph=lavfi.r128.M:min=-120:max=5
10181
10182   drawgrid
10183       Draw a grid on the input image.
10184
10185       It accepts the following parameters:
10186
10187       x
10188       y   The expressions which specify the coordinates of some point of grid
10189           intersection (meant to configure offset). Both default to 0.
10190
10191       width, w
10192       height, h
10193           The expressions which specify the width and height of the grid
10194           cell, if 0 they are interpreted as the input width and height,
10195           respectively, minus "thickness", so image gets framed. Default to
10196           0.
10197
10198       color, c
10199           Specify the color of the grid. For the general syntax of this
10200           option, check the "Color" section in the ffmpeg-utils manual. If
10201           the special value "invert" is used, the grid color is the same as
10202           the video with inverted luma.
10203
10204       thickness, t
10205           The expression which sets the thickness of the grid line. Default
10206           value is 1.
10207
10208           See below for the list of accepted constants.
10209
10210       replace
10211           Applicable if the input has alpha. With 1 the pixels of the painted
10212           grid will overwrite the video's color and alpha pixels.  Default is
10213           0, which composites the grid onto the input, leaving the video's
10214           alpha intact.
10215
10216       The parameters for x, y, w and h and t are expressions containing the
10217       following constants:
10218
10219       dar The input display aspect ratio, it is the same as (w / h) * sar.
10220
10221       hsub
10222       vsub
10223           horizontal and vertical chroma subsample values. For example for
10224           the pixel format "yuv422p" hsub is 2 and vsub is 1.
10225
10226       in_h, ih
10227       in_w, iw
10228           The input grid cell width and height.
10229
10230       sar The input sample aspect ratio.
10231
10232       x
10233       y   The x and y coordinates of some point of grid intersection (meant
10234           to configure offset).
10235
10236       w
10237       h   The width and height of the drawn cell.
10238
10239       t   The thickness of the drawn cell.
10240
10241           These constants allow the x, y, w, h and t expressions to refer to
10242           each other, so you may for example specify "y=x/dar" or "h=w/dar".
10243
10244       Examples
10245
10246       •   Draw a grid with cell 100x100 pixels, thickness 2 pixels, with
10247           color red and an opacity of 50%:
10248
10249                   drawgrid=width=100:height=100:thickness=2:color=red@0.5
10250
10251       •   Draw a white 3x3 grid with an opacity of 50%:
10252
10253                   drawgrid=w=iw/3:h=ih/3:t=2:c=white@0.5
10254
10255       Commands
10256
10257       This filter supports same commands as options.  The command accepts the
10258       same syntax of the corresponding option.
10259
10260       If the specified expression is not valid, it is kept at its current
10261       value.
10262
10263   drawtext
10264       Draw a text string or text from a specified file on top of a video,
10265       using the libfreetype library.
10266
10267       To enable compilation of this filter, you need to configure FFmpeg with
10268       "--enable-libfreetype".  To enable default font fallback and the font
10269       option you need to configure FFmpeg with "--enable-libfontconfig".  To
10270       enable the text_shaping option, you need to configure FFmpeg with
10271       "--enable-libfribidi".
10272
10273       Syntax
10274
10275       It accepts the following parameters:
10276
10277       box Used to draw a box around text using the background color.  The
10278           value must be either 1 (enable) or 0 (disable).  The default value
10279           of box is 0.
10280
10281       boxborderw
10282           Set the width of the border to be drawn around the box using
10283           boxcolor.  The default value of boxborderw is 0.
10284
10285       boxcolor
10286           The color to be used for drawing box around text. For the syntax of
10287           this option, check the "Color" section in the ffmpeg-utils manual.
10288
10289           The default value of boxcolor is "white".
10290
10291       line_spacing
10292           Set the line spacing in pixels of the border to be drawn around the
10293           box using box.  The default value of line_spacing is 0.
10294
10295       borderw
10296           Set the width of the border to be drawn around the text using
10297           bordercolor.  The default value of borderw is 0.
10298
10299       bordercolor
10300           Set the color to be used for drawing border around text. For the
10301           syntax of this option, check the "Color" section in the ffmpeg-
10302           utils manual.
10303
10304           The default value of bordercolor is "black".
10305
10306       expansion
10307           Select how the text is expanded. Can be either "none", "strftime"
10308           (deprecated) or "normal" (default). See the drawtext_expansion,
10309           Text expansion section below for details.
10310
10311       basetime
10312           Set a start time for the count. Value is in microseconds. Only
10313           applied in the deprecated strftime expansion mode. To emulate in
10314           normal expansion mode use the "pts" function, supplying the start
10315           time (in seconds) as the second argument.
10316
10317       fix_bounds
10318           If true, check and fix text coords to avoid clipping.
10319
10320       fontcolor
10321           The color to be used for drawing fonts. For the syntax of this
10322           option, check the "Color" section in the ffmpeg-utils manual.
10323
10324           The default value of fontcolor is "black".
10325
10326       fontcolor_expr
10327           String which is expanded the same way as text to obtain dynamic
10328           fontcolor value. By default this option has empty value and is not
10329           processed. When this option is set, it overrides fontcolor option.
10330
10331       font
10332           The font family to be used for drawing text. By default Sans.
10333
10334       fontfile
10335           The font file to be used for drawing text. The path must be
10336           included.  This parameter is mandatory if the fontconfig support is
10337           disabled.
10338
10339       alpha
10340           Draw the text applying alpha blending. The value can be a number
10341           between 0.0 and 1.0.  The expression accepts the same variables x,
10342           y as well.  The default value is 1.  Please see fontcolor_expr.
10343
10344       fontsize
10345           The font size to be used for drawing text.  The default value of
10346           fontsize is 16.
10347
10348       text_shaping
10349           If set to 1, attempt to shape the text (for example, reverse the
10350           order of right-to-left text and join Arabic characters) before
10351           drawing it.  Otherwise, just draw the text exactly as given.  By
10352           default 1 (if supported).
10353
10354       ft_load_flags
10355           The flags to be used for loading the fonts.
10356
10357           The flags map the corresponding flags supported by libfreetype, and
10358           are a combination of the following values:
10359
10360           default
10361           no_scale
10362           no_hinting
10363           render
10364           no_bitmap
10365           vertical_layout
10366           force_autohint
10367           crop_bitmap
10368           pedantic
10369           ignore_global_advance_width
10370           no_recurse
10371           ignore_transform
10372           monochrome
10373           linear_design
10374           no_autohint
10375
10376           Default value is "default".
10377
10378           For more information consult the documentation for the FT_LOAD_*
10379           libfreetype flags.
10380
10381       shadowcolor
10382           The color to be used for drawing a shadow behind the drawn text.
10383           For the syntax of this option, check the "Color" section in the
10384           ffmpeg-utils manual.
10385
10386           The default value of shadowcolor is "black".
10387
10388       shadowx
10389       shadowy
10390           The x and y offsets for the text shadow position with respect to
10391           the position of the text. They can be either positive or negative
10392           values. The default value for both is "0".
10393
10394       start_number
10395           The starting frame number for the n/frame_num variable. The default
10396           value is "0".
10397
10398       tabsize
10399           The size in number of spaces to use for rendering the tab.  Default
10400           value is 4.
10401
10402       timecode
10403           Set the initial timecode representation in "hh:mm:ss[:;.]ff"
10404           format. It can be used with or without text parameter.
10405           timecode_rate option must be specified.
10406
10407       timecode_rate, rate, r
10408           Set the timecode frame rate (timecode only). Value will be rounded
10409           to nearest integer. Minimum value is "1".  Drop-frame timecode is
10410           supported for frame rates 30 & 60.
10411
10412       tc24hmax
10413           If set to 1, the output of the timecode option will wrap around at
10414           24 hours.  Default is 0 (disabled).
10415
10416       text
10417           The text string to be drawn. The text must be a sequence of UTF-8
10418           encoded characters.  This parameter is mandatory if no file is
10419           specified with the parameter textfile.
10420
10421       textfile
10422           A text file containing text to be drawn. The text must be a
10423           sequence of UTF-8 encoded characters.
10424
10425           This parameter is mandatory if no text string is specified with the
10426           parameter text.
10427
10428           If both text and textfile are specified, an error is thrown.
10429
10430       text_source
10431           Text source should be set as side_data_detection_bboxes if you want
10432           to use text data in detection bboxes of side data.
10433
10434           If text source is set, text and textfile will be ignored and still
10435           use text data in detection bboxes of side data. So please do not
10436           use this parameter if you are not sure about the text source.
10437
10438       reload
10439           The textfile will be reloaded at specified frame interval.  Be sure
10440           to update textfile atomically, or it may be read partially, or even
10441           fail.  Range is 0 to INT_MAX. Default is 0.
10442
10443       x
10444       y   The expressions which specify the offsets where text will be drawn
10445           within the video frame. They are relative to the top/left border of
10446           the output image.
10447
10448           The default value of x and y is "0".
10449
10450           See below for the list of accepted constants and functions.
10451
10452       The parameters for x and y are expressions containing the following
10453       constants and functions:
10454
10455       dar input display aspect ratio, it is the same as (w / h) * sar
10456
10457       hsub
10458       vsub
10459           horizontal and vertical chroma subsample values. For example for
10460           the pixel format "yuv422p" hsub is 2 and vsub is 1.
10461
10462       line_h, lh
10463           the height of each text line
10464
10465       main_h, h, H
10466           the input height
10467
10468       main_w, w, W
10469           the input width
10470
10471       max_glyph_a, ascent
10472           the maximum distance from the baseline to the highest/upper grid
10473           coordinate used to place a glyph outline point, for all the
10474           rendered glyphs.  It is a positive value, due to the grid's
10475           orientation with the Y axis upwards.
10476
10477       max_glyph_d, descent
10478           the maximum distance from the baseline to the lowest grid
10479           coordinate used to place a glyph outline point, for all the
10480           rendered glyphs.  This is a negative value, due to the grid's
10481           orientation, with the Y axis upwards.
10482
10483       max_glyph_h
10484           maximum glyph height, that is the maximum height for all the glyphs
10485           contained in the rendered text, it is equivalent to ascent -
10486           descent.
10487
10488       max_glyph_w
10489           maximum glyph width, that is the maximum width for all the glyphs
10490           contained in the rendered text
10491
10492       n   the number of input frame, starting from 0
10493
10494       rand(min, max)
10495           return a random number included between min and max
10496
10497       sar The input sample aspect ratio.
10498
10499       t   timestamp expressed in seconds, NAN if the input timestamp is
10500           unknown
10501
10502       text_h, th
10503           the height of the rendered text
10504
10505       text_w, tw
10506           the width of the rendered text
10507
10508       x
10509       y   the x and y offset coordinates where the text is drawn.
10510
10511           These parameters allow the x and y expressions to refer to each
10512           other, so you can for example specify "y=x/dar".
10513
10514       pict_type
10515           A one character description of the current frame's picture type.
10516
10517       pkt_pos
10518           The current packet's position in the input file or stream (in
10519           bytes, from the start of the input). A value of -1 indicates this
10520           info is not available.
10521
10522       pkt_duration
10523           The current packet's duration, in seconds.
10524
10525       pkt_size
10526           The current packet's size (in bytes).
10527
10528       Text expansion
10529
10530       If expansion is set to "strftime", the filter recognizes strftime()
10531       sequences in the provided text and expands them accordingly. Check the
10532       documentation of strftime(). This feature is deprecated.
10533
10534       If expansion is set to "none", the text is printed verbatim.
10535
10536       If expansion is set to "normal" (which is the default), the following
10537       expansion mechanism is used.
10538
10539       The backslash character \, followed by any character, always expands to
10540       the second character.
10541
10542       Sequences of the form "%{...}" are expanded. The text between the
10543       braces is a function name, possibly followed by arguments separated by
10544       ':'.  If the arguments contain special characters or delimiters (':' or
10545       '}'), they should be escaped.
10546
10547       Note that they probably must also be escaped as the value for the text
10548       option in the filter argument string and as the filter argument in the
10549       filtergraph description, and possibly also for the shell, that makes up
10550       to four levels of escaping; using a text file avoids these problems.
10551
10552       The following functions are available:
10553
10554       expr, e
10555           The expression evaluation result.
10556
10557           It must take one argument specifying the expression to be
10558           evaluated, which accepts the same constants and functions as the x
10559           and y values. Note that not all constants should be used, for
10560           example the text size is not known when evaluating the expression,
10561           so the constants text_w and text_h will have an undefined value.
10562
10563       expr_int_format, eif
10564           Evaluate the expression's value and output as formatted integer.
10565
10566           The first argument is the expression to be evaluated, just as for
10567           the expr function.  The second argument specifies the output
10568           format. Allowed values are x, X, d and u. They are treated exactly
10569           as in the "printf" function.  The third parameter is optional and
10570           sets the number of positions taken by the output.  It can be used
10571           to add padding with zeros from the left.
10572
10573       gmtime
10574           The time at which the filter is running, expressed in UTC.  It can
10575           accept an argument: a strftime() format string.  The format string
10576           is extended to support the variable %[1-6]N which prints fractions
10577           of the second with optionally specified number of digits.
10578
10579       localtime
10580           The time at which the filter is running, expressed in the local
10581           time zone.  It can accept an argument: a strftime() format string.
10582           The format string is extended to support the variable %[1-6]N which
10583           prints fractions of the second with optionally specified number of
10584           digits.
10585
10586       metadata
10587           Frame metadata. Takes one or two arguments.
10588
10589           The first argument is mandatory and specifies the metadata key.
10590
10591           The second argument is optional and specifies a default value, used
10592           when the metadata key is not found or empty.
10593
10594           Available metadata can be identified by inspecting entries starting
10595           with TAG included within each frame section printed by running
10596           "ffprobe -show_frames".
10597
10598           String metadata generated in filters leading to the drawtext filter
10599           are also available.
10600
10601       n, frame_num
10602           The frame number, starting from 0.
10603
10604       pict_type
10605           A one character description of the current picture type.
10606
10607       pts The timestamp of the current frame.  It can take up to three
10608           arguments.
10609
10610           The first argument is the format of the timestamp; it defaults to
10611           "flt" for seconds as a decimal number with microsecond accuracy;
10612           "hms" stands for a formatted [-]HH:MM:SS.mmm timestamp with
10613           millisecond accuracy.  "gmtime" stands for the timestamp of the
10614           frame formatted as UTC time; "localtime" stands for the timestamp
10615           of the frame formatted as local time zone time.
10616
10617           The second argument is an offset added to the timestamp.
10618
10619           If the format is set to "hms", a third argument "24HH" may be
10620           supplied to present the hour part of the formatted timestamp in 24h
10621           format (00-23).
10622
10623           If the format is set to "localtime" or "gmtime", a third argument
10624           may be supplied: a strftime() format string.  By default, YYYY-MM-
10625           DD HH:MM:SS format will be used.
10626
10627       Commands
10628
10629       This filter supports altering parameters via commands:
10630
10631       reinit
10632           Alter existing filter parameters.
10633
10634           Syntax for the argument is the same as for filter invocation, e.g.
10635
10636                   fontsize=56:fontcolor=green:text='Hello World'
10637
10638           Full filter invocation with sendcmd would look like this:
10639
10640                   sendcmd=c='56.0 drawtext reinit fontsize=56\:fontcolor=green\:text=Hello\\ World'
10641
10642       If the entire argument can't be parsed or applied as valid values then
10643       the filter will continue with its existing parameters.
10644
10645       Examples
10646
10647       •   Draw "Test Text" with font FreeSerif, using the default values for
10648           the optional parameters.
10649
10650                   drawtext="fontfile=/usr/share/fonts/truetype/freefont/FreeSerif.ttf: text='Test Text'"
10651
10652       •   Draw 'Test Text' with font FreeSerif of size 24 at position x=100
10653           and y=50 (counting from the top-left corner of the screen), text is
10654           yellow with a red box around it. Both the text and the box have an
10655           opacity of 20%.
10656
10657                   drawtext="fontfile=/usr/share/fonts/truetype/freefont/FreeSerif.ttf: text='Test Text':\
10658                             x=100: y=50: fontsize=24: fontcolor=yellow@0.2: box=1: boxcolor=red@0.2"
10659
10660           Note that the double quotes are not necessary if spaces are not
10661           used within the parameter list.
10662
10663       •   Show the text at the center of the video frame:
10664
10665                   drawtext="fontsize=30:fontfile=FreeSerif.ttf:text='hello world':x=(w-text_w)/2:y=(h-text_h)/2"
10666
10667       •   Show the text at a random position, switching to a new position
10668           every 30 seconds:
10669
10670                   drawtext="fontsize=30:fontfile=FreeSerif.ttf:text='hello world':x=if(eq(mod(t\,30)\,0)\,rand(0\,(w-text_w))\,x):y=if(eq(mod(t\,30)\,0)\,rand(0\,(h-text_h))\,y)"
10671
10672       •   Show a text line sliding from right to left in the last row of the
10673           video frame. The file LONG_LINE is assumed to contain a single line
10674           with no newlines.
10675
10676                   drawtext="fontsize=15:fontfile=FreeSerif.ttf:text=LONG_LINE:y=h-line_h:x=-50*t"
10677
10678       •   Show the content of file CREDITS off the bottom of the frame and
10679           scroll up.
10680
10681                   drawtext="fontsize=20:fontfile=FreeSerif.ttf:textfile=CREDITS:y=h-20*t"
10682
10683       •   Draw a single green letter "g", at the center of the input video.
10684           The glyph baseline is placed at half screen height.
10685
10686                   drawtext="fontsize=60:fontfile=FreeSerif.ttf:fontcolor=green:text=g:x=(w-max_glyph_w)/2:y=h/2-ascent"
10687
10688       •   Show text for 1 second every 3 seconds:
10689
10690                   drawtext="fontfile=FreeSerif.ttf:fontcolor=white:x=100:y=x/dar:enable=lt(mod(t\,3)\,1):text='blink'"
10691
10692       •   Use fontconfig to set the font. Note that the colons need to be
10693           escaped.
10694
10695                   drawtext='fontfile=Linux Libertine O-40\:style=Semibold:text=FFmpeg'
10696
10697       •   Draw "Test Text" with font size dependent on height of the video.
10698
10699                   drawtext="text='Test Text': fontsize=h/30: x=(w-text_w)/2: y=(h-text_h*2)"
10700
10701       •   Print the date of a real-time encoding (see strftime(3)):
10702
10703                   drawtext='fontfile=FreeSans.ttf:text=%{localtime\:%a %b %d %Y}'
10704
10705       •   Show text fading in and out (appearing/disappearing):
10706
10707                   #!/bin/sh
10708                   DS=1.0 # display start
10709                   DE=10.0 # display end
10710                   FID=1.5 # fade in duration
10711                   FOD=5 # fade out duration
10712                   ffplay -f lavfi "color,drawtext=text=TEST:fontsize=50:fontfile=FreeSerif.ttf:fontcolor_expr=ff0000%{eif\\\\: clip(255*(1*between(t\\, $DS + $FID\\, $DE - $FOD) + ((t - $DS)/$FID)*between(t\\, $DS\\, $DS + $FID) + (-(t - $DE)/$FOD)*between(t\\, $DE - $FOD\\, $DE) )\\, 0\\, 255) \\\\: x\\\\: 2 }"
10713
10714       •   Horizontally align multiple separate texts. Note that max_glyph_a
10715           and the fontsize value are included in the y offset.
10716
10717                   drawtext=fontfile=FreeSans.ttf:text=DOG:fontsize=24:x=10:y=20+24-max_glyph_a,
10718                   drawtext=fontfile=FreeSans.ttf:text=cow:fontsize=24:x=80:y=20+24-max_glyph_a
10719
10720       •   Plot special lavf.image2dec.source_basename metadata onto each
10721           frame if such metadata exists. Otherwise, plot the string "NA".
10722           Note that image2 demuxer must have option -export_path_metadata 1
10723           for the special metadata fields to be available for filters.
10724
10725                   drawtext="fontsize=20:fontcolor=white:fontfile=FreeSans.ttf:text='%{metadata\:lavf.image2dec.source_basename\:NA}':x=10:y=10"
10726
10727       For more information about libfreetype, check:
10728       <http://www.freetype.org/>.
10729
10730       For more information about fontconfig, check:
10731       <http://freedesktop.org/software/fontconfig/fontconfig-user.html>.
10732
10733       For more information about libfribidi, check: <http://fribidi.org/>.
10734
10735   edgedetect
10736       Detect and draw edges. The filter uses the Canny Edge Detection
10737       algorithm.
10738
10739       The filter accepts the following options:
10740
10741       low
10742       high
10743           Set low and high threshold values used by the Canny thresholding
10744           algorithm.
10745
10746           The high threshold selects the "strong" edge pixels, which are then
10747           connected through 8-connectivity with the "weak" edge pixels
10748           selected by the low threshold.
10749
10750           low and high threshold values must be chosen in the range [0,1],
10751           and low should be lesser or equal to high.
10752
10753           Default value for low is "20/255", and default value for high is
10754           "50/255".
10755
10756       mode
10757           Define the drawing mode.
10758
10759           wires
10760               Draw white/gray wires on black background.
10761
10762           colormix
10763               Mix the colors to create a paint/cartoon effect.
10764
10765           canny
10766               Apply Canny edge detector on all selected planes.
10767
10768           Default value is wires.
10769
10770       planes
10771           Select planes for filtering. By default all available planes are
10772           filtered.
10773
10774       Examples
10775
10776       •   Standard edge detection with custom values for the hysteresis
10777           thresholding:
10778
10779                   edgedetect=low=0.1:high=0.4
10780
10781       •   Painting effect without thresholding:
10782
10783                   edgedetect=mode=colormix:high=0
10784
10785   elbg
10786       Apply a posterize effect using the ELBG (Enhanced LBG) algorithm.
10787
10788       For each input image, the filter will compute the optimal mapping from
10789       the input to the output given the codebook length, that is the number
10790       of distinct output colors.
10791
10792       This filter accepts the following options.
10793
10794       codebook_length, l
10795           Set codebook length. The value must be a positive integer, and
10796           represents the number of distinct output colors. Default value is
10797           256.
10798
10799       nb_steps, n
10800           Set the maximum number of iterations to apply for computing the
10801           optimal mapping. The higher the value the better the result and the
10802           higher the computation time. Default value is 1.
10803
10804       seed, s
10805           Set a random seed, must be an integer included between 0 and
10806           UINT32_MAX. If not specified, or if explicitly set to -1, the
10807           filter will try to use a good random seed on a best effort basis.
10808
10809       pal8
10810           Set pal8 output pixel format. This option does not work with
10811           codebook length greater than 256. Default is disabled.
10812
10813       use_alpha
10814           Include alpha values in the quantization calculation. Allows
10815           creating palettized output images (e.g. PNG8) with multiple alpha
10816           smooth blending.
10817
10818   entropy
10819       Measure graylevel entropy in histogram of color channels of video
10820       frames.
10821
10822       It accepts the following parameters:
10823
10824       mode
10825           Can be either normal or diff. Default is normal.
10826
10827           diff mode measures entropy of histogram delta values, absolute
10828           differences between neighbour histogram values.
10829
10830   epx
10831       Apply the EPX magnification filter which is designed for pixel art.
10832
10833       It accepts the following option:
10834
10835       n   Set the scaling dimension: 2 for "2xEPX", 3 for "3xEPX".  Default
10836           is 3.
10837
10838   eq
10839       Set brightness, contrast, saturation and approximate gamma adjustment.
10840
10841       The filter accepts the following options:
10842
10843       contrast
10844           Set the contrast expression. The value must be a float value in
10845           range "-1000.0" to 1000.0. The default value is "1".
10846
10847       brightness
10848           Set the brightness expression. The value must be a float value in
10849           range "-1.0" to 1.0. The default value is "0".
10850
10851       saturation
10852           Set the saturation expression. The value must be a float in range
10853           0.0 to 3.0. The default value is "1".
10854
10855       gamma
10856           Set the gamma expression. The value must be a float in range 0.1 to
10857           10.0.  The default value is "1".
10858
10859       gamma_r
10860           Set the gamma expression for red. The value must be a float in
10861           range 0.1 to 10.0. The default value is "1".
10862
10863       gamma_g
10864           Set the gamma expression for green. The value must be a float in
10865           range 0.1 to 10.0. The default value is "1".
10866
10867       gamma_b
10868           Set the gamma expression for blue. The value must be a float in
10869           range 0.1 to 10.0. The default value is "1".
10870
10871       gamma_weight
10872           Set the gamma weight expression. It can be used to reduce the
10873           effect of a high gamma value on bright image areas, e.g. keep them
10874           from getting overamplified and just plain white. The value must be
10875           a float in range 0.0 to 1.0. A value of 0.0 turns the gamma
10876           correction all the way down while 1.0 leaves it at its full
10877           strength. Default is "1".
10878
10879       eval
10880           Set when the expressions for brightness, contrast, saturation and
10881           gamma expressions are evaluated.
10882
10883           It accepts the following values:
10884
10885           init
10886               only evaluate expressions once during the filter initialization
10887               or when a command is processed
10888
10889           frame
10890               evaluate expressions for each incoming frame
10891
10892           Default value is init.
10893
10894       The expressions accept the following parameters:
10895
10896       n   frame count of the input frame starting from 0
10897
10898       pos byte position of the corresponding packet in the input file, NAN if
10899           unspecified
10900
10901       r   frame rate of the input video, NAN if the input frame rate is
10902           unknown
10903
10904       t   timestamp expressed in seconds, NAN if the input timestamp is
10905           unknown
10906
10907       Commands
10908
10909       The filter supports the following commands:
10910
10911       contrast
10912           Set the contrast expression.
10913
10914       brightness
10915           Set the brightness expression.
10916
10917       saturation
10918           Set the saturation expression.
10919
10920       gamma
10921           Set the gamma expression.
10922
10923       gamma_r
10924           Set the gamma_r expression.
10925
10926       gamma_g
10927           Set gamma_g expression.
10928
10929       gamma_b
10930           Set gamma_b expression.
10931
10932       gamma_weight
10933           Set gamma_weight expression.
10934
10935           The command accepts the same syntax of the corresponding option.
10936
10937           If the specified expression is not valid, it is kept at its current
10938           value.
10939
10940   erosion
10941       Apply erosion effect to the video.
10942
10943       This filter replaces the pixel by the local(3x3) minimum.
10944
10945       It accepts the following options:
10946
10947       threshold0
10948       threshold1
10949       threshold2
10950       threshold3
10951           Limit the maximum change for each plane, default is 65535.  If 0,
10952           plane will remain unchanged.
10953
10954       coordinates
10955           Flag which specifies the pixel to refer to. Default is 255 i.e. all
10956           eight pixels are used.
10957
10958           Flags to local 3x3 coordinates maps like this:
10959
10960               1 2 3
10961               4   5
10962               6 7 8
10963
10964       Commands
10965
10966       This filter supports the all above options as commands.
10967
10968   estdif
10969       Deinterlace the input video ("estdif" stands for "Edge Slope Tracing
10970       Deinterlacing Filter").
10971
10972       Spatial only filter that uses edge slope tracing algorithm to
10973       interpolate missing lines.  It accepts the following parameters:
10974
10975       mode
10976           The interlacing mode to adopt. It accepts one of the following
10977           values:
10978
10979           frame
10980               Output one frame for each frame.
10981
10982           field
10983               Output one frame for each field.
10984
10985           The default value is "field".
10986
10987       parity
10988           The picture field parity assumed for the input interlaced video. It
10989           accepts one of the following values:
10990
10991           tff Assume the top field is first.
10992
10993           bff Assume the bottom field is first.
10994
10995           auto
10996               Enable automatic detection of field parity.
10997
10998           The default value is "auto".  If the interlacing is unknown or the
10999           decoder does not export this information, top field first will be
11000           assumed.
11001
11002       deint
11003           Specify which frames to deinterlace. Accepts one of the following
11004           values:
11005
11006           all Deinterlace all frames.
11007
11008           interlaced
11009               Only deinterlace frames marked as interlaced.
11010
11011           The default value is "all".
11012
11013       rslope
11014           Specify the search radius for edge slope tracing. Default value is
11015           1.  Allowed range is from 1 to 15.
11016
11017       redge
11018           Specify the search radius for best edge matching. Default value is
11019           2.  Allowed range is from 0 to 15.
11020
11021       ecost
11022           Specify the edge cost for edge matching. Default value is 1.0.
11023           Allowed range is from 0 to 9.
11024
11025       mcost
11026           Specify the middle cost for edge matching. Default value is 0.5.
11027           Allowed range is from 0 to 1.
11028
11029       dcost
11030           Specify the distance cost for edge matching. Default value is 0.5.
11031           Allowed range is from 0 to 1.
11032
11033       interp
11034           Specify the interpolation used. Default is 4-point interpolation.
11035           It accepts one of the following values:
11036
11037           2p  Two-point interpolation.
11038
11039           4p  Four-point interpolation.
11040
11041           6p  Six-point interpolation.
11042
11043       Commands
11044
11045       This filter supports same commands as options.
11046
11047   exposure
11048       Adjust exposure of the video stream.
11049
11050       The filter accepts the following options:
11051
11052       exposure
11053           Set the exposure correction in EV. Allowed range is from -3.0 to
11054           3.0 EV Default value is 0 EV.
11055
11056       black
11057           Set the black level correction. Allowed range is from -1.0 to 1.0.
11058           Default value is 0.
11059
11060       Commands
11061
11062       This filter supports same commands as options.
11063
11064   extractplanes
11065       Extract color channel components from input video stream into separate
11066       grayscale video streams.
11067
11068       The filter accepts the following option:
11069
11070       planes
11071           Set plane(s) to extract.
11072
11073           Available values for planes are:
11074
11075           y
11076           u
11077           v
11078           a
11079           r
11080           g
11081           b
11082
11083           Choosing planes not available in the input will result in an error.
11084           That means you cannot select "r", "g", "b" planes with "y", "u",
11085           "v" planes at same time.
11086
11087       Examples
11088
11089       •   Extract luma, u and v color channel component from input video
11090           frame into 3 grayscale outputs:
11091
11092                   ffmpeg -i video.avi -filter_complex 'extractplanes=y+u+v[y][u][v]' -map '[y]' y.avi -map '[u]' u.avi -map '[v]' v.avi
11093
11094   fade
11095       Apply a fade-in/out effect to the input video.
11096
11097       It accepts the following parameters:
11098
11099       type, t
11100           The effect type can be either "in" for a fade-in, or "out" for a
11101           fade-out effect.  Default is "in".
11102
11103       start_frame, s
11104           Specify the number of the frame to start applying the fade effect
11105           at. Default is 0.
11106
11107       nb_frames, n
11108           The number of frames that the fade effect lasts. At the end of the
11109           fade-in effect, the output video will have the same intensity as
11110           the input video.  At the end of the fade-out transition, the output
11111           video will be filled with the selected color.  Default is 25.
11112
11113       alpha
11114           If set to 1, fade only alpha channel, if one exists on the input.
11115           Default value is 0.
11116
11117       start_time, st
11118           Specify the timestamp (in seconds) of the frame to start to apply
11119           the fade effect. If both start_frame and start_time are specified,
11120           the fade will start at whichever comes last.  Default is 0.
11121
11122       duration, d
11123           The number of seconds for which the fade effect has to last. At the
11124           end of the fade-in effect the output video will have the same
11125           intensity as the input video, at the end of the fade-out transition
11126           the output video will be filled with the selected color.  If both
11127           duration and nb_frames are specified, duration is used. Default is
11128           0 (nb_frames is used by default).
11129
11130       color, c
11131           Specify the color of the fade. Default is "black".
11132
11133       Examples
11134
11135       •   Fade in the first 30 frames of video:
11136
11137                   fade=in:0:30
11138
11139           The command above is equivalent to:
11140
11141                   fade=t=in:s=0:n=30
11142
11143       •   Fade out the last 45 frames of a 200-frame video:
11144
11145                   fade=out:155:45
11146                   fade=type=out:start_frame=155:nb_frames=45
11147
11148       •   Fade in the first 25 frames and fade out the last 25 frames of a
11149           1000-frame video:
11150
11151                   fade=in:0:25, fade=out:975:25
11152
11153       •   Make the first 5 frames yellow, then fade in from frame 5-24:
11154
11155                   fade=in:5:20:color=yellow
11156
11157       •   Fade in alpha over first 25 frames of video:
11158
11159                   fade=in:0:25:alpha=1
11160
11161       •   Make the first 5.5 seconds black, then fade in for 0.5 seconds:
11162
11163                   fade=t=in:st=5.5:d=0.5
11164
11165   feedback
11166       Apply feedback video filter.
11167
11168       This filter pass cropped input frames to 2nd output.  From there it can
11169       be filtered with other video filters.  After filter receives frame from
11170       2nd input, that frame is combined on top of original frame from 1st
11171       input and passed to 1st output.
11172
11173       The typical usage is filter only part of frame.
11174
11175       The filter accepts the following options:
11176
11177       x
11178       y   Set the top left crop position.
11179
11180       w
11181       h   Set the crop size.
11182
11183       Examples
11184
11185       •   Blur only top left rectangular part of video frame size 100x100
11186           with gblur filter.
11187
11188                   [in][blurin]feedback=x=0:y=0:w=100:h=100[out][blurout];[blurout]gblur=8[blurin]
11189
11190       •   Draw black box on top left part of video frame of size 100x100 with
11191           drawbox filter.
11192
11193                   [in][blurin]feedback=x=0:y=0:w=100:h=100[out][blurout];[blurout]drawbox=x=0:y=0:w=100:h=100:t=100[blurin]
11194
11195   fftdnoiz
11196       Denoise frames using 3D FFT (frequency domain filtering).
11197
11198       The filter accepts the following options:
11199
11200       sigma
11201           Set the noise sigma constant. This sets denoising strength.
11202           Default value is 1. Allowed range is from 0 to 30.  Using very high
11203           sigma with low overlap may give blocking artifacts.
11204
11205       amount
11206           Set amount of denoising. By default all detected noise is reduced.
11207           Default value is 1. Allowed range is from 0 to 1.
11208
11209       block
11210           Set size of block in pixels, Default is 32, can be 8 to 256.
11211
11212       overlap
11213           Set block overlap. Default is 0.5. Allowed range is from 0.2 to
11214           0.8.
11215
11216       method
11217           Set denoising method. Default is "wiener", can also be "hard".
11218
11219       prev
11220           Set number of previous frames to use for denoising. By default is
11221           set to 0.
11222
11223       next
11224           Set number of next frames to to use for denoising. By default is
11225           set to 0.
11226
11227       planes
11228           Set planes which will be filtered, by default are all available
11229           filtered except alpha.
11230
11231   fftfilt
11232       Apply arbitrary expressions to samples in frequency domain
11233
11234       dc_Y
11235           Adjust the dc value (gain) of the luma plane of the image. The
11236           filter accepts an integer value in range 0 to 1000. The default
11237           value is set to 0.
11238
11239       dc_U
11240           Adjust the dc value (gain) of the 1st chroma plane of the image.
11241           The filter accepts an integer value in range 0 to 1000. The default
11242           value is set to 0.
11243
11244       dc_V
11245           Adjust the dc value (gain) of the 2nd chroma plane of the image.
11246           The filter accepts an integer value in range 0 to 1000. The default
11247           value is set to 0.
11248
11249       weight_Y
11250           Set the frequency domain weight expression for the luma plane.
11251
11252       weight_U
11253           Set the frequency domain weight expression for the 1st chroma
11254           plane.
11255
11256       weight_V
11257           Set the frequency domain weight expression for the 2nd chroma
11258           plane.
11259
11260       eval
11261           Set when the expressions are evaluated.
11262
11263           It accepts the following values:
11264
11265           init
11266               Only evaluate expressions once during the filter
11267               initialization.
11268
11269           frame
11270               Evaluate expressions for each incoming frame.
11271
11272           Default value is init.
11273
11274           The filter accepts the following variables:
11275
11276       X
11277       Y   The coordinates of the current sample.
11278
11279       W
11280       H   The width and height of the image.
11281
11282       N   The number of input frame, starting from 0.
11283
11284       WS
11285       HS  The size of FFT array for horizontal and vertical processing.
11286
11287       Examples
11288
11289       •   High-pass:
11290
11291                   fftfilt=dc_Y=128:weight_Y='squish(1-(Y+X)/100)'
11292
11293       •   Low-pass:
11294
11295                   fftfilt=dc_Y=0:weight_Y='squish((Y+X)/100-1)'
11296
11297       •   Sharpen:
11298
11299                   fftfilt=dc_Y=0:weight_Y='1+squish(1-(Y+X)/100)'
11300
11301       •   Blur:
11302
11303                   fftfilt=dc_Y=0:weight_Y='exp(-4 * ((Y+X)/(W+H)))'
11304
11305   field
11306       Extract a single field from an interlaced image using stride arithmetic
11307       to avoid wasting CPU time. The output frames are marked as non-
11308       interlaced.
11309
11310       The filter accepts the following options:
11311
11312       type
11313           Specify whether to extract the top (if the value is 0 or "top") or
11314           the bottom field (if the value is 1 or "bottom").
11315
11316   fieldhint
11317       Create new frames by copying the top and bottom fields from surrounding
11318       frames supplied as numbers by the hint file.
11319
11320       hint
11321           Set file containing hints: absolute/relative frame numbers.
11322
11323           There must be one line for each frame in a clip. Each line must
11324           contain two numbers separated by the comma, optionally followed by
11325           "-" or "+".  Numbers supplied on each line of file can not be out
11326           of [N-1,N+1] where N is current frame number for "absolute" mode or
11327           out of [-1, 1] range for "relative" mode. First number tells from
11328           which frame to pick up top field and second number tells from which
11329           frame to pick up bottom field.
11330
11331           If optionally followed by "+" output frame will be marked as
11332           interlaced, else if followed by "-" output frame will be marked as
11333           progressive, else it will be marked same as input frame.  If
11334           optionally followed by "t" output frame will use only top field, or
11335           in case of "b" it will use only bottom field.  If line starts with
11336           "#" or ";" that line is skipped.
11337
11338       mode
11339           Can be item "absolute" or "relative" or "pattern". Default is
11340           "absolute".  The "pattern" mode is same as "relative" mode, except
11341           at last entry of file if there are more frames to process than
11342           "hint" file is seek back to start.
11343
11344       Example of first several lines of "hint" file for "relative" mode:
11345
11346               0,0 - # first frame
11347               1,0 - # second frame, use third's frame top field and second's frame bottom field
11348               1,0 - # third frame, use fourth's frame top field and third's frame bottom field
11349               1,0 -
11350               0,0 -
11351               0,0 -
11352               1,0 -
11353               1,0 -
11354               1,0 -
11355               0,0 -
11356               0,0 -
11357               1,0 -
11358               1,0 -
11359               1,0 -
11360               0,0 -
11361
11362   fieldmatch
11363       Field matching filter for inverse telecine. It is meant to reconstruct
11364       the progressive frames from a telecined stream. The filter does not
11365       drop duplicated frames, so to achieve a complete inverse telecine
11366       "fieldmatch" needs to be followed by a decimation filter such as
11367       decimate in the filtergraph.
11368
11369       The separation of the field matching and the decimation is notably
11370       motivated by the possibility of inserting a de-interlacing filter
11371       fallback between the two.  If the source has mixed telecined and real
11372       interlaced content, "fieldmatch" will not be able to match fields for
11373       the interlaced parts.  But these remaining combed frames will be marked
11374       as interlaced, and thus can be de-interlaced by a later filter such as
11375       yadif before decimation.
11376
11377       In addition to the various configuration options, "fieldmatch" can take
11378       an optional second stream, activated through the ppsrc option. If
11379       enabled, the frames reconstruction will be based on the fields and
11380       frames from this second stream. This allows the first input to be pre-
11381       processed in order to help the various algorithms of the filter, while
11382       keeping the output lossless (assuming the fields are matched properly).
11383       Typically, a field-aware denoiser, or brightness/contrast adjustments
11384       can help.
11385
11386       Note that this filter uses the same algorithms as TIVTC/TFM (AviSynth
11387       project) and VIVTC/VFM (VapourSynth project). The later is a light
11388       clone of TFM from which "fieldmatch" is based on. While the semantic
11389       and usage are very close, some behaviour and options names can differ.
11390
11391       The decimate filter currently only works for constant frame rate input.
11392       If your input has mixed telecined (30fps) and progressive content with
11393       a lower framerate like 24fps use the following filterchain to produce
11394       the necessary cfr stream:
11395       "dejudder,fps=30000/1001,fieldmatch,decimate".
11396
11397       The filter accepts the following options:
11398
11399       order
11400           Specify the assumed field order of the input stream. Available
11401           values are:
11402
11403           auto
11404               Auto detect parity (use FFmpeg's internal parity value).
11405
11406           bff Assume bottom field first.
11407
11408           tff Assume top field first.
11409
11410           Note that it is sometimes recommended not to trust the parity
11411           announced by the stream.
11412
11413           Default value is auto.
11414
11415       mode
11416           Set the matching mode or strategy to use. pc mode is the safest in
11417           the sense that it won't risk creating jerkiness due to duplicate
11418           frames when possible, but if there are bad edits or blended fields
11419           it will end up outputting combed frames when a good match might
11420           actually exist. On the other hand, pcn_ub mode is the most risky in
11421           terms of creating jerkiness, but will almost always find a good
11422           frame if there is one. The other values are all somewhere in
11423           between pc and pcn_ub in terms of risking jerkiness and creating
11424           duplicate frames versus finding good matches in sections with bad
11425           edits, orphaned fields, blended fields, etc.
11426
11427           More details about p/c/n/u/b are available in p/c/n/u/b meaning
11428           section.
11429
11430           Available values are:
11431
11432           pc  2-way matching (p/c)
11433
11434           pc_n
11435               2-way matching, and trying 3rd match if still combed (p/c + n)
11436
11437           pc_u
11438               2-way matching, and trying 3rd match (same order) if still
11439               combed (p/c + u)
11440
11441           pc_n_ub
11442               2-way matching, trying 3rd match if still combed, and trying
11443               4th/5th matches if still combed (p/c + n + u/b)
11444
11445           pcn 3-way matching (p/c/n)
11446
11447           pcn_ub
11448               3-way matching, and trying 4th/5th matches if all 3 of the
11449               original matches are detected as combed (p/c/n + u/b)
11450
11451           The parenthesis at the end indicate the matches that would be used
11452           for that mode assuming order=tff (and field on auto or top).
11453
11454           In terms of speed pc mode is by far the fastest and pcn_ub is the
11455           slowest.
11456
11457           Default value is pc_n.
11458
11459       ppsrc
11460           Mark the main input stream as a pre-processed input, and enable the
11461           secondary input stream as the clean source to pick the fields from.
11462           See the filter introduction for more details. It is similar to the
11463           clip2 feature from VFM/TFM.
11464
11465           Default value is 0 (disabled).
11466
11467       field
11468           Set the field to match from. It is recommended to set this to the
11469           same value as order unless you experience matching failures with
11470           that setting. In certain circumstances changing the field that is
11471           used to match from can have a large impact on matching performance.
11472           Available values are:
11473
11474           auto
11475               Automatic (same value as order).
11476
11477           bottom
11478               Match from the bottom field.
11479
11480           top Match from the top field.
11481
11482           Default value is auto.
11483
11484       mchroma
11485           Set whether or not chroma is included during the match comparisons.
11486           In most cases it is recommended to leave this enabled. You should
11487           set this to 0 only if your clip has bad chroma problems such as
11488           heavy rainbowing or other artifacts. Setting this to 0 could also
11489           be used to speed things up at the cost of some accuracy.
11490
11491           Default value is 1.
11492
11493       y0
11494       y1  These define an exclusion band which excludes the lines between y0
11495           and y1 from being included in the field matching decision. An
11496           exclusion band can be used to ignore subtitles, a logo, or other
11497           things that may interfere with the matching. y0 sets the starting
11498           scan line and y1 sets the ending line; all lines in between y0 and
11499           y1 (including y0 and y1) will be ignored. Setting y0 and y1 to the
11500           same value will disable the feature.  y0 and y1 defaults to 0.
11501
11502       scthresh
11503           Set the scene change detection threshold as a percentage of maximum
11504           change on the luma plane. Good values are in the "[8.0, 14.0]"
11505           range. Scene change detection is only relevant in case
11506           combmatch=sc.  The range for scthresh is "[0.0, 100.0]".
11507
11508           Default value is 12.0.
11509
11510       combmatch
11511           When combatch is not none, "fieldmatch" will take into account the
11512           combed scores of matches when deciding what match to use as the
11513           final match. Available values are:
11514
11515           none
11516               No final matching based on combed scores.
11517
11518           sc  Combed scores are only used when a scene change is detected.
11519
11520           full
11521               Use combed scores all the time.
11522
11523           Default is sc.
11524
11525       combdbg
11526           Force "fieldmatch" to calculate the combed metrics for certain
11527           matches and print them. This setting is known as micout in TFM/VFM
11528           vocabulary.  Available values are:
11529
11530           none
11531               No forced calculation.
11532
11533           pcn Force p/c/n calculations.
11534
11535           pcnub
11536               Force p/c/n/u/b calculations.
11537
11538           Default value is none.
11539
11540       cthresh
11541           This is the area combing threshold used for combed frame detection.
11542           This essentially controls how "strong" or "visible" combing must be
11543           to be detected.  Larger values mean combing must be more visible
11544           and smaller values mean combing can be less visible or strong and
11545           still be detected. Valid settings are from "-1" (every pixel will
11546           be detected as combed) to 255 (no pixel will be detected as
11547           combed). This is basically a pixel difference value. A good range
11548           is "[8, 12]".
11549
11550           Default value is 9.
11551
11552       chroma
11553           Sets whether or not chroma is considered in the combed frame
11554           decision.  Only disable this if your source has chroma problems
11555           (rainbowing, etc.) that are causing problems for the combed frame
11556           detection with chroma enabled. Actually, using chroma=0 is usually
11557           more reliable, except for the case where there is chroma only
11558           combing in the source.
11559
11560           Default value is 0.
11561
11562       blockx
11563       blocky
11564           Respectively set the x-axis and y-axis size of the window used
11565           during combed frame detection. This has to do with the size of the
11566           area in which combpel pixels are required to be detected as combed
11567           for a frame to be declared combed. See the combpel parameter
11568           description for more info.  Possible values are any number that is
11569           a power of 2 starting at 4 and going up to 512.
11570
11571           Default value is 16.
11572
11573       combpel
11574           The number of combed pixels inside any of the blocky by blockx size
11575           blocks on the frame for the frame to be detected as combed. While
11576           cthresh controls how "visible" the combing must be, this setting
11577           controls "how much" combing there must be in any localized area (a
11578           window defined by the blockx and blocky settings) on the frame.
11579           Minimum value is 0 and maximum is "blocky x blockx" (at which point
11580           no frames will ever be detected as combed). This setting is known
11581           as MI in TFM/VFM vocabulary.
11582
11583           Default value is 80.
11584
11585       p/c/n/u/b meaning
11586
11587       p/c/n
11588
11589       We assume the following telecined stream:
11590
11591               Top fields:     1 2 2 3 4
11592               Bottom fields:  1 2 3 4 4
11593
11594       The numbers correspond to the progressive frame the fields relate to.
11595       Here, the first two frames are progressive, the 3rd and 4th are combed,
11596       and so on.
11597
11598       When "fieldmatch" is configured to run a matching from bottom
11599       (field=bottom) this is how this input stream get transformed:
11600
11601               Input stream:
11602                               T     1 2 2 3 4
11603                               B     1 2 3 4 4   <-- matching reference
11604
11605               Matches:              c c n n c
11606
11607               Output stream:
11608                               T     1 2 3 4 4
11609                               B     1 2 3 4 4
11610
11611       As a result of the field matching, we can see that some frames get
11612       duplicated.  To perform a complete inverse telecine, you need to rely
11613       on a decimation filter after this operation. See for instance the
11614       decimate filter.
11615
11616       The same operation now matching from top fields (field=top) looks like
11617       this:
11618
11619               Input stream:
11620                               T     1 2 2 3 4   <-- matching reference
11621                               B     1 2 3 4 4
11622
11623               Matches:              c c p p c
11624
11625               Output stream:
11626                               T     1 2 2 3 4
11627                               B     1 2 2 3 4
11628
11629       In these examples, we can see what p, c and n mean; basically, they
11630       refer to the frame and field of the opposite parity:
11631
11632       *<p matches the field of the opposite parity in the previous frame>
11633       *<c matches the field of the opposite parity in the current frame>
11634       *<n matches the field of the opposite parity in the next frame>
11635
11636       u/b
11637
11638       The u and b matching are a bit special in the sense that they match
11639       from the opposite parity flag. In the following examples, we assume
11640       that we are currently matching the 2nd frame (Top:2, bottom:2).
11641       According to the match, a 'x' is placed above and below each matched
11642       fields.
11643
11644       With bottom matching (field=bottom):
11645
11646               Match:           c         p           n          b          u
11647
11648                                x       x               x        x          x
11649                 Top          1 2 2     1 2 2       1 2 2      1 2 2      1 2 2
11650                 Bottom       1 2 3     1 2 3       1 2 3      1 2 3      1 2 3
11651                                x         x           x        x              x
11652
11653               Output frames:
11654                                2          1          2          2          2
11655                                2          2          2          1          3
11656
11657       With top matching (field=top):
11658
11659               Match:           c         p           n          b          u
11660
11661                                x         x           x        x              x
11662                 Top          1 2 2     1 2 2       1 2 2      1 2 2      1 2 2
11663                 Bottom       1 2 3     1 2 3       1 2 3      1 2 3      1 2 3
11664                                x       x               x        x          x
11665
11666               Output frames:
11667                                2          2          2          1          2
11668                                2          1          3          2          2
11669
11670       Examples
11671
11672       Simple IVTC of a top field first telecined stream:
11673
11674               fieldmatch=order=tff:combmatch=none, decimate
11675
11676       Advanced IVTC, with fallback on yadif for still combed frames:
11677
11678               fieldmatch=order=tff:combmatch=full, yadif=deint=interlaced, decimate
11679
11680   fieldorder
11681       Transform the field order of the input video.
11682
11683       It accepts the following parameters:
11684
11685       order
11686           The output field order. Valid values are tff for top field first or
11687           bff for bottom field first.
11688
11689       The default value is tff.
11690
11691       The transformation is done by shifting the picture content up or down
11692       by one line, and filling the remaining line with appropriate picture
11693       content.  This method is consistent with most broadcast field order
11694       converters.
11695
11696       If the input video is not flagged as being interlaced, or it is already
11697       flagged as being of the required output field order, then this filter
11698       does not alter the incoming video.
11699
11700       It is very useful when converting to or from PAL DV material, which is
11701       bottom field first.
11702
11703       For example:
11704
11705               ffmpeg -i in.vob -vf "fieldorder=bff" out.dv
11706
11707   fifo, afifo
11708       Buffer input images and send them when they are requested.
11709
11710       It is mainly useful when auto-inserted by the libavfilter framework.
11711
11712       It does not take parameters.
11713
11714   fillborders
11715       Fill borders of the input video, without changing video stream
11716       dimensions.  Sometimes video can have garbage at the four edges and you
11717       may not want to crop video input to keep size multiple of some number.
11718
11719       This filter accepts the following options:
11720
11721       left
11722           Number of pixels to fill from left border.
11723
11724       right
11725           Number of pixels to fill from right border.
11726
11727       top Number of pixels to fill from top border.
11728
11729       bottom
11730           Number of pixels to fill from bottom border.
11731
11732       mode
11733           Set fill mode.
11734
11735           It accepts the following values:
11736
11737           smear
11738               fill pixels using outermost pixels
11739
11740           mirror
11741               fill pixels using mirroring (half sample symmetric)
11742
11743           fixed
11744               fill pixels with constant value
11745
11746           reflect
11747               fill pixels using reflecting (whole sample symmetric)
11748
11749           wrap
11750               fill pixels using wrapping
11751
11752           fade
11753               fade pixels to constant value
11754
11755           margins
11756               fill pixels at top and bottom with weighted averages pixels
11757               near borders
11758
11759           Default is smear.
11760
11761       color
11762           Set color for pixels in fixed or fade mode. Default is black.
11763
11764       Commands
11765
11766       This filter supports same commands as options.  The command accepts the
11767       same syntax of the corresponding option.
11768
11769       If the specified expression is not valid, it is kept at its current
11770       value.
11771
11772   find_rect
11773       Find a rectangular object
11774
11775       It accepts the following options:
11776
11777       object
11778           Filepath of the object image, needs to be in gray8.
11779
11780       threshold
11781           Detection threshold, default is 0.5.
11782
11783       mipmaps
11784           Number of mipmaps, default is 3.
11785
11786       xmin, ymin, xmax, ymax
11787           Specifies the rectangle in which to search.
11788
11789       discard
11790           Discard frames where object is not detected. Default is disabled.
11791
11792       Examples
11793
11794       •   Cover a rectangular object by the supplied image of a given video
11795           using ffmpeg:
11796
11797                   ffmpeg -i file.ts -vf find_rect=newref.pgm,cover_rect=cover.jpg:mode=cover new.mkv
11798
11799   floodfill
11800       Flood area with values of same pixel components with another values.
11801
11802       It accepts the following options:
11803
11804       x   Set pixel x coordinate.
11805
11806       y   Set pixel y coordinate.
11807
11808       s0  Set source #0 component value.
11809
11810       s1  Set source #1 component value.
11811
11812       s2  Set source #2 component value.
11813
11814       s3  Set source #3 component value.
11815
11816       d0  Set destination #0 component value.
11817
11818       d1  Set destination #1 component value.
11819
11820       d2  Set destination #2 component value.
11821
11822       d3  Set destination #3 component value.
11823
11824   format
11825       Convert the input video to one of the specified pixel formats.
11826       Libavfilter will try to pick one that is suitable as input to the next
11827       filter.
11828
11829       It accepts the following parameters:
11830
11831       pix_fmts
11832           A '|'-separated list of pixel format names, such as
11833           "pix_fmts=yuv420p|monow|rgb24".
11834
11835       Examples
11836
11837       •   Convert the input video to the yuv420p format
11838
11839                   format=pix_fmts=yuv420p
11840
11841           Convert the input video to any of the formats in the list
11842
11843                   format=pix_fmts=yuv420p|yuv444p|yuv410p
11844
11845   fps
11846       Convert the video to specified constant frame rate by duplicating or
11847       dropping frames as necessary.
11848
11849       It accepts the following parameters:
11850
11851       fps The desired output frame rate. It accepts expressions containing
11852           the following constants:
11853
11854           source_fps
11855               The input's frame rate
11856
11857           ntsc
11858               NTSC frame rate of "30000/1001"
11859
11860           pal PAL frame rate of 25.0
11861
11862           film
11863               Film frame rate of 24.0
11864
11865           ntsc_film
11866               NTSC-film frame rate of "24000/1001"
11867
11868           The default is 25.
11869
11870       start_time
11871           Assume the first PTS should be the given value, in seconds. This
11872           allows for padding/trimming at the start of stream. By default, no
11873           assumption is made about the first frame's expected PTS, so no
11874           padding or trimming is done.  For example, this could be set to 0
11875           to pad the beginning with duplicates of the first frame if a video
11876           stream starts after the audio stream or to trim any frames with a
11877           negative PTS.
11878
11879       round
11880           Timestamp (PTS) rounding method.
11881
11882           Possible values are:
11883
11884           zero
11885               round towards 0
11886
11887           inf round away from 0
11888
11889           down
11890               round towards -infinity
11891
11892           up  round towards +infinity
11893
11894           near
11895               round to nearest
11896
11897           The default is "near".
11898
11899       eof_action
11900           Action performed when reading the last frame.
11901
11902           Possible values are:
11903
11904           round
11905               Use same timestamp rounding method as used for other frames.
11906
11907           pass
11908               Pass through last frame if input duration has not been reached
11909               yet.
11910
11911           The default is "round".
11912
11913       Alternatively, the options can be specified as a flat string:
11914       fps[:start_time[:round]].
11915
11916       See also the setpts filter.
11917
11918       Examples
11919
11920       •   A typical usage in order to set the fps to 25:
11921
11922                   fps=fps=25
11923
11924       •   Sets the fps to 24, using abbreviation and rounding method to round
11925           to nearest:
11926
11927                   fps=fps=film:round=near
11928
11929   framepack
11930       Pack two different video streams into a stereoscopic video, setting
11931       proper metadata on supported codecs. The two views should have the same
11932       size and framerate and processing will stop when the shorter video
11933       ends. Please note that you may conveniently adjust view properties with
11934       the scale and fps filters.
11935
11936       It accepts the following parameters:
11937
11938       format
11939           The desired packing format. Supported values are:
11940
11941           sbs The views are next to each other (default).
11942
11943           tab The views are on top of each other.
11944
11945           lines
11946               The views are packed by line.
11947
11948           columns
11949               The views are packed by column.
11950
11951           frameseq
11952               The views are temporally interleaved.
11953
11954       Some examples:
11955
11956               # Convert left and right views into a frame-sequential video
11957               ffmpeg -i LEFT -i RIGHT -filter_complex framepack=frameseq OUTPUT
11958
11959               # Convert views into a side-by-side video with the same output resolution as the input
11960               ffmpeg -i LEFT -i RIGHT -filter_complex [0:v]scale=w=iw/2[left],[1:v]scale=w=iw/2[right],[left][right]framepack=sbs OUTPUT
11961
11962   framerate
11963       Change the frame rate by interpolating new video output frames from the
11964       source frames.
11965
11966       This filter is not designed to function correctly with interlaced
11967       media. If you wish to change the frame rate of interlaced media then
11968       you are required to deinterlace before this filter and re-interlace
11969       after this filter.
11970
11971       A description of the accepted options follows.
11972
11973       fps Specify the output frames per second. This option can also be
11974           specified as a value alone. The default is 50.
11975
11976       interp_start
11977           Specify the start of a range where the output frame will be created
11978           as a linear interpolation of two frames. The range is [0-255], the
11979           default is 15.
11980
11981       interp_end
11982           Specify the end of a range where the output frame will be created
11983           as a linear interpolation of two frames. The range is [0-255], the
11984           default is 240.
11985
11986       scene
11987           Specify the level at which a scene change is detected as a value
11988           between 0 and 100 to indicate a new scene; a low value reflects a
11989           low probability for the current frame to introduce a new scene,
11990           while a higher value means the current frame is more likely to be
11991           one.  The default is 8.2.
11992
11993       flags
11994           Specify flags influencing the filter process.
11995
11996           Available value for flags is:
11997
11998           scene_change_detect, scd
11999               Enable scene change detection using the value of the option
12000               scene.  This flag is enabled by default.
12001
12002   framestep
12003       Select one frame every N-th frame.
12004
12005       This filter accepts the following option:
12006
12007       step
12008           Select frame after every "step" frames.  Allowed values are
12009           positive integers higher than 0. Default value is 1.
12010
12011   freezedetect
12012       Detect frozen video.
12013
12014       This filter logs a message and sets frame metadata when it detects that
12015       the input video has no significant change in content during a specified
12016       duration.  Video freeze detection calculates the mean average absolute
12017       difference of all the components of video frames and compares it to a
12018       noise floor.
12019
12020       The printed times and duration are expressed in seconds. The
12021       "lavfi.freezedetect.freeze_start" metadata key is set on the first
12022       frame whose timestamp equals or exceeds the detection duration and it
12023       contains the timestamp of the first frame of the freeze. The
12024       "lavfi.freezedetect.freeze_duration" and
12025       "lavfi.freezedetect.freeze_end" metadata keys are set on the first
12026       frame after the freeze.
12027
12028       The filter accepts the following options:
12029
12030       noise, n
12031           Set noise tolerance. Can be specified in dB (in case "dB" is
12032           appended to the specified value) or as a difference ratio between 0
12033           and 1. Default is -60dB, or 0.001.
12034
12035       duration, d
12036           Set freeze duration until notification (default is 2 seconds).
12037
12038   freezeframes
12039       Freeze video frames.
12040
12041       This filter freezes video frames using frame from 2nd input.
12042
12043       The filter accepts the following options:
12044
12045       first
12046           Set number of first frame from which to start freeze.
12047
12048       last
12049           Set number of last frame from which to end freeze.
12050
12051       replace
12052           Set number of frame from 2nd input which will be used instead of
12053           replaced frames.
12054
12055   frei0r
12056       Apply a frei0r effect to the input video.
12057
12058       To enable the compilation of this filter, you need to install the
12059       frei0r header and configure FFmpeg with "--enable-frei0r".
12060
12061       It accepts the following parameters:
12062
12063       filter_name
12064           The name of the frei0r effect to load. If the environment variable
12065           FREI0R_PATH is defined, the frei0r effect is searched for in each
12066           of the directories specified by the colon-separated list in
12067           FREI0R_PATH.  Otherwise, the standard frei0r paths are searched, in
12068           this order: HOME/.frei0r-1/lib/, /usr/local/lib/frei0r-1/,
12069           /usr/lib/frei0r-1/.
12070
12071       filter_params
12072           A '|'-separated list of parameters to pass to the frei0r effect.
12073
12074       A frei0r effect parameter can be a boolean (its value is either "y" or
12075       "n"), a double, a color (specified as R/G/B, where R, G, and B are
12076       floating point numbers between 0.0 and 1.0, inclusive) or a color
12077       description as specified in the "Color" section in the ffmpeg-utils
12078       manual, a position (specified as X/Y, where X and Y are floating point
12079       numbers) and/or a string.
12080
12081       The number and types of parameters depend on the loaded effect. If an
12082       effect parameter is not specified, the default value is set.
12083
12084       Examples
12085
12086       •   Apply the distort0r effect, setting the first two double
12087           parameters:
12088
12089                   frei0r=filter_name=distort0r:filter_params=0.5|0.01
12090
12091       •   Apply the colordistance effect, taking a color as the first
12092           parameter:
12093
12094                   frei0r=colordistance:0.2/0.3/0.4
12095                   frei0r=colordistance:violet
12096                   frei0r=colordistance:0x112233
12097
12098       •   Apply the perspective effect, specifying the top left and top right
12099           image positions:
12100
12101                   frei0r=perspective:0.2/0.2|0.8/0.2
12102
12103       For more information, see <http://frei0r.dyne.org>
12104
12105       Commands
12106
12107       This filter supports the filter_params option as commands.
12108
12109   fspp
12110       Apply fast and simple postprocessing. It is a faster version of spp.
12111
12112       It splits (I)DCT into horizontal/vertical passes. Unlike the simple
12113       post- processing filter, one of them is performed once per block, not
12114       per pixel.  This allows for much higher speed.
12115
12116       The filter accepts the following options:
12117
12118       quality
12119           Set quality. This option defines the number of levels for
12120           averaging. It accepts an integer in the range 4-5. Default value is
12121           4.
12122
12123       qp  Force a constant quantization parameter. It accepts an integer in
12124           range 0-63.  If not set, the filter will use the QP from the video
12125           stream (if available).
12126
12127       strength
12128           Set filter strength. It accepts an integer in range -15 to 32.
12129           Lower values mean more details but also more artifacts, while
12130           higher values make the image smoother but also blurrier. Default
12131           value is 0 X PSNR optimal.
12132
12133       use_bframe_qp
12134           Enable the use of the QP from the B-Frames if set to 1. Using this
12135           option may cause flicker since the B-Frames have often larger QP.
12136           Default is 0 (not enabled).
12137
12138   gblur
12139       Apply Gaussian blur filter.
12140
12141       The filter accepts the following options:
12142
12143       sigma
12144           Set horizontal sigma, standard deviation of Gaussian blur. Default
12145           is 0.5.
12146
12147       steps
12148           Set number of steps for Gaussian approximation. Default is 1.
12149
12150       planes
12151           Set which planes to filter. By default all planes are filtered.
12152
12153       sigmaV
12154           Set vertical sigma, if negative it will be same as "sigma".
12155           Default is "-1".
12156
12157       Commands
12158
12159       This filter supports same commands as options.  The command accepts the
12160       same syntax of the corresponding option.
12161
12162       If the specified expression is not valid, it is kept at its current
12163       value.
12164
12165   geq
12166       Apply generic equation to each pixel.
12167
12168       The filter accepts the following options:
12169
12170       lum_expr, lum
12171           Set the luminance expression.
12172
12173       cb_expr, cb
12174           Set the chrominance blue expression.
12175
12176       cr_expr, cr
12177           Set the chrominance red expression.
12178
12179       alpha_expr, a
12180           Set the alpha expression.
12181
12182       red_expr, r
12183           Set the red expression.
12184
12185       green_expr, g
12186           Set the green expression.
12187
12188       blue_expr, b
12189           Set the blue expression.
12190
12191       The colorspace is selected according to the specified options. If one
12192       of the lum_expr, cb_expr, or cr_expr options is specified, the filter
12193       will automatically select a YCbCr colorspace. If one of the red_expr,
12194       green_expr, or blue_expr options is specified, it will select an RGB
12195       colorspace.
12196
12197       If one of the chrominance expression is not defined, it falls back on
12198       the other one. If no alpha expression is specified it will evaluate to
12199       opaque value.  If none of chrominance expressions are specified, they
12200       will evaluate to the luminance expression.
12201
12202       The expressions can use the following variables and functions:
12203
12204       N   The sequential number of the filtered frame, starting from 0.
12205
12206       X
12207       Y   The coordinates of the current sample.
12208
12209       W
12210       H   The width and height of the image.
12211
12212       SW
12213       SH  Width and height scale depending on the currently filtered plane.
12214           It is the ratio between the corresponding luma plane number of
12215           pixels and the current plane ones. E.g. for YUV4:2:0 the values are
12216           "1,1" for the luma plane, and "0.5,0.5" for chroma planes.
12217
12218       T   Time of the current frame, expressed in seconds.
12219
12220       p(x, y)
12221           Return the value of the pixel at location (x,y) of the current
12222           plane.
12223
12224       lum(x, y)
12225           Return the value of the pixel at location (x,y) of the luminance
12226           plane.
12227
12228       cb(x, y)
12229           Return the value of the pixel at location (x,y) of the blue-
12230           difference chroma plane. Return 0 if there is no such plane.
12231
12232       cr(x, y)
12233           Return the value of the pixel at location (x,y) of the red-
12234           difference chroma plane. Return 0 if there is no such plane.
12235
12236       r(x, y)
12237       g(x, y)
12238       b(x, y)
12239           Return the value of the pixel at location (x,y) of the
12240           red/green/blue component. Return 0 if there is no such component.
12241
12242       alpha(x, y)
12243           Return the value of the pixel at location (x,y) of the alpha plane.
12244           Return 0 if there is no such plane.
12245
12246       psum(x,y), lumsum(x, y), cbsum(x,y), crsum(x,y), rsum(x,y), gsum(x,y),
12247       bsum(x,y), alphasum(x,y)
12248           Sum of sample values in the rectangle from (0,0) to (x,y), this
12249           allows obtaining sums of samples within a rectangle. See the
12250           functions without the sum postfix.
12251
12252       interpolation
12253           Set one of interpolation methods:
12254
12255           nearest, n
12256           bilinear, b
12257
12258           Default is bilinear.
12259
12260       For functions, if x and y are outside the area, the value will be
12261       automatically clipped to the closer edge.
12262
12263       Please note that this filter can use multiple threads in which case
12264       each slice will have its own expression state. If you want to use only
12265       a single expression state because your expressions depend on previous
12266       state then you should limit the number of filter threads to 1.
12267
12268       Examples
12269
12270       •   Flip the image horizontally:
12271
12272                   geq=p(W-X\,Y)
12273
12274       •   Generate a bidimensional sine wave, with angle "PI/3" and a
12275           wavelength of 100 pixels:
12276
12277                   geq=128 + 100*sin(2*(PI/100)*(cos(PI/3)*(X-50*T) + sin(PI/3)*Y)):128:128
12278
12279       •   Generate a fancy enigmatic moving light:
12280
12281                   nullsrc=s=256x256,geq=random(1)/hypot(X-cos(N*0.07)*W/2-W/2\,Y-sin(N*0.09)*H/2-H/2)^2*1000000*sin(N*0.02):128:128
12282
12283       •   Generate a quick emboss effect:
12284
12285                   format=gray,geq=lum_expr='(p(X,Y)+(256-p(X-4,Y-4)))/2'
12286
12287       •   Modify RGB components depending on pixel position:
12288
12289                   geq=r='X/W*r(X,Y)':g='(1-X/W)*g(X,Y)':b='(H-Y)/H*b(X,Y)'
12290
12291       •   Create a radial gradient that is the same size as the input (also
12292           see the vignette filter):
12293
12294                   geq=lum=255*gauss((X/W-0.5)*3)*gauss((Y/H-0.5)*3)/gauss(0)/gauss(0),format=gray
12295
12296   gradfun
12297       Fix the banding artifacts that are sometimes introduced into nearly
12298       flat regions by truncation to 8-bit color depth.  Interpolate the
12299       gradients that should go where the bands are, and dither them.
12300
12301       It is designed for playback only.  Do not use it prior to lossy
12302       compression, because compression tends to lose the dither and bring
12303       back the bands.
12304
12305       It accepts the following parameters:
12306
12307       strength
12308           The maximum amount by which the filter will change any one pixel.
12309           This is also the threshold for detecting nearly flat regions.
12310           Acceptable values range from .51 to 64; the default value is 1.2.
12311           Out-of-range values will be clipped to the valid range.
12312
12313       radius
12314           The neighborhood to fit the gradient to. A larger radius makes for
12315           smoother gradients, but also prevents the filter from modifying the
12316           pixels near detailed regions. Acceptable values are 8-32; the
12317           default value is 16. Out-of-range values will be clipped to the
12318           valid range.
12319
12320       Alternatively, the options can be specified as a flat string:
12321       strength[:radius]
12322
12323       Examples
12324
12325       •   Apply the filter with a 3.5 strength and radius of 8:
12326
12327                   gradfun=3.5:8
12328
12329       •   Specify radius, omitting the strength (which will fall-back to the
12330           default value):
12331
12332                   gradfun=radius=8
12333
12334   graphmonitor
12335       Show various filtergraph stats.
12336
12337       With this filter one can debug complete filtergraph.  Especially issues
12338       with links filling with queued frames.
12339
12340       The filter accepts the following options:
12341
12342       size, s
12343           Set video output size. Default is hd720.
12344
12345       opacity, o
12346           Set video opacity. Default is 0.9. Allowed range is from 0 to 1.
12347
12348       mode, m
12349           Set output mode, can be fulll or compact.  In compact mode only
12350           filters with some queued frames have displayed stats.
12351
12352       flags, f
12353           Set flags which enable which stats are shown in video.
12354
12355           Available values for flags are:
12356
12357           queue
12358               Display number of queued frames in each link.
12359
12360           frame_count_in
12361               Display number of frames taken from filter.
12362
12363           frame_count_out
12364               Display number of frames given out from filter.
12365
12366           frame_count_delta
12367               Display delta number of frames between above two values.
12368
12369           pts Display current filtered frame pts.
12370
12371           pts_delta
12372               Display pts delta between current and previous frame.
12373
12374           time
12375               Display current filtered frame time.
12376
12377           time_delta
12378               Display time delta between current and previous frame.
12379
12380           timebase
12381               Display time base for filter link.
12382
12383           format
12384               Display used format for filter link.
12385
12386           size
12387               Display video size or number of audio channels in case of audio
12388               used by filter link.
12389
12390           rate
12391               Display video frame rate or sample rate in case of audio used
12392               by filter link.
12393
12394           eof Display link output status.
12395
12396           sample_count_in
12397               Display number of samples taken from filter.
12398
12399           sample_count_out
12400               Display number of samples given out from filter.
12401
12402           sample_count_delta
12403               Display delta number of samples between above two values.
12404
12405       rate, r
12406           Set upper limit for video rate of output stream, Default value is
12407           25.  This guarantee that output video frame rate will not be higher
12408           than this value.
12409
12410   grayworld
12411       A color constancy filter that applies color correction based on the
12412       grayworld assumption
12413
12414       See:
12415       <https://www.researchgate.net/publication/275213614_A_New_Color_Correction_Method_for_Underwater_Imaging>
12416
12417       The algorithm  uses linear light, so input data should be linearized
12418       beforehand (and possibly correctly tagged).
12419
12420               ffmpeg -i INPUT -vf zscale=transfer=linear,grayworld,zscale=transfer=bt709,format=yuv420p OUTPUT
12421
12422   greyedge
12423       A color constancy variation filter which estimates scene illumination
12424       via grey edge algorithm and corrects the scene colors accordingly.
12425
12426       See: <https://staff.science.uva.nl/th.gevers/pub/GeversTIP07.pdf>
12427
12428       The filter accepts the following options:
12429
12430       difford
12431           The order of differentiation to be applied on the scene. Must be
12432           chosen in the range [0,2] and default value is 1.
12433
12434       minknorm
12435           The Minkowski parameter to be used for calculating the Minkowski
12436           distance. Must be chosen in the range [0,20] and default value is
12437           1. Set to 0 for getting max value instead of calculating Minkowski
12438           distance.
12439
12440       sigma
12441           The standard deviation of Gaussian blur to be applied on the scene.
12442           Must be chosen in the range [0,1024.0] and default value = 1.
12443           floor( sigma * break_off_sigma(3) ) can't be equal to 0 if difford
12444           is greater than 0.
12445
12446       Examples
12447
12448       •   Grey Edge:
12449
12450                   greyedge=difford=1:minknorm=5:sigma=2
12451
12452       •   Max Edge:
12453
12454                   greyedge=difford=1:minknorm=0:sigma=2
12455
12456   guided
12457       Apply guided filter for edge-preserving smoothing, dehazing and so on.
12458
12459       The filter accepts the following options:
12460
12461       radius
12462           Set the box radius in pixels.  Allowed range is 1 to 20. Default is
12463           3.
12464
12465       eps Set regularization parameter (with square).  Allowed range is 0 to
12466           1. Default is 0.01.
12467
12468       mode
12469           Set filter mode. Can be "basic" or "fast".  Default is "basic".
12470
12471       sub Set subsampling ratio for "fast" mode.  Range is 2 to 64. Default
12472           is 4.  No subsampling occurs in "basic" mode.
12473
12474       guidance
12475           Set guidance mode. Can be "off" or "on". Default is "off".  If
12476           "off", single input is required.  If "on", two inputs of the same
12477           resolution and pixel format are required.  The second input serves
12478           as the guidance.
12479
12480       planes
12481           Set planes to filter. Default is first only.
12482
12483       Commands
12484
12485       This filter supports the all above options as commands.
12486
12487       Examples
12488
12489       •   Edge-preserving smoothing with guided filter:
12490
12491                   ffmpeg -i in.png -vf guided out.png
12492
12493       •   Dehazing, structure-transferring filtering, detail enhancement with
12494           guided filter.  For the generation of guidance image, refer to
12495           paper "Guided Image Filtering".  See:
12496           <http://kaiminghe.com/publications/pami12guidedfilter.pdf>.
12497
12498                   ffmpeg -i in.png -i guidance.png -filter_complex guided=guidance=on out.png
12499
12500   haldclut
12501       Apply a Hald CLUT to a video stream.
12502
12503       First input is the video stream to process, and second one is the Hald
12504       CLUT.  The Hald CLUT input can be a simple picture or a complete video
12505       stream.
12506
12507       The filter accepts the following options:
12508
12509       clut
12510           Set which CLUT video frames will be processed from second input
12511           stream, can be first or all. Default is all.
12512
12513       shortest
12514           Force termination when the shortest input terminates. Default is 0.
12515
12516       repeatlast
12517           Continue applying the last CLUT after the end of the stream. A
12518           value of 0 disable the filter after the last frame of the CLUT is
12519           reached.  Default is 1.
12520
12521       "haldclut" also has the same interpolation options as lut3d (both
12522       filters share the same internals).
12523
12524       This filter also supports the framesync options.
12525
12526       More information about the Hald CLUT can be found on Eskil Steenberg's
12527       website (Hald CLUT author) at
12528       <http://www.quelsolaar.com/technology/clut.html>.
12529
12530       Commands
12531
12532       This filter supports the "interp" option as commands.
12533
12534       Workflow examples
12535
12536       Hald CLUT video stream
12537
12538       Generate an identity Hald CLUT stream altered with various effects:
12539
12540               ffmpeg -f lavfi -i B<haldclutsrc>=8 -vf "hue=H=2*PI*t:s=sin(2*PI*t)+1, curves=cross_process" -t 10 -c:v ffv1 clut.nut
12541
12542       Note: make sure you use a lossless codec.
12543
12544       Then use it with "haldclut" to apply it on some random stream:
12545
12546               ffmpeg -f lavfi -i mandelbrot -i clut.nut -filter_complex '[0][1] haldclut' -t 20 mandelclut.mkv
12547
12548       The Hald CLUT will be applied to the 10 first seconds (duration of
12549       clut.nut), then the latest picture of that CLUT stream will be applied
12550       to the remaining frames of the "mandelbrot" stream.
12551
12552       Hald CLUT with preview
12553
12554       A Hald CLUT is supposed to be a squared image of "Level*Level*Level" by
12555       "Level*Level*Level" pixels. For a given Hald CLUT, FFmpeg will select
12556       the biggest possible square starting at the top left of the picture.
12557       The remaining padding pixels (bottom or right) will be ignored. This
12558       area can be used to add a preview of the Hald CLUT.
12559
12560       Typically, the following generated Hald CLUT will be supported by the
12561       "haldclut" filter:
12562
12563               ffmpeg -f lavfi -i B<haldclutsrc>=8 -vf "
12564                  pad=iw+320 [padded_clut];
12565                  smptebars=s=320x256, split [a][b];
12566                  [padded_clut][a] overlay=W-320:h, curves=color_negative [main];
12567                  [main][b] overlay=W-320" -frames:v 1 clut.png
12568
12569       It contains the original and a preview of the effect of the CLUT: SMPTE
12570       color bars are displayed on the right-top, and below the same color
12571       bars processed by the color changes.
12572
12573       Then, the effect of this Hald CLUT can be visualized with:
12574
12575               ffplay input.mkv -vf "movie=clut.png, [in] haldclut"
12576
12577   hflip
12578       Flip the input video horizontally.
12579
12580       For example, to horizontally flip the input video with ffmpeg:
12581
12582               ffmpeg -i in.avi -vf "hflip" out.avi
12583
12584   histeq
12585       This filter applies a global color histogram equalization on a per-
12586       frame basis.
12587
12588       It can be used to correct video that has a compressed range of pixel
12589       intensities.  The filter redistributes the pixel intensities to
12590       equalize their distribution across the intensity range. It may be
12591       viewed as an "automatically adjusting contrast filter". This filter is
12592       useful only for correcting degraded or poorly captured source video.
12593
12594       The filter accepts the following options:
12595
12596       strength
12597           Determine the amount of equalization to be applied.  As the
12598           strength is reduced, the distribution of pixel intensities more-
12599           and-more approaches that of the input frame. The value must be a
12600           float number in the range [0,1] and defaults to 0.200.
12601
12602       intensity
12603           Set the maximum intensity that can generated and scale the output
12604           values appropriately.  The strength should be set as desired and
12605           then the intensity can be limited if needed to avoid washing-out.
12606           The value must be a float number in the range [0,1] and defaults to
12607           0.210.
12608
12609       antibanding
12610           Set the antibanding level. If enabled the filter will randomly vary
12611           the luminance of output pixels by a small amount to avoid banding
12612           of the histogram. Possible values are "none", "weak" or "strong".
12613           It defaults to "none".
12614
12615   histogram
12616       Compute and draw a color distribution histogram for the input video.
12617
12618       The computed histogram is a representation of the color component
12619       distribution in an image.
12620
12621       Standard histogram displays the color components distribution in an
12622       image.  Displays color graph for each color component. Shows
12623       distribution of the Y, U, V, A or R, G, B components, depending on
12624       input format, in the current frame. Below each graph a color component
12625       scale meter is shown.
12626
12627       The filter accepts the following options:
12628
12629       level_height
12630           Set height of level. Default value is 200.  Allowed range is [50,
12631           2048].
12632
12633       scale_height
12634           Set height of color scale. Default value is 12.  Allowed range is
12635           [0, 40].
12636
12637       display_mode
12638           Set display mode.  It accepts the following values:
12639
12640           stack
12641               Per color component graphs are placed below each other.
12642
12643           parade
12644               Per color component graphs are placed side by side.
12645
12646           overlay
12647               Presents information identical to that in the "parade", except
12648               that the graphs representing color components are superimposed
12649               directly over one another.
12650
12651           Default is "stack".
12652
12653       levels_mode
12654           Set mode. Can be either "linear", or "logarithmic".  Default is
12655           "linear".
12656
12657       components
12658           Set what color components to display.  Default is 7.
12659
12660       fgopacity
12661           Set foreground opacity. Default is 0.7.
12662
12663       bgopacity
12664           Set background opacity. Default is 0.5.
12665
12666       colors_mode
12667           Set colors mode.  It accepts the following values:
12668
12669           whiteonblack
12670           blackonwhite
12671           whiteongray
12672           blackongray
12673           coloronblack
12674           coloronwhite
12675           colorongray
12676           blackoncolor
12677           whiteoncolor
12678           grayoncolor
12679
12680           Default is "whiteonblack".
12681
12682       Examples
12683
12684       •   Calculate and draw histogram:
12685
12686                   ffplay -i input -vf histogram
12687
12688   hqdn3d
12689       This is a high precision/quality 3d denoise filter. It aims to reduce
12690       image noise, producing smooth images and making still images really
12691       still. It should enhance compressibility.
12692
12693       It accepts the following optional parameters:
12694
12695       luma_spatial
12696           A non-negative floating point number which specifies spatial luma
12697           strength.  It defaults to 4.0.
12698
12699       chroma_spatial
12700           A non-negative floating point number which specifies spatial chroma
12701           strength.  It defaults to 3.0*luma_spatial/4.0.
12702
12703       luma_tmp
12704           A floating point number which specifies luma temporal strength. It
12705           defaults to 6.0*luma_spatial/4.0.
12706
12707       chroma_tmp
12708           A floating point number which specifies chroma temporal strength.
12709           It defaults to luma_tmp*chroma_spatial/luma_spatial.
12710
12711       Commands
12712
12713       This filter supports same commands as options.  The command accepts the
12714       same syntax of the corresponding option.
12715
12716       If the specified expression is not valid, it is kept at its current
12717       value.
12718
12719   hwdownload
12720       Download hardware frames to system memory.
12721
12722       The input must be in hardware frames, and the output a non-hardware
12723       format.  Not all formats will be supported on the output - it may be
12724       necessary to insert an additional format filter immediately following
12725       in the graph to get the output in a supported format.
12726
12727   hwmap
12728       Map hardware frames to system memory or to another device.
12729
12730       This filter has several different modes of operation; which one is used
12731       depends on the input and output formats:
12732
12733       •   Hardware frame input, normal frame output
12734
12735           Map the input frames to system memory and pass them to the output.
12736           If the original hardware frame is later required (for example,
12737           after overlaying something else on part of it), the hwmap filter
12738           can be used again in the next mode to retrieve it.
12739
12740       •   Normal frame input, hardware frame output
12741
12742           If the input is actually a software-mapped hardware frame, then
12743           unmap it - that is, return the original hardware frame.
12744
12745           Otherwise, a device must be provided.  Create new hardware surfaces
12746           on that device for the output, then map them back to the software
12747           format at the input and give those frames to the preceding filter.
12748           This will then act like the hwupload filter, but may be able to
12749           avoid an additional copy when the input is already in a compatible
12750           format.
12751
12752       •   Hardware frame input and output
12753
12754           A device must be supplied for the output, either directly or with
12755           the derive_device option.  The input and output devices must be of
12756           different types and compatible - the exact meaning of this is
12757           system-dependent, but typically it means that they must refer to
12758           the same underlying hardware context (for example, refer to the
12759           same graphics card).
12760
12761           If the input frames were originally created on the output device,
12762           then unmap to retrieve the original frames.
12763
12764           Otherwise, map the frames to the output device - create new
12765           hardware frames on the output corresponding to the frames on the
12766           input.
12767
12768       The following additional parameters are accepted:
12769
12770       mode
12771           Set the frame mapping mode.  Some combination of:
12772
12773           read
12774               The mapped frame should be readable.
12775
12776           write
12777               The mapped frame should be writeable.
12778
12779           overwrite
12780               The mapping will always overwrite the entire frame.
12781
12782               This may improve performance in some cases, as the original
12783               contents of the frame need not be loaded.
12784
12785           direct
12786               The mapping must not involve any copying.
12787
12788               Indirect mappings to copies of frames are created in some cases
12789               where either direct mapping is not possible or it would have
12790               unexpected properties.  Setting this flag ensures that the
12791               mapping is direct and will fail if that is not possible.
12792
12793           Defaults to read+write if not specified.
12794
12795       derive_device type
12796           Rather than using the device supplied at initialisation, instead
12797           derive a new device of type type from the device the input frames
12798           exist on.
12799
12800       reverse
12801           In a hardware to hardware mapping, map in reverse - create frames
12802           in the sink and map them back to the source.  This may be necessary
12803           in some cases where a mapping in one direction is required but only
12804           the opposite direction is supported by the devices being used.
12805
12806           This option is dangerous - it may break the preceding filter in
12807           undefined ways if there are any additional constraints on that
12808           filter's output.  Do not use it without fully understanding the
12809           implications of its use.
12810
12811   hwupload
12812       Upload system memory frames to hardware surfaces.
12813
12814       The device to upload to must be supplied when the filter is
12815       initialised.  If using ffmpeg, select the appropriate device with the
12816       -filter_hw_device option or with the derive_device option.  The input
12817       and output devices must be of different types and compatible - the
12818       exact meaning of this is system-dependent, but typically it means that
12819       they must refer to the same underlying hardware context (for example,
12820       refer to the same graphics card).
12821
12822       The following additional parameters are accepted:
12823
12824       derive_device type
12825           Rather than using the device supplied at initialisation, instead
12826           derive a new device of type type from the device the input frames
12827           exist on.
12828
12829   hwupload_cuda
12830       Upload system memory frames to a CUDA device.
12831
12832       It accepts the following optional parameters:
12833
12834       device
12835           The number of the CUDA device to use
12836
12837   hqx
12838       Apply a high-quality magnification filter designed for pixel art. This
12839       filter was originally created by Maxim Stepin.
12840
12841       It accepts the following option:
12842
12843       n   Set the scaling dimension: 2 for "hq2x", 3 for "hq3x" and 4 for
12844           "hq4x".  Default is 3.
12845
12846   hstack
12847       Stack input videos horizontally.
12848
12849       All streams must be of same pixel format and of same height.
12850
12851       Note that this filter is faster than using overlay and pad filter to
12852       create same output.
12853
12854       The filter accepts the following option:
12855
12856       inputs
12857           Set number of input streams. Default is 2.
12858
12859       shortest
12860           If set to 1, force the output to terminate when the shortest input
12861           terminates. Default value is 0.
12862
12863   hsvhold
12864       Turns a certain HSV range into gray values.
12865
12866       This filter measures color difference between set HSV color in options
12867       and ones measured in video stream. Depending on options, output colors
12868       can be changed to be gray or not.
12869
12870       The filter accepts the following options:
12871
12872       hue Set the hue value which will be used in color difference
12873           calculation.  Allowed range is from -360 to 360. Default value is
12874           0.
12875
12876       sat Set the saturation value which will be used in color difference
12877           calculation.  Allowed range is from -1 to 1. Default value is 0.
12878
12879       val Set the value which will be used in color difference calculation.
12880           Allowed range is from -1 to 1. Default value is 0.
12881
12882       similarity
12883           Set similarity percentage with the key color.  Allowed range is
12884           from 0 to 1. Default value is 0.01.
12885
12886           0.00001 matches only the exact key color, while 1.0 matches
12887           everything.
12888
12889       blend
12890           Blend percentage.  Allowed range is from 0 to 1. Default value is
12891           0.
12892
12893           0.0 makes pixels either fully gray, or not gray at all.
12894
12895           Higher values result in more gray pixels, with a higher gray pixel
12896           the more similar the pixels color is to the key color.
12897
12898   hsvkey
12899       Turns a certain HSV range into transparency.
12900
12901       This filter measures color difference between set HSV color in options
12902       and ones measured in video stream. Depending on options, output colors
12903       can be changed to transparent by adding alpha channel.
12904
12905       The filter accepts the following options:
12906
12907       hue Set the hue value which will be used in color difference
12908           calculation.  Allowed range is from -360 to 360. Default value is
12909           0.
12910
12911       sat Set the saturation value which will be used in color difference
12912           calculation.  Allowed range is from -1 to 1. Default value is 0.
12913
12914       val Set the value which will be used in color difference calculation.
12915           Allowed range is from -1 to 1. Default value is 0.
12916
12917       similarity
12918           Set similarity percentage with the key color.  Allowed range is
12919           from 0 to 1. Default value is 0.01.
12920
12921           0.00001 matches only the exact key color, while 1.0 matches
12922           everything.
12923
12924       blend
12925           Blend percentage.  Allowed range is from 0 to 1. Default value is
12926           0.
12927
12928           0.0 makes pixels either fully transparent, or not transparent at
12929           all.
12930
12931           Higher values result in semi-transparent pixels, with a higher
12932           transparency the more similar the pixels color is to the key color.
12933
12934   hue
12935       Modify the hue and/or the saturation of the input.
12936
12937       It accepts the following parameters:
12938
12939       h   Specify the hue angle as a number of degrees. It accepts an
12940           expression, and defaults to "0".
12941
12942       s   Specify the saturation in the [-10,10] range. It accepts an
12943           expression and defaults to "1".
12944
12945       H   Specify the hue angle as a number of radians. It accepts an
12946           expression, and defaults to "0".
12947
12948       b   Specify the brightness in the [-10,10] range. It accepts an
12949           expression and defaults to "0".
12950
12951       h and H are mutually exclusive, and can't be specified at the same
12952       time.
12953
12954       The b, h, H and s option values are expressions containing the
12955       following constants:
12956
12957       n   frame count of the input frame starting from 0
12958
12959       pts presentation timestamp of the input frame expressed in time base
12960           units
12961
12962       r   frame rate of the input video, NAN if the input frame rate is
12963           unknown
12964
12965       t   timestamp expressed in seconds, NAN if the input timestamp is
12966           unknown
12967
12968       tb  time base of the input video
12969
12970       Examples
12971
12972       •   Set the hue to 90 degrees and the saturation to 1.0:
12973
12974                   hue=h=90:s=1
12975
12976       •   Same command but expressing the hue in radians:
12977
12978                   hue=H=PI/2:s=1
12979
12980       •   Rotate hue and make the saturation swing between 0 and 2 over a
12981           period of 1 second:
12982
12983                   hue="H=2*PI*t: s=sin(2*PI*t)+1"
12984
12985       •   Apply a 3 seconds saturation fade-in effect starting at 0:
12986
12987                   hue="s=min(t/3\,1)"
12988
12989           The general fade-in expression can be written as:
12990
12991                   hue="s=min(0\, max((t-START)/DURATION\, 1))"
12992
12993       •   Apply a 3 seconds saturation fade-out effect starting at 5 seconds:
12994
12995                   hue="s=max(0\, min(1\, (8-t)/3))"
12996
12997           The general fade-out expression can be written as:
12998
12999                   hue="s=max(0\, min(1\, (START+DURATION-t)/DURATION))"
13000
13001       Commands
13002
13003       This filter supports the following commands:
13004
13005       b
13006       s
13007       h
13008       H   Modify the hue and/or the saturation and/or brightness of the input
13009           video.  The command accepts the same syntax of the corresponding
13010           option.
13011
13012           If the specified expression is not valid, it is kept at its current
13013           value.
13014
13015   huesaturation
13016       Apply hue-saturation-intensity adjustments to input video stream.
13017
13018       This filter operates in RGB colorspace.
13019
13020       This filter accepts the following options:
13021
13022       hue Set the hue shift in degrees to apply. Default is 0.  Allowed range
13023           is from -180 to 180.
13024
13025       saturation
13026           Set the saturation shift. Default is 0.  Allowed range is from -1
13027           to 1.
13028
13029       intensity
13030           Set the intensity shift. Default is 0.  Allowed range is from -1 to
13031           1.
13032
13033       colors
13034           Set which primary and complementary colors are going to be
13035           adjusted.  This options is set by providing one or multiple values.
13036           This can select multiple colors at once. By default all colors are
13037           selected.
13038
13039           r   Adjust reds.
13040
13041           y   Adjust yellows.
13042
13043           g   Adjust greens.
13044
13045           c   Adjust cyans.
13046
13047           b   Adjust blues.
13048
13049           m   Adjust magentas.
13050
13051           a   Adjust all colors.
13052
13053       strength
13054           Set strength of filtering. Allowed range is from 0 to 100.  Default
13055           value is 1.
13056
13057       rw, gw, bw
13058           Set weight for each RGB component. Allowed range is from 0 to 1.
13059           By default is set to 0.333, 0.334, 0.333.  Those options are used
13060           in saturation and lightess processing.
13061
13062       lightness
13063           Set preserving lightness, by default is disabled.  Adjusting hues
13064           can change lightness from original RGB triplet, with this option
13065           enabled lightness is kept at same value.
13066
13067   hysteresis
13068       Grow first stream into second stream by connecting components.  This
13069       makes it possible to build more robust edge masks.
13070
13071       This filter accepts the following options:
13072
13073       planes
13074           Set which planes will be processed as bitmap, unprocessed planes
13075           will be copied from first stream.  By default value 0xf, all planes
13076           will be processed.
13077
13078       threshold
13079           Set threshold which is used in filtering. If pixel component value
13080           is higher than this value filter algorithm for connecting
13081           components is activated.  By default value is 0.
13082
13083       The "hysteresis" filter also supports the framesync options.
13084
13085   iccdetect
13086       Detect the colorspace  from an embedded ICC profile (if present), and
13087       update the frame's tags accordingly.
13088
13089       This filter accepts the following options:
13090
13091       force
13092           If true, the frame's existing colorspace tags will always be
13093           overridden by values detected from an ICC profile. Otherwise, they
13094           will only be assigned if they contain "unknown". Enabled by
13095           default.
13096
13097   iccgen
13098       Generate ICC profiles and attach them to frames.
13099
13100       This filter accepts the following options:
13101
13102       color_primaries
13103       color_trc
13104           Configure the colorspace that the ICC profile will be generated
13105           for. The default value of "auto" infers the value from the input
13106           frame's metadata, defaulting to BT.709/sRGB as appropriate.
13107
13108           See the setparams filter for a list of possible values, but note
13109           that "unknown" are not valid values for this filter.
13110
13111       force
13112           If true, an ICC profile will be generated even if it would
13113           overwrite an already existing ICC profile. Disabled by default.
13114
13115   identity
13116       Obtain the identity score between two input videos.
13117
13118       This filter takes two input videos.
13119
13120       Both input videos must have the same resolution and pixel format for
13121       this filter to work correctly. Also it assumes that both inputs have
13122       the same number of frames, which are compared one by one.
13123
13124       The obtained per component, average, min and max identity score is
13125       printed through the logging system.
13126
13127       The filter stores the calculated identity scores of each frame in frame
13128       metadata.
13129
13130       In the below example the input file main.mpg being processed is
13131       compared with the reference file ref.mpg.
13132
13133               ffmpeg -i main.mpg -i ref.mpg -lavfi identity -f null -
13134
13135   idet
13136       Detect video interlacing type.
13137
13138       This filter tries to detect if the input frames are interlaced,
13139       progressive, top or bottom field first. It will also try to detect
13140       fields that are repeated between adjacent frames (a sign of telecine).
13141
13142       Single frame detection considers only immediately adjacent frames when
13143       classifying each frame.  Multiple frame detection incorporates the
13144       classification history of previous frames.
13145
13146       The filter will log these metadata values:
13147
13148       single.current_frame
13149           Detected type of current frame using single-frame detection. One
13150           of: ``tff'' (top field first), ``bff'' (bottom field first),
13151           ``progressive'', or ``undetermined''
13152
13153       single.tff
13154           Cumulative number of frames detected as top field first using
13155           single-frame detection.
13156
13157       multiple.tff
13158           Cumulative number of frames detected as top field first using
13159           multiple-frame detection.
13160
13161       single.bff
13162           Cumulative number of frames detected as bottom field first using
13163           single-frame detection.
13164
13165       multiple.current_frame
13166           Detected type of current frame using multiple-frame detection. One
13167           of: ``tff'' (top field first), ``bff'' (bottom field first),
13168           ``progressive'', or ``undetermined''
13169
13170       multiple.bff
13171           Cumulative number of frames detected as bottom field first using
13172           multiple-frame detection.
13173
13174       single.progressive
13175           Cumulative number of frames detected as progressive using single-
13176           frame detection.
13177
13178       multiple.progressive
13179           Cumulative number of frames detected as progressive using multiple-
13180           frame detection.
13181
13182       single.undetermined
13183           Cumulative number of frames that could not be classified using
13184           single-frame detection.
13185
13186       multiple.undetermined
13187           Cumulative number of frames that could not be classified using
13188           multiple-frame detection.
13189
13190       repeated.current_frame
13191           Which field in the current frame is repeated from the last. One of
13192           ``neither'', ``top'', or ``bottom''.
13193
13194       repeated.neither
13195           Cumulative number of frames with no repeated field.
13196
13197       repeated.top
13198           Cumulative number of frames with the top field repeated from the
13199           previous frame's top field.
13200
13201       repeated.bottom
13202           Cumulative number of frames with the bottom field repeated from the
13203           previous frame's bottom field.
13204
13205       The filter accepts the following options:
13206
13207       intl_thres
13208           Set interlacing threshold.
13209
13210       prog_thres
13211           Set progressive threshold.
13212
13213       rep_thres
13214           Threshold for repeated field detection.
13215
13216       half_life
13217           Number of frames after which a given frame's contribution to the
13218           statistics is halved (i.e., it contributes only 0.5 to its
13219           classification). The default of 0 means that all frames seen are
13220           given full weight of 1.0 forever.
13221
13222       analyze_interlaced_flag
13223           When this is not 0 then idet will use the specified number of
13224           frames to determine if the interlaced flag is accurate, it will not
13225           count undetermined frames.  If the flag is found to be accurate it
13226           will be used without any further computations, if it is found to be
13227           inaccurate it will be cleared without any further computations.
13228           This allows inserting the idet filter as a low computational method
13229           to clean up the interlaced flag
13230
13231   il
13232       Deinterleave or interleave fields.
13233
13234       This filter allows one to process interlaced images fields without
13235       deinterlacing them. Deinterleaving splits the input frame into 2 fields
13236       (so called half pictures). Odd lines are moved to the top half of the
13237       output image, even lines to the bottom half.  You can process (filter)
13238       them independently and then re-interleave them.
13239
13240       The filter accepts the following options:
13241
13242       luma_mode, l
13243       chroma_mode, c
13244       alpha_mode, a
13245           Available values for luma_mode, chroma_mode and alpha_mode are:
13246
13247           none
13248               Do nothing.
13249
13250           deinterleave, d
13251               Deinterleave fields, placing one above the other.
13252
13253           interleave, i
13254               Interleave fields. Reverse the effect of deinterleaving.
13255
13256           Default value is "none".
13257
13258       luma_swap, ls
13259       chroma_swap, cs
13260       alpha_swap, as
13261           Swap luma/chroma/alpha fields. Exchange even & odd lines. Default
13262           value is 0.
13263
13264       Commands
13265
13266       This filter supports the all above options as commands.
13267
13268   inflate
13269       Apply inflate effect to the video.
13270
13271       This filter replaces the pixel by the local(3x3) average by taking into
13272       account only values higher than the pixel.
13273
13274       It accepts the following options:
13275
13276       threshold0
13277       threshold1
13278       threshold2
13279       threshold3
13280           Limit the maximum change for each plane, default is 65535.  If 0,
13281           plane will remain unchanged.
13282
13283       Commands
13284
13285       This filter supports the all above options as commands.
13286
13287   interlace
13288       Simple interlacing filter from progressive contents. This interleaves
13289       upper (or lower) lines from odd frames with lower (or upper) lines from
13290       even frames, halving the frame rate and preserving image height.
13291
13292                  Original        Original             New Frame
13293                  Frame 'j'      Frame 'j+1'             (tff)
13294                 ==========      ===========       ==================
13295                   Line 0  -------------------->    Frame 'j' Line 0
13296                   Line 1          Line 1  ---->   Frame 'j+1' Line 1
13297                   Line 2 --------------------->    Frame 'j' Line 2
13298                   Line 3          Line 3  ---->   Frame 'j+1' Line 3
13299                    ...             ...                   ...
13300               New Frame + 1 will be generated by Frame 'j+2' and Frame 'j+3' and so on
13301
13302       It accepts the following optional parameters:
13303
13304       scan
13305           This determines whether the interlaced frame is taken from the even
13306           (tff - default) or odd (bff) lines of the progressive frame.
13307
13308       lowpass
13309           Vertical lowpass filter to avoid twitter interlacing and reduce
13310           moire patterns.
13311
13312           0, off
13313               Disable vertical lowpass filter
13314
13315           1, linear
13316               Enable linear filter (default)
13317
13318           2, complex
13319               Enable complex filter. This will slightly less reduce twitter
13320               and moire but better retain detail and subjective sharpness
13321               impression.
13322
13323   kerndeint
13324       Deinterlace input video by applying Donald Graft's adaptive kernel
13325       deinterling. Work on interlaced parts of a video to produce progressive
13326       frames.
13327
13328       The description of the accepted parameters follows.
13329
13330       thresh
13331           Set the threshold which affects the filter's tolerance when
13332           determining if a pixel line must be processed. It must be an
13333           integer in the range [0,255] and defaults to 10. A value of 0 will
13334           result in applying the process on every pixels.
13335
13336       map Paint pixels exceeding the threshold value to white if set to 1.
13337           Default is 0.
13338
13339       order
13340           Set the fields order. Swap fields if set to 1, leave fields alone
13341           if 0. Default is 0.
13342
13343       sharp
13344           Enable additional sharpening if set to 1. Default is 0.
13345
13346       twoway
13347           Enable twoway sharpening if set to 1. Default is 0.
13348
13349       Examples
13350
13351       •   Apply default values:
13352
13353                   kerndeint=thresh=10:map=0:order=0:sharp=0:twoway=0
13354
13355       •   Enable additional sharpening:
13356
13357                   kerndeint=sharp=1
13358
13359       •   Paint processed pixels in white:
13360
13361                   kerndeint=map=1
13362
13363   kirsch
13364       Apply kirsch operator to input video stream.
13365
13366       The filter accepts the following option:
13367
13368       planes
13369           Set which planes will be processed, unprocessed planes will be
13370           copied.  By default value 0xf, all planes will be processed.
13371
13372       scale
13373           Set value which will be multiplied with filtered result.
13374
13375       delta
13376           Set value which will be added to filtered result.
13377
13378       Commands
13379
13380       This filter supports the all above options as commands.
13381
13382   lagfun
13383       Slowly update darker pixels.
13384
13385       This filter makes short flashes of light appear longer.  This filter
13386       accepts the following options:
13387
13388       decay
13389           Set factor for decaying. Default is .95. Allowed range is from 0 to
13390           1.
13391
13392       planes
13393           Set which planes to filter. Default is all. Allowed range is from 0
13394           to 15.
13395
13396       Commands
13397
13398       This filter supports the all above options as commands.
13399
13400   lenscorrection
13401       Correct radial lens distortion
13402
13403       This filter can be used to correct for radial distortion as can result
13404       from the use of wide angle lenses, and thereby re-rectify the image. To
13405       find the right parameters one can use tools available for example as
13406       part of opencv or simply trial-and-error.  To use opencv use the
13407       calibration sample (under samples/cpp) from the opencv sources and
13408       extract the k1 and k2 coefficients from the resulting matrix.
13409
13410       Note that effectively the same filter is available in the open-source
13411       tools Krita and Digikam from the KDE project.
13412
13413       In contrast to the vignette filter, which can also be used to
13414       compensate lens errors, this filter corrects the distortion of the
13415       image, whereas vignette corrects the brightness distribution, so you
13416       may want to use both filters together in certain cases, though you will
13417       have to take care of ordering, i.e. whether vignetting should be
13418       applied before or after lens correction.
13419
13420       Options
13421
13422       The filter accepts the following options:
13423
13424       cx  Relative x-coordinate of the focal point of the image, and thereby
13425           the center of the distortion. This value has a range [0,1] and is
13426           expressed as fractions of the image width. Default is 0.5.
13427
13428       cy  Relative y-coordinate of the focal point of the image, and thereby
13429           the center of the distortion. This value has a range [0,1] and is
13430           expressed as fractions of the image height. Default is 0.5.
13431
13432       k1  Coefficient of the quadratic correction term. This value has a
13433           range [-1,1]. 0 means no correction. Default is 0.
13434
13435       k2  Coefficient of the double quadratic correction term. This value has
13436           a range [-1,1].  0 means no correction. Default is 0.
13437
13438       i   Set interpolation type. Can be "nearest" or "bilinear".  Default is
13439           "nearest".
13440
13441       fc  Specify the color of the unmapped pixels. For the syntax of this
13442           option, check the "Color" section in the ffmpeg-utils manual.
13443           Default color is "black@0".
13444
13445       The formula that generates the correction is:
13446
13447       r_src = r_tgt * (1 + k1 * (r_tgt / r_0)^2 + k2 * (r_tgt / r_0)^4)
13448
13449       where r_0 is halve of the image diagonal and r_src and r_tgt are the
13450       distances from the focal point in the source and target images,
13451       respectively.
13452
13453       Commands
13454
13455       This filter supports the all above options as commands.
13456
13457   lensfun
13458       Apply lens correction via the lensfun library
13459       (<http://lensfun.sourceforge.net/>).
13460
13461       The "lensfun" filter requires the camera make, camera model, and lens
13462       model to apply the lens correction. The filter will load the lensfun
13463       database and query it to find the corresponding camera and lens entries
13464       in the database. As long as these entries can be found with the given
13465       options, the filter can perform corrections on frames. Note that
13466       incomplete strings will result in the filter choosing the best match
13467       with the given options, and the filter will output the chosen camera
13468       and lens models (logged with level "info"). You must provide the make,
13469       camera model, and lens model as they are required.
13470
13471       To obtain a list of available makes and models, leave out one or both
13472       of "make" and "model" options. The filter will send the full list to
13473       the log with level "INFO".  The first column is the make and the second
13474       column is the model.  To obtain a list of available lenses, set any
13475       values for make and model and leave out the "lens_model" option. The
13476       filter will send the full list of lenses in the log with level "INFO".
13477       The ffmpeg tool will exit after the list is printed.
13478
13479       The filter accepts the following options:
13480
13481       make
13482           The make of the camera (for example, "Canon"). This option is
13483           required.
13484
13485       model
13486           The model of the camera (for example, "Canon EOS 100D"). This
13487           option is required.
13488
13489       lens_model
13490           The model of the lens (for example, "Canon EF-S 18-55mm f/3.5-5.6
13491           IS STM"). This option is required.
13492
13493       db_path
13494           The full path to the lens database folder. If not set, the filter
13495           will attempt to load the database from the install path when the
13496           library was built. Default is unset.
13497
13498       mode
13499           The type of correction to apply. The following values are valid
13500           options:
13501
13502           vignetting
13503               Enables fixing lens vignetting.
13504
13505           geometry
13506               Enables fixing lens geometry. This is the default.
13507
13508           subpixel
13509               Enables fixing chromatic aberrations.
13510
13511           vig_geo
13512               Enables fixing lens vignetting and lens geometry.
13513
13514           vig_subpixel
13515               Enables fixing lens vignetting and chromatic aberrations.
13516
13517           distortion
13518               Enables fixing both lens geometry and chromatic aberrations.
13519
13520           all Enables all possible corrections.
13521
13522       focal_length
13523           The focal length of the image/video (zoom; expected constant for
13524           video). For example, a 18--55mm lens has focal length range of
13525           [18--55], so a value in that range should be chosen when using that
13526           lens. Default 18.
13527
13528       aperture
13529           The aperture of the image/video (expected constant for video). Note
13530           that aperture is only used for vignetting correction. Default 3.5.
13531
13532       focus_distance
13533           The focus distance of the image/video (expected constant for
13534           video). Note that focus distance is only used for vignetting and
13535           only slightly affects the vignetting correction process. If
13536           unknown, leave it at the default value (which is 1000).
13537
13538       scale
13539           The scale factor which is applied after transformation. After
13540           correction the video is no longer necessarily rectangular. This
13541           parameter controls how much of the resulting image is visible. The
13542           value 0 means that a value will be chosen automatically such that
13543           there is little or no unmapped area in the output image. 1.0 means
13544           that no additional scaling is done. Lower values may result in more
13545           of the corrected image being visible, while higher values may avoid
13546           unmapped areas in the output.
13547
13548       target_geometry
13549           The target geometry of the output image/video. The following values
13550           are valid options:
13551
13552           rectilinear (default)
13553           fisheye
13554           panoramic
13555           equirectangular
13556           fisheye_orthographic
13557           fisheye_stereographic
13558           fisheye_equisolid
13559           fisheye_thoby
13560       reverse
13561           Apply the reverse of image correction (instead of correcting
13562           distortion, apply it).
13563
13564       interpolation
13565           The type of interpolation used when correcting distortion. The
13566           following values are valid options:
13567
13568           nearest
13569           linear (default)
13570           lanczos
13571
13572       Examples
13573
13574       •   Apply lens correction with make "Canon", camera model "Canon EOS
13575           100D", and lens model "Canon EF-S 18-55mm f/3.5-5.6 IS STM" with
13576           focal length of "18" and aperture of "8.0".
13577
13578                   ffmpeg -i input.mov -vf lensfun=make=Canon:model="Canon EOS 100D":lens_model="Canon EF-S 18-55mm f/3.5-5.6 IS STM":focal_length=18:aperture=8 -c:v h264 -b:v 8000k output.mov
13579
13580       •   Apply the same as before, but only for the first 5 seconds of
13581           video.
13582
13583                   ffmpeg -i input.mov -vf lensfun=make=Canon:model="Canon EOS 100D":lens_model="Canon EF-S 18-55mm f/3.5-5.6 IS STM":focal_length=18:aperture=8:enable='lte(t\,5)' -c:v h264 -b:v 8000k output.mov
13584
13585   libplacebo
13586       Flexible GPU-accelerated processing filter based on libplacebo
13587       (<https://code.videolan.org/videolan/libplacebo>). Note that this
13588       filter currently only accepts Vulkan input frames.
13589
13590       Options
13591
13592       The options for this filter are divided into the following sections:
13593
13594       Output mode
13595
13596       These options control the overall output mode. By default, libplacebo
13597       will try to preserve the source colorimetry and size as best as it can,
13598       but it will apply any embedded film grain, dolby vision metadata or
13599       anamorphic SAR present in source frames.
13600
13601       w
13602       h   Set the output video dimension expression. Default value is the
13603           input dimension.
13604
13605           Allows for the same expressions as the scale filter.
13606
13607       format
13608           Set the output format override. If unset (the default), frames will
13609           be output in the same format as the respective input frames.
13610           Otherwise, format conversion will be performed.
13611
13612       force_original_aspect_ratio
13613       force_divisible_by
13614           Work the same as the identical scale filter options.
13615
13616       normalize_sar
13617           If enabled (the default), output frames will always have a pixel
13618           aspect ratio of 1:1. If disabled, any aspect ratio mismatches,
13619           including those from e.g.  anamorphic video sources, are forwarded
13620           to the output pixel aspect ratio.
13621
13622       pad_crop_ratio
13623           Specifies a ratio (between 0.0 and 1.0) between padding and
13624           cropping when the input aspect ratio does not match the output
13625           aspect ratio and normalize_sar is in effect. The default of 0.0
13626           always pads the content with black borders, while a value of 1.0
13627           always crops off parts of the content. Intermediate values are
13628           possible, leading to a mix of the two approaches.
13629
13630       colorspace
13631       color_primaries
13632       color_trc
13633       range
13634           Configure the colorspace that output frames will be delivered in.
13635           The default value of "auto" outputs frames in the same format as
13636           the input frames, leading to no change. For any other value,
13637           conversion will be performed.
13638
13639           See the setparams filter for a list of possible values.
13640
13641       apply_filmgrain
13642           Apply film grain (e.g. AV1 or H.274) if present in source frames,
13643           and strip it from the output. Enabled by default.
13644
13645       apply_dolbyvision
13646           Apply Dolby Vision RPU metadata if present in source frames, and
13647           strip it from the output. Enabled by default. Note that Dolby
13648           Vision will always output BT.2020+PQ, overriding the usual input
13649           frame metadata. These will also be picked as the values of "auto"
13650           for the respective frame output options.
13651
13652       Scaling
13653
13654       The options in this section control how libplacebo performs upscaling
13655       and (if necessary) downscaling. Note that libplacebo will always
13656       internally operate on 4:4:4 content, so any sub-sampled chroma formats
13657       such as "yuv420p" will necessarily be upsampled and downsampled as part
13658       of the rendering process. That means scaling might be in effect even if
13659       the source and destination resolution are the same.
13660
13661       upscaler
13662       downscaler
13663           Configure the filter kernel used for upscaling and downscaling. The
13664           respective defaults are "spline36" and "mitchell". For a full list
13665           of possible values, pass "help" to these options. The most
13666           important values are:
13667
13668           none
13669               Forces the use of built-in GPU texture sampling (typically
13670               bilinear). Extremely fast but poor quality, especially when
13671               downscaling.
13672
13673           bilinear
13674               Bilinear interpolation. Can generally be done for free on GPUs,
13675               except when doing so would lead to aliasing. Fast and low
13676               quality.
13677
13678           nearest
13679               Nearest-neighbour interpolation. Sharp but highly aliasing.
13680
13681           oversample
13682               Algorithm that looks visually similar to nearest-neighbour
13683               interpolation but tries to preserve pixel aspect ratio. Good
13684               for pixel art, since it results in minimal distortion of the
13685               artistic appearance.
13686
13687           lanczos
13688               Standard sinc-sinc interpolation kernel.
13689
13690           spline36
13691               Cubic spline approximation of lanczos. No difference in
13692               performance, but has very slightly less ringing.
13693
13694           ewa_lanczos
13695               Elliptically weighted average version of lanczos, based on a
13696               jinc-sinc kernel.  This is also popularly referred to as just
13697               "Jinc scaling". Slow but very high quality.
13698
13699           gaussian
13700               Gaussian kernel. Has certain ideal mathematical properties, but
13701               subjectively very blurry.
13702
13703           mitchell
13704               Cubic BC spline with parameters recommended by Mitchell and
13705               Netravali. Very little ringing.
13706
13707       lut_entries
13708           Configures the size of scaler LUTs, ranging from 1 to 256. The
13709           default of 0 will pick libplacebo's internal default, typically 64.
13710
13711       antiringing
13712           Enables anti-ringing (for non-EWA filters). The value (between 0.0
13713           and 1.0) configures the strength of the anti-ringing algorithm. May
13714           increase aliasing if set too high. Disabled by default.
13715
13716       sigmoid
13717           Enable sigmoidal compression during upscaling. Reduces ringing
13718           slightly.  Enabled by default.
13719
13720       Debanding
13721
13722       Libplacebo comes with a built-in debanding filter that is good at
13723       counteracting many common sources of banding and blocking. Turning this
13724       on is highly recommended whenever quality is desired.
13725
13726       deband
13727           Enable (fast) debanding algorithm. Disabled by default.
13728
13729       deband_iterations
13730           Number of deband iterations of the debanding algorithm. Each
13731           iteration is performed with progressively increased radius (and
13732           diminished threshold).  Recommended values are in the range 1 to 4.
13733           Defaults to 1.
13734
13735       deband_threshold
13736           Debanding filter strength. Higher numbers lead to more aggressive
13737           debanding.  Defaults to 4.0.
13738
13739       deband_radius
13740           Debanding filter radius. A higher radius is better for slow
13741           gradients, while a lower radius is better for steep gradients.
13742           Defaults to 16.0.
13743
13744       deband_grain
13745           Amount of extra output grain to add. Helps hide imperfections.
13746           Defaults to 6.0.
13747
13748       Color adjustment
13749
13750       A collection of subjective color controls. Not very rigorous, so the
13751       exact effect will vary somewhat depending on the input primaries and
13752       colorspace.
13753
13754       brightness
13755           Brightness boost, between "-1.0" and 1.0. Defaults to 0.0.
13756
13757       contrast
13758           Contrast gain, between 0.0 and 16.0. Defaults to 1.0.
13759
13760       saturation
13761           Saturation gain, between 0.0 and 16.0. Defaults to 1.0.
13762
13763       hue Hue shift in radians, between "-3.14" and 3.14. Defaults to 0.0.
13764           This will rotate the UV subvector, defaulting to BT.709
13765           coefficients for RGB inputs.
13766
13767       gamma
13768           Gamma adjustment, between 0.0 and 16.0. Defaults to 1.0.
13769
13770       cones
13771           Cone model to use for color blindness simulation. Accepts any
13772           combination of "l", "m" and "s". Here are some examples:
13773
13774           m   Deuteranomaly / deuteranopia (affecting 3%-4% of the
13775               population)
13776
13777           l   Protanomaly / protanopia (affecting 1%-2% of the population)
13778
13779           l+m Monochromacy (very rare)
13780
13781           l+m+s
13782               Achromatopsy (complete loss of daytime vision, extremely rare)
13783
13784       cone-strength
13785           Gain factor for the cones specified by "cones", between 0.0 and
13786           10.0. A value of 1.0 results in no change to color vision. A value
13787           of 0.0 (the default) simulates complete loss of those cones. Values
13788           above 1.0 result in exaggerating the differences between cones,
13789           which may help compensate for reduced color vision.
13790
13791       Peak detection
13792
13793       To help deal with sources that only have static HDR10 metadata (or no
13794       tagging whatsoever), libplacebo uses its own internal frame analysis
13795       compute shader to analyze source frames and adapt the tone mapping
13796       function in realtime. If this is too slow, or if exactly reproducible
13797       frame-perfect results are needed, it's recommended to turn this feature
13798       off.
13799
13800       peak_detect
13801           Enable HDR peak detection. Ignores static MaxCLL/MaxFALL values in
13802           favor of dynamic detection from the input. Note that the detected
13803           values do not get written back to the output frames, they merely
13804           guide the internal tone mapping process. Enabled by default.
13805
13806       smoothing_period
13807           Peak detection smoothing period, between 0.0 and 1000.0. Higher
13808           values result in peak detection becoming less responsive to changes
13809           in the input. Defaults to 100.0.
13810
13811       minimum_peak
13812           Lower bound on the detected peak (relative to SDR white), between
13813           0.0 and 100.0. Defaults to 1.0.
13814
13815       scene_threshold_low
13816       scene_threshold_high
13817           Lower and upper thresholds for scene change detection. Expressed in
13818           a logarithmic scale between 0.0 and 100.0. Default to 5.5 and 10.0,
13819           respectively. Setting either to a negative value disables this
13820           functionality.
13821
13822       overshoot
13823           Peak smoothing overshoot margin, between 0.0 and 1.0. Provides a
13824           safety margin to prevent clipping as a result of peak smoothing.
13825           Defaults to 0.05, corresponding to a margin of 5%.
13826
13827       Tone mapping
13828
13829       The options in this section control how libplacebo performs tone-
13830       mapping and gamut-mapping when dealing with mismatches between wide-
13831       gamut or HDR content.  In general, libplacebo relies on accurate source
13832       tagging and mastering display gamut information to produce the best
13833       results.
13834
13835       intent
13836           Rendering intent to use when adapting between different primary
13837           color gamuts (after tone-mapping).
13838
13839           perceptual
13840               Perceptual gamut mapping. Currently equivalent to relative
13841               colorimetric.
13842
13843           relative
13844               Relative colorimetric. This is the default.
13845
13846           absolute
13847               Absolute colorimetric.
13848
13849           saturation
13850               Saturation mapping. Forcibly stretches the source gamut to the
13851               target gamut.
13852
13853       gamut_mode
13854           How to handle out-of-gamut colors that can occur as a result of
13855           colorimetric gamut mapping.
13856
13857           clip
13858               Do nothing, simply clip out-of-range colors to the RGB volume.
13859               This is the default.
13860
13861           warn
13862               Highlight out-of-gamut pixels (by coloring them pink).
13863
13864           darken
13865               Linearly reduces content brightness to preserves saturated
13866               details, followed by clipping the remaining out-of-gamut
13867               colors. As the name implies, this makes everything darker, but
13868               provides a good balance between preserving details and colors.
13869
13870           desaturate
13871               Hard-desaturates out-of-gamut colors towards white, while
13872               preserving the luminance. Has a tendency to shift colors.
13873
13874       tonemapping
13875           Tone-mapping algorithm to use. Available values are:
13876
13877           auto
13878               Automatic selection based on internal heuristics. This is the
13879               default.
13880
13881           clip
13882               Performs no tone-mapping, just clips out-of-range colors.
13883               Retains perfect color accuracy for in-range colors but
13884               completely destroys out-of-range information.  Does not perform
13885               any black point adaptation. Not configurable.
13886
13887           bt.2390
13888               EETF from the ITU-R Report BT.2390, a hermite spline roll-off
13889               with linear segment. The knee point offset is configurable.
13890               Note that this parameter defaults to 1.0, rather than the value
13891               of 0.5 from the ITU-R spec.
13892
13893           bt.2446a
13894               EETF from ITU-R Report BT.2446, method A. Designed for well-
13895               mastered HDR sources. Can be used for both forward and inverse
13896               tone mapping. Not configurable.
13897
13898           spline
13899               Simple spline consisting of two polynomials, joined by a single
13900               pivot point.  The parameter gives the pivot point (in PQ
13901               space), defaulting to 0.30.  Can be used for both forward and
13902               inverse tone mapping.
13903
13904           reinhard
13905               Simple non-linear, global tone mapping algorithm. The parameter
13906               specifies the local contrast coefficient at the display peak.
13907               Essentially, a parameter of 0.5 implies that the reference
13908               white will be about half as bright as when clipping. Defaults
13909               to 0.5, which results in the simplest formulation of this
13910               function.
13911
13912           mobius
13913               Generalization of the reinhard tone mapping algorithm to
13914               support an additional linear slope near black. The tone mapping
13915               parameter indicates the trade-off between the linear section
13916               and the non-linear section. Essentially, for a given parameter
13917               x, every color value below x will be mapped linearly, while
13918               higher values get non-linearly tone-mapped. Values near 1.0
13919               make this curve behave like "clip", while values near 0.0 make
13920               this curve behave like "reinhard". The default value is 0.3,
13921               which provides a good balance between colorimetric accuracy and
13922               preserving out-of-gamut details.
13923
13924           hable
13925               Piece-wise, filmic tone-mapping algorithm developed by John
13926               Hable for use in Uncharted 2, inspired by a similar tone-
13927               mapping algorithm used by Kodak.  Popularized by its use in
13928               video games with HDR rendering. Preserves both dark and bright
13929               details very well, but comes with the drawback of changing the
13930               average brightness quite significantly. This is sort of similar
13931               to "reinhard" with parameter 0.24.
13932
13933           gamma
13934               Fits a gamma (power) function to transfer between the source
13935               and target color spaces, effectively resulting in a perceptual
13936               hard-knee joining two roughly linear sections. This preserves
13937               details at all scales fairly accurately, but can result in an
13938               image with a muted or dull appearance. The parameter is used as
13939               the cutoff point, defaulting to 0.5.
13940
13941           linear
13942               Linearly stretches the input range to the output range, in PQ
13943               space. This will preserve all details accurately, but results
13944               in a significantly different average brightness. Can be used
13945               for inverse tone-mapping in addition to regular tone-mapping.
13946               The parameter can be used as an additional linear gain
13947               coefficient (defaulting to 1.0).
13948
13949       tonemapping_param
13950           For tunable tone mapping functions, this parameter can be used to
13951           fine-tune the curve behavior. Refer to the documentation of
13952           "tonemapping". The default value of 0.0 is replaced by the curve's
13953           preferred default setting.
13954
13955       tonemapping_mode
13956           This option determines how the tone mapping function specified by
13957           "tonemapping" is applied to the colors in a scene. Possible values
13958           are:
13959
13960           auto
13961               Automatic selection based on internal heuristics. This is the
13962               default.
13963
13964           rgb Apply the function per-channel in the RGB colorspace.  Per-
13965               channel tone-mapping in RGB. Guarantees no clipping and heavily
13966               desaturates the output, but distorts the colors quite
13967               significantly. Very similar to the "Hollywood" look and feel.
13968
13969           max Tone-mapping is performed on the brightest component found in
13970               the signal. Good at preserving details in highlights, but has a
13971               tendency to crush blacks.
13972
13973           hybrid
13974               Tone-map per-channel for highlights and linearly (luma-based)
13975               for midtones/shadows, based on a fixed gamma 2.4 coefficient
13976               curve.
13977
13978           luma
13979               Tone-map linearly on the luma component (CIE Y), and adjust
13980               (desaturate) the chromaticities to compensate using a simple
13981               constant factor. This is essentially the mode used in ITU-R
13982               BT.2446 method A.
13983
13984       inverse_tonemapping
13985           If enabled, this filter will also attempt stretching SDR signals to
13986           fill HDR output color volumes. Disabled by default.
13987
13988       tonemapping_crosstalk
13989           Extra tone-mapping crosstalk factor, between 0.0 and 0.3. This can
13990           help reduce issues tone-mapping certain bright spectral colors.
13991           Defaults to 0.04.
13992
13993       tonemapping_lut_size
13994           Size of the tone-mapping LUT, between 2 and 1024. Defaults to 256.
13995           Note that this figure is squared when combined with "peak_detect".
13996
13997       Dithering
13998
13999       By default, libplacebo will dither whenever necessary, which includes
14000       rendering to any integer format below 16-bit precision. It's
14001       recommended to always leave this on, since not doing so may result in
14002       visible banding in the output, even if the "debanding" filter is
14003       enabled. If maximum performance is needed, use "ordered_fixed" instead
14004       of disabling dithering.
14005
14006       dithering
14007           Dithering method to use. Accepts the following values:
14008
14009           none
14010               Disables dithering completely. May result in visible banding.
14011
14012           blue
14013               Dither with pseudo-blue noise. This is the default.
14014
14015           ordered
14016               Tunable ordered dither pattern.
14017
14018           ordered_fixed
14019               Faster ordered dither with a fixed size of 6. Texture-less.
14020
14021           white
14022               Dither with white noise. Texture-less.
14023
14024       dither_lut_size
14025           Dither LUT size, as log base2 between 1 and 8. Defaults to 6,
14026           corresponding to a LUT size of "64x64".
14027
14028       dither_temporal
14029           Enables temporal dithering. Disabled by default.
14030
14031       Custom shaders
14032
14033       libplacebo supports a number of custom shaders based on the mpv .hook
14034       GLSL syntax. A collection of such shaders can be found here:
14035       <https://github.com/mpv-player/mpv/wiki/User-Scripts#user-shaders>
14036
14037       A full description of the mpv shader format is beyond the scope of this
14038       section, but a summary can be found here:
14039       <https://mpv.io/manual/master/#options-glsl-shader>
14040
14041       custom_shader_path
14042           Specifies a path to a custom shader file to load at runtime.
14043
14044       custom_shader_bin
14045           Specifies a complete custom shader as a raw string.
14046
14047       Debugging / performance
14048
14049       All of the options in this section default off. They may be of
14050       assistance when attempting to squeeze the maximum performance at the
14051       cost of quality.
14052
14053       skip_aa
14054           Disable anti-aliasing when downscaling.
14055
14056       polar_cutoff
14057           Truncate polar (EWA) scaler kernels below this absolute magnitude,
14058           between 0.0 and 1.0.
14059
14060       disable_linear
14061           Disable linear light scaling.
14062
14063       disable_builtin
14064           Disable built-in GPU sampling (forces LUT).
14065
14066       force_icc_lut
14067           Force the use of a full ICC 3DLUT for gamut mapping.
14068
14069       disable_fbos
14070           Forcibly disable FBOs, resulting in loss of almost all
14071           functionality, but offering the maximum possible speed.
14072
14073       Commands
14074
14075       This filter supports almost all of the above options as commands.
14076
14077       Examples
14078
14079       •   Complete example for how to initialize the Vulkan device, upload
14080           frames to the GPU, perform filter conversion to yuv420p, and
14081           download frames back to the CPU for output. Note that in specific
14082           cases you can get around the need to perform format conversion by
14083           specifying the correct "format" filter option corresponding to the
14084           input frames.
14085
14086                   ffmpeg -i $INPUT -init_hw_device vulkan -vf hwupload,libplacebo=format=yuv420p,hwdownload,format=yuv420p $OUTPUT
14087
14088       •   Tone-map input to standard gamut BT.709 output:
14089
14090                   libplacebo=colorspace=bt709:color_primaries=bt709:color_trc=bt709:range=tv
14091
14092       •   Rescale input to fit into standard 1080p, with high quality
14093           scaling:
14094
14095                   libplacebo=w=1920:h=1080:force_original_aspect_ratio=decrease:normalize_sar=true:upscaler=ewa_lanczos:downscaler=ewa_lanczos
14096
14097       •   Convert input to standard sRGB JPEG:
14098
14099                   libplacebo=format=yuv420p:colorspace=bt470bg:color_primaries=bt709:color_trc=iec61966-2-1:range=pc
14100
14101       •   Use higher quality debanding settings:
14102
14103                   libplacebo=deband=true:deband_iterations=3:deband_radius=8:deband_threshold=6
14104
14105       •   Run this filter on the CPU, on systems with Mesa installed (and
14106           with the most expensive options disabled):
14107
14108                   ffmpeg ... -init_hw_device vulkan:llvmpipe ... -vf libplacebo=upscaler=none:downscaler=none:peak_detect=false
14109
14110       •   Suppress CPU-based AV1/H.274 film grain application in the decoder,
14111           in favor of doing it with this filter. Note that this is only a
14112           gain if the frames are either already on the GPU, or if you're
14113           using libplacebo for other purposes, since otherwise the VRAM
14114           roundtrip will more than offset any expected speedup.
14115
14116                   ffmpeg -export_side_data +film_grain ... -vf libplacebo=apply_filmgrain=true
14117
14118   libvmaf
14119       Calulate the VMAF (Video Multi-Method Assessment Fusion) score for a
14120       reference/distorted pair of input videos.
14121
14122       The first input is the distorted video, and the second input is the
14123       reference video.
14124
14125       The obtained VMAF score is printed through the logging system.
14126
14127       It requires Netflix's vmaf library (libvmaf) as a pre-requisite.  After
14128       installing the library it can be enabled using: "./configure
14129       --enable-libvmaf".
14130
14131       The filter has following options:
14132
14133       model
14134           A `|` delimited list of vmaf models. Each model can be configured
14135           with a number of parameters.  Default value: "version=vmaf_v0.6.1"
14136
14137       model_path
14138           Deprecated, use model='path=...'.
14139
14140       enable_transform
14141           Deprecated, use model='enable_transform=true'.
14142
14143       phone_model
14144           Deprecated, use model='enable_transform=true'.
14145
14146       enable_conf_interval
14147           Deprecated, use model='enable_conf_interval=true'.
14148
14149       feature
14150           A `|` delimited list of features. Each feature can be configured
14151           with a number of parameters.
14152
14153       psnr
14154           Deprecated, use feature='name=psnr'.
14155
14156       ssim
14157           Deprecated, use feature='name=ssim'.
14158
14159       ms_ssim
14160           Deprecated, use feature='name=ms_ssim'.
14161
14162       log_path
14163           Set the file path to be used to store log files.
14164
14165       log_fmt
14166           Set the format of the log file (xml, json, csv, or sub).
14167
14168       n_threads
14169           Set number of threads to be used when initializing libvmaf.
14170           Default value: 0, no threads.
14171
14172       n_subsample
14173           Set frame subsampling interval to be used.
14174
14175       This filter also supports the framesync options.
14176
14177       Examples
14178
14179       •   In the examples below, a distorted video distorted.mpg is compared
14180           with a reference file reference.mpg.
14181
14182       •   Basic usage:
14183
14184                   ffmpeg -i distorted.mpg -i reference.mpg -lavfi libvmaf=log_path=output.xml -f null -
14185
14186       •   Example with multiple models:
14187
14188                   ffmpeg -i distorted.mpg -i reference.mpg -lavfi libvmaf='model=version=vmaf_v0.6.1\\:name=vmaf|version=vmaf_v0.6.1neg\\:name=vmaf_neg' -f null -
14189
14190       •   Example with multiple addtional features:
14191
14192                   ffmpeg -i distorted.mpg -i reference.mpg -lavfi libvmaf='feature=name=psnr|name=ciede' -f null -
14193
14194       •   Example with options and different containers:
14195
14196                   ffmpeg -i distorted.mpg -i reference.mkv -lavfi "[0:v]settb=AVTB,setpts=PTS-STARTPTS[main];[1:v]settb=AVTB,setpts=PTS-STARTPTS[ref];[main][ref]libvmaf=log_fmt=json:log_path=output.json" -f null -
14197
14198   limitdiff
14199       Apply limited difference filter using second and optionally third video
14200       stream.
14201
14202       The filter accepts the following options:
14203
14204       threshold
14205           Set the threshold to use when allowing certain differences between
14206           video streams.  Any absolute difference value lower or exact than
14207           this threshold will pick pixel components from first video stream.
14208
14209       elasticity
14210           Set the elasticity of soft thresholding when processing video
14211           streams.  This value multiplied with first one sets second
14212           threshold.  Any absolute difference value greater or exact than
14213           second threshold will pick pixel components from second video
14214           stream. For values between those two threshold linear interpolation
14215           between first and second video stream will be used.
14216
14217       reference
14218           Enable the reference (third) video stream processing. By default is
14219           disabled.  If set, this video stream will be used for calculating
14220           absolute difference with first video stream.
14221
14222       planes
14223           Specify which planes will be processed. Defaults to all available.
14224
14225       Commands
14226
14227       This filter supports the all above options as commands except option
14228       reference.
14229
14230   limiter
14231       Limits the pixel components values to the specified range [min, max].
14232
14233       The filter accepts the following options:
14234
14235       min Lower bound. Defaults to the lowest allowed value for the input.
14236
14237       max Upper bound. Defaults to the highest allowed value for the input.
14238
14239       planes
14240           Specify which planes will be processed. Defaults to all available.
14241
14242       Commands
14243
14244       This filter supports the all above options as commands.
14245
14246   loop
14247       Loop video frames.
14248
14249       The filter accepts the following options:
14250
14251       loop
14252           Set the number of loops. Setting this value to -1 will result in
14253           infinite loops.  Default is 0.
14254
14255       size
14256           Set maximal size in number of frames. Default is 0.
14257
14258       start
14259           Set first frame of loop. Default is 0.
14260
14261       Examples
14262
14263       •   Loop single first frame infinitely:
14264
14265                   loop=loop=-1:size=1:start=0
14266
14267       •   Loop single first frame 10 times:
14268
14269                   loop=loop=10:size=1:start=0
14270
14271       •   Loop 10 first frames 5 times:
14272
14273                   loop=loop=5:size=10:start=0
14274
14275   lut1d
14276       Apply a 1D LUT to an input video.
14277
14278       The filter accepts the following options:
14279
14280       file
14281           Set the 1D LUT file name.
14282
14283           Currently supported formats:
14284
14285           cube
14286               Iridas
14287
14288           csp cineSpace
14289
14290       interp
14291           Select interpolation mode.
14292
14293           Available values are:
14294
14295           nearest
14296               Use values from the nearest defined point.
14297
14298           linear
14299               Interpolate values using the linear interpolation.
14300
14301           cosine
14302               Interpolate values using the cosine interpolation.
14303
14304           cubic
14305               Interpolate values using the cubic interpolation.
14306
14307           spline
14308               Interpolate values using the spline interpolation.
14309
14310       Commands
14311
14312       This filter supports the all above options as commands.
14313
14314   lut3d
14315       Apply a 3D LUT to an input video.
14316
14317       The filter accepts the following options:
14318
14319       file
14320           Set the 3D LUT file name.
14321
14322           Currently supported formats:
14323
14324           3dl AfterEffects
14325
14326           cube
14327               Iridas
14328
14329           dat DaVinci
14330
14331           m3d Pandora
14332
14333           csp cineSpace
14334
14335       interp
14336           Select interpolation mode.
14337
14338           Available values are:
14339
14340           nearest
14341               Use values from the nearest defined point.
14342
14343           trilinear
14344               Interpolate values using the 8 points defining a cube.
14345
14346           tetrahedral
14347               Interpolate values using a tetrahedron.
14348
14349           pyramid
14350               Interpolate values using a pyramid.
14351
14352           prism
14353               Interpolate values using a prism.
14354
14355       Commands
14356
14357       This filter supports the "interp" option as commands.
14358
14359   lumakey
14360       Turn certain luma values into transparency.
14361
14362       The filter accepts the following options:
14363
14364       threshold
14365           Set the luma which will be used as base for transparency.  Default
14366           value is 0.
14367
14368       tolerance
14369           Set the range of luma values to be keyed out.  Default value is
14370           0.01.
14371
14372       softness
14373           Set the range of softness. Default value is 0.  Use this to control
14374           gradual transition from zero to full transparency.
14375
14376       Commands
14377
14378       This filter supports same commands as options.  The command accepts the
14379       same syntax of the corresponding option.
14380
14381       If the specified expression is not valid, it is kept at its current
14382       value.
14383
14384   lut, lutrgb, lutyuv
14385       Compute a look-up table for binding each pixel component input value to
14386       an output value, and apply it to the input video.
14387
14388       lutyuv applies a lookup table to a YUV input video, lutrgb to an RGB
14389       input video.
14390
14391       These filters accept the following parameters:
14392
14393       c0  set first pixel component expression
14394
14395       c1  set second pixel component expression
14396
14397       c2  set third pixel component expression
14398
14399       c3  set fourth pixel component expression, corresponds to the alpha
14400           component
14401
14402       r   set red component expression
14403
14404       g   set green component expression
14405
14406       b   set blue component expression
14407
14408       a   alpha component expression
14409
14410       y   set Y/luminance component expression
14411
14412       u   set U/Cb component expression
14413
14414       v   set V/Cr component expression
14415
14416       Each of them specifies the expression to use for computing the lookup
14417       table for the corresponding pixel component values.
14418
14419       The exact component associated to each of the c* options depends on the
14420       format in input.
14421
14422       The lut filter requires either YUV or RGB pixel formats in input,
14423       lutrgb requires RGB pixel formats in input, and lutyuv requires YUV.
14424
14425       The expressions can contain the following constants and functions:
14426
14427       w
14428       h   The input width and height.
14429
14430       val The input value for the pixel component.
14431
14432       clipval
14433           The input value, clipped to the minval-maxval range.
14434
14435       maxval
14436           The maximum value for the pixel component.
14437
14438       minval
14439           The minimum value for the pixel component.
14440
14441       negval
14442           The negated value for the pixel component value, clipped to the
14443           minval-maxval range; it corresponds to the expression
14444           "maxval-clipval+minval".
14445
14446       clip(val)
14447           The computed value in val, clipped to the minval-maxval range.
14448
14449       gammaval(gamma)
14450           The computed gamma correction value of the pixel component value,
14451           clipped to the minval-maxval range. It corresponds to the
14452           expression
14453           "pow((clipval-minval)/(maxval-minval)\,gamma)*(maxval-minval)+minval"
14454
14455       All expressions default to "clipval".
14456
14457       Commands
14458
14459       This filter supports same commands as options.
14460
14461       Examples
14462
14463       •   Negate input video:
14464
14465                   lutrgb="r=maxval+minval-val:g=maxval+minval-val:b=maxval+minval-val"
14466                   lutyuv="y=maxval+minval-val:u=maxval+minval-val:v=maxval+minval-val"
14467
14468           The above is the same as:
14469
14470                   lutrgb="r=negval:g=negval:b=negval"
14471                   lutyuv="y=negval:u=negval:v=negval"
14472
14473       •   Negate luminance:
14474
14475                   lutyuv=y=negval
14476
14477       •   Remove chroma components, turning the video into a graytone image:
14478
14479                   lutyuv="u=128:v=128"
14480
14481       •   Apply a luma burning effect:
14482
14483                   lutyuv="y=2*val"
14484
14485       •   Remove green and blue components:
14486
14487                   lutrgb="g=0:b=0"
14488
14489       •   Set a constant alpha channel value on input:
14490
14491                   format=rgba,lutrgb=a="maxval-minval/2"
14492
14493       •   Correct luminance gamma by a factor of 0.5:
14494
14495                   lutyuv=y=gammaval(0.5)
14496
14497       •   Discard least significant bits of luma:
14498
14499                   lutyuv=y='bitand(val, 128+64+32)'
14500
14501       •   Technicolor like effect:
14502
14503                   lutyuv=u='(val-maxval/2)*2+maxval/2':v='(val-maxval/2)*2+maxval/2'
14504
14505   lut2, tlut2
14506       The "lut2" filter takes two input streams and outputs one stream.
14507
14508       The "tlut2" (time lut2) filter takes two consecutive frames from one
14509       single stream.
14510
14511       This filter accepts the following parameters:
14512
14513       c0  set first pixel component expression
14514
14515       c1  set second pixel component expression
14516
14517       c2  set third pixel component expression
14518
14519       c3  set fourth pixel component expression, corresponds to the alpha
14520           component
14521
14522       d   set output bit depth, only available for "lut2" filter. By default
14523           is 0, which means bit depth is automatically picked from first
14524           input format.
14525
14526       The "lut2" filter also supports the framesync options.
14527
14528       Each of them specifies the expression to use for computing the lookup
14529       table for the corresponding pixel component values.
14530
14531       The exact component associated to each of the c* options depends on the
14532       format in inputs.
14533
14534       The expressions can contain the following constants:
14535
14536       w
14537       h   The input width and height.
14538
14539       x   The first input value for the pixel component.
14540
14541       y   The second input value for the pixel component.
14542
14543       bdx The first input video bit depth.
14544
14545       bdy The second input video bit depth.
14546
14547       All expressions default to "x".
14548
14549       Commands
14550
14551       This filter supports the all above options as commands except option
14552       "d".
14553
14554       Examples
14555
14556       •   Highlight differences between two RGB video streams:
14557
14558                   lut2='ifnot(x-y,0,pow(2,bdx)-1):ifnot(x-y,0,pow(2,bdx)-1):ifnot(x-y,0,pow(2,bdx)-1)'
14559
14560       •   Highlight differences between two YUV video streams:
14561
14562                   lut2='ifnot(x-y,0,pow(2,bdx)-1):ifnot(x-y,pow(2,bdx-1),pow(2,bdx)-1):ifnot(x-y,pow(2,bdx-1),pow(2,bdx)-1)'
14563
14564       •   Show max difference between two video streams:
14565
14566                   lut2='if(lt(x,y),0,if(gt(x,y),pow(2,bdx)-1,pow(2,bdx-1))):if(lt(x,y),0,if(gt(x,y),pow(2,bdx)-1,pow(2,bdx-1))):if(lt(x,y),0,if(gt(x,y),pow(2,bdx)-1,pow(2,bdx-1)))'
14567
14568   maskedclamp
14569       Clamp the first input stream with the second input and third input
14570       stream.
14571
14572       Returns the value of first stream to be between second input stream -
14573       "undershoot" and third input stream + "overshoot".
14574
14575       This filter accepts the following options:
14576
14577       undershoot
14578           Default value is 0.
14579
14580       overshoot
14581           Default value is 0.
14582
14583       planes
14584           Set which planes will be processed as bitmap, unprocessed planes
14585           will be copied from first stream.  By default value 0xf, all planes
14586           will be processed.
14587
14588       Commands
14589
14590       This filter supports the all above options as commands.
14591
14592   maskedmax
14593       Merge the second and third input stream into output stream using
14594       absolute differences between second input stream and first input stream
14595       and absolute difference between third input stream and first input
14596       stream. The picked value will be from second input stream if second
14597       absolute difference is greater than first one or from third input
14598       stream otherwise.
14599
14600       This filter accepts the following options:
14601
14602       planes
14603           Set which planes will be processed as bitmap, unprocessed planes
14604           will be copied from first stream.  By default value 0xf, all planes
14605           will be processed.
14606
14607       Commands
14608
14609       This filter supports the all above options as commands.
14610
14611   maskedmerge
14612       Merge the first input stream with the second input stream using per
14613       pixel weights in the third input stream.
14614
14615       A value of 0 in the third stream pixel component means that pixel
14616       component from first stream is returned unchanged, while maximum value
14617       (eg. 255 for 8-bit videos) means that pixel component from second
14618       stream is returned unchanged. Intermediate values define the amount of
14619       merging between both input stream's pixel components.
14620
14621       This filter accepts the following options:
14622
14623       planes
14624           Set which planes will be processed as bitmap, unprocessed planes
14625           will be copied from first stream.  By default value 0xf, all planes
14626           will be processed.
14627
14628       Commands
14629
14630       This filter supports the all above options as commands.
14631
14632   maskedmin
14633       Merge the second and third input stream into output stream using
14634       absolute differences between second input stream and first input stream
14635       and absolute difference between third input stream and first input
14636       stream. The picked value will be from second input stream if second
14637       absolute difference is less than first one or from third input stream
14638       otherwise.
14639
14640       This filter accepts the following options:
14641
14642       planes
14643           Set which planes will be processed as bitmap, unprocessed planes
14644           will be copied from first stream.  By default value 0xf, all planes
14645           will be processed.
14646
14647       Commands
14648
14649       This filter supports the all above options as commands.
14650
14651   maskedthreshold
14652       Pick pixels comparing absolute difference of two video streams with
14653       fixed threshold.
14654
14655       If absolute difference between pixel component of first and second
14656       video stream is equal or lower than user supplied threshold than pixel
14657       component from first video stream is picked, otherwise pixel component
14658       from second video stream is picked.
14659
14660       This filter accepts the following options:
14661
14662       threshold
14663           Set threshold used when picking pixels from absolute difference
14664           from two input video streams.
14665
14666       planes
14667           Set which planes will be processed as bitmap, unprocessed planes
14668           will be copied from second stream.  By default value 0xf, all
14669           planes will be processed.
14670
14671       Commands
14672
14673       This filter supports the all above options as commands.
14674
14675   maskfun
14676       Create mask from input video.
14677
14678       For example it is useful to create motion masks after "tblend" filter.
14679
14680       This filter accepts the following options:
14681
14682       low Set low threshold. Any pixel component lower or exact than this
14683           value will be set to 0.
14684
14685       high
14686           Set high threshold. Any pixel component higher than this value will
14687           be set to max value allowed for current pixel format.
14688
14689       planes
14690           Set planes to filter, by default all available planes are filtered.
14691
14692       fill
14693           Fill all frame pixels with this value.
14694
14695       sum Set max average pixel value for frame. If sum of all pixel
14696           components is higher that this average, output frame will be
14697           completely filled with value set by fill option.  Typically useful
14698           for scene changes when used in combination with "tblend" filter.
14699
14700       Commands
14701
14702       This filter supports the all above options as commands.
14703
14704   mcdeint
14705       Apply motion-compensation deinterlacing.
14706
14707       It needs one field per frame as input and must thus be used together
14708       with yadif=1/3 or equivalent.
14709
14710       This filter is only available in ffmpeg version 4.4 or earlier.
14711
14712       This filter accepts the following options:
14713
14714       mode
14715           Set the deinterlacing mode.
14716
14717           It accepts one of the following values:
14718
14719           fast
14720           medium
14721           slow
14722               use iterative motion estimation
14723
14724           extra_slow
14725               like slow, but use multiple reference frames.
14726
14727           Default value is fast.
14728
14729       parity
14730           Set the picture field parity assumed for the input video. It must
14731           be one of the following values:
14732
14733           0, tff
14734               assume top field first
14735
14736           1, bff
14737               assume bottom field first
14738
14739           Default value is bff.
14740
14741       qp  Set per-block quantization parameter (QP) used by the internal
14742           encoder.
14743
14744           Higher values should result in a smoother motion vector field but
14745           less optimal individual vectors. Default value is 1.
14746
14747   median
14748       Pick median pixel from certain rectangle defined by radius.
14749
14750       This filter accepts the following options:
14751
14752       radius
14753           Set horizontal radius size. Default value is 1.  Allowed range is
14754           integer from 1 to 127.
14755
14756       planes
14757           Set which planes to process. Default is 15, which is all available
14758           planes.
14759
14760       radiusV
14761           Set vertical radius size. Default value is 0.  Allowed range is
14762           integer from 0 to 127.  If it is 0, value will be picked from
14763           horizontal "radius" option.
14764
14765       percentile
14766           Set median percentile. Default value is 0.5.  Default value of 0.5
14767           will pick always median values, while 0 will pick minimum values,
14768           and 1 maximum values.
14769
14770       Commands
14771
14772       This filter supports same commands as options.  The command accepts the
14773       same syntax of the corresponding option.
14774
14775       If the specified expression is not valid, it is kept at its current
14776       value.
14777
14778   mergeplanes
14779       Merge color channel components from several video streams.
14780
14781       The filter accepts up to 4 input streams, and merge selected input
14782       planes to the output video.
14783
14784       This filter accepts the following options:
14785
14786       mapping
14787           Set input to output plane mapping. Default is 0.
14788
14789           The mappings is specified as a bitmap. It should be specified as a
14790           hexadecimal number in the form 0xAa[Bb[Cc[Dd]]]. 'Aa' describes the
14791           mapping for the first plane of the output stream. 'A' sets the
14792           number of the input stream to use (from 0 to 3), and 'a' the plane
14793           number of the corresponding input to use (from 0 to 3). The rest of
14794           the mappings is similar, 'Bb' describes the mapping for the output
14795           stream second plane, 'Cc' describes the mapping for the output
14796           stream third plane and 'Dd' describes the mapping for the output
14797           stream fourth plane.
14798
14799       format
14800           Set output pixel format. Default is "yuva444p".
14801
14802       map0s
14803       map1s
14804       map2s
14805       map3s
14806           Set input to output stream mapping for output Nth plane. Default is
14807           0.
14808
14809       map0p
14810       map1p
14811       map2p
14812       map3p
14813           Set input to output plane mapping for output Nth plane. Default is
14814           0.
14815
14816       Examples
14817
14818       •   Merge three gray video streams of same width and height into single
14819           video stream:
14820
14821                   [a0][a1][a2]mergeplanes=0x001020:yuv444p
14822
14823       •   Merge 1st yuv444p stream and 2nd gray video stream into yuva444p
14824           video stream:
14825
14826                   [a0][a1]mergeplanes=0x00010210:yuva444p
14827
14828       •   Swap Y and A plane in yuva444p stream:
14829
14830                   format=yuva444p,mergeplanes=0x03010200:yuva444p
14831
14832       •   Swap U and V plane in yuv420p stream:
14833
14834                   format=yuv420p,mergeplanes=0x000201:yuv420p
14835
14836       •   Cast a rgb24 clip to yuv444p:
14837
14838                   format=rgb24,mergeplanes=0x000102:yuv444p
14839
14840   mestimate
14841       Estimate and export motion vectors using block matching algorithms.
14842       Motion vectors are stored in frame side data to be used by other
14843       filters.
14844
14845       This filter accepts the following options:
14846
14847       method
14848           Specify the motion estimation method. Accepts one of the following
14849           values:
14850
14851           esa Exhaustive search algorithm.
14852
14853           tss Three step search algorithm.
14854
14855           tdls
14856               Two dimensional logarithmic search algorithm.
14857
14858           ntss
14859               New three step search algorithm.
14860
14861           fss Four step search algorithm.
14862
14863           ds  Diamond search algorithm.
14864
14865           hexbs
14866               Hexagon-based search algorithm.
14867
14868           epzs
14869               Enhanced predictive zonal search algorithm.
14870
14871           umh Uneven multi-hexagon search algorithm.
14872
14873           Default value is esa.
14874
14875       mb_size
14876           Macroblock size. Default 16.
14877
14878       search_param
14879           Search parameter. Default 7.
14880
14881   midequalizer
14882       Apply Midway Image Equalization effect using two video streams.
14883
14884       Midway Image Equalization adjusts a pair of images to have the same
14885       histogram, while maintaining their dynamics as much as possible. It's
14886       useful for e.g. matching exposures from a pair of stereo cameras.
14887
14888       This filter has two inputs and one output, which must be of same pixel
14889       format, but may be of different sizes. The output of filter is first
14890       input adjusted with midway histogram of both inputs.
14891
14892       This filter accepts the following option:
14893
14894       planes
14895           Set which planes to process. Default is 15, which is all available
14896           planes.
14897
14898   minterpolate
14899       Convert the video to specified frame rate using motion interpolation.
14900
14901       This filter accepts the following options:
14902
14903       fps Specify the output frame rate. This can be rational e.g.
14904           "60000/1001". Frames are dropped if fps is lower than source fps.
14905           Default 60.
14906
14907       mi_mode
14908           Motion interpolation mode. Following values are accepted:
14909
14910           dup Duplicate previous or next frame for interpolating new ones.
14911
14912           blend
14913               Blend source frames. Interpolated frame is mean of previous and
14914               next frames.
14915
14916           mci Motion compensated interpolation. Following options are
14917               effective when this mode is selected:
14918
14919               mc_mode
14920                   Motion compensation mode. Following values are accepted:
14921
14922                   obmc
14923                       Overlapped block motion compensation.
14924
14925                   aobmc
14926                       Adaptive overlapped block motion compensation. Window
14927                       weighting coefficients are controlled adaptively
14928                       according to the reliabilities of the neighboring
14929                       motion vectors to reduce oversmoothing.
14930
14931                   Default mode is obmc.
14932
14933               me_mode
14934                   Motion estimation mode. Following values are accepted:
14935
14936                   bidir
14937                       Bidirectional motion estimation. Motion vectors are
14938                       estimated for each source frame in both forward and
14939                       backward directions.
14940
14941                   bilat
14942                       Bilateral motion estimation. Motion vectors are
14943                       estimated directly for interpolated frame.
14944
14945                   Default mode is bilat.
14946
14947               me  The algorithm to be used for motion estimation. Following
14948                   values are accepted:
14949
14950                   esa Exhaustive search algorithm.
14951
14952                   tss Three step search algorithm.
14953
14954                   tdls
14955                       Two dimensional logarithmic search algorithm.
14956
14957                   ntss
14958                       New three step search algorithm.
14959
14960                   fss Four step search algorithm.
14961
14962                   ds  Diamond search algorithm.
14963
14964                   hexbs
14965                       Hexagon-based search algorithm.
14966
14967                   epzs
14968                       Enhanced predictive zonal search algorithm.
14969
14970                   umh Uneven multi-hexagon search algorithm.
14971
14972                   Default algorithm is epzs.
14973
14974               mb_size
14975                   Macroblock size. Default 16.
14976
14977               search_param
14978                   Motion estimation search parameter. Default 32.
14979
14980               vsbmc
14981                   Enable variable-size block motion compensation. Motion
14982                   estimation is applied with smaller block sizes at object
14983                   boundaries in order to make the them less blur. Default is
14984                   0 (disabled).
14985
14986       scd Scene change detection method. Scene change leads motion vectors to
14987           be in random direction. Scene change detection replace interpolated
14988           frames by duplicate ones. May not be needed for other modes.
14989           Following values are accepted:
14990
14991           none
14992               Disable scene change detection.
14993
14994           fdiff
14995               Frame difference. Corresponding pixel values are compared and
14996               if it satisfies scd_threshold scene change is detected.
14997
14998           Default method is fdiff.
14999
15000       scd_threshold
15001           Scene change detection threshold. Default is 10..
15002
15003   mix
15004       Mix several video input streams into one video stream.
15005
15006       A description of the accepted options follows.
15007
15008       inputs
15009           The number of inputs. If unspecified, it defaults to 2.
15010
15011       weights
15012           Specify weight of each input video stream as sequence.  Each weight
15013           is separated by space. If number of weights is smaller than number
15014           of frames last specified weight will be used for all remaining
15015           unset weights.
15016
15017       scale
15018           Specify scale, if it is set it will be multiplied with sum of each
15019           weight multiplied with pixel values to give final destination pixel
15020           value. By default scale is auto scaled to sum of weights.
15021
15022       planes
15023           Set which planes to filter. Default is all. Allowed range is from 0
15024           to 15.
15025
15026       duration
15027           Specify how end of stream is determined.
15028
15029           longest
15030               The duration of the longest input. (default)
15031
15032           shortest
15033               The duration of the shortest input.
15034
15035           first
15036               The duration of the first input.
15037
15038       Commands
15039
15040       This filter supports the following commands:
15041
15042       weights
15043       scale
15044       planes
15045           Syntax is same as option with same name.
15046
15047   monochrome
15048       Convert video to gray using custom color filter.
15049
15050       A description of the accepted options follows.
15051
15052       cb  Set the chroma blue spot. Allowed range is from -1 to 1.  Default
15053           value is 0.
15054
15055       cr  Set the chroma red spot. Allowed range is from -1 to 1.  Default
15056           value is 0.
15057
15058       size
15059           Set the color filter size. Allowed range is from .1 to 10.  Default
15060           value is 1.
15061
15062       high
15063           Set the highlights strength. Allowed range is from 0 to 1.  Default
15064           value is 0.
15065
15066       Commands
15067
15068       This filter supports the all above options as commands.
15069
15070   morpho
15071       This filter allows to apply main morphological grayscale transforms,
15072       erode and dilate with arbitrary structures set in second input stream.
15073
15074       Unlike naive implementation and much slower performance in erosion and
15075       dilation filters, when speed is critical "morpho" filter should be used
15076       instead.
15077
15078       A description of accepted options follows,
15079
15080       mode
15081           Set morphological transform to apply, can be:
15082
15083           erode
15084           dilate
15085           open
15086           close
15087           gradient
15088           tophat
15089           blackhat
15090
15091           Default is "erode".
15092
15093       planes
15094           Set planes to filter, by default all planes except alpha are
15095           filtered.
15096
15097       structure
15098           Set which structure video frames will be processed from second
15099           input stream, can be first or all. Default is all.
15100
15101       The "morpho" filter also supports the framesync options.
15102
15103       Commands
15104
15105       This filter supports same commands as options.
15106
15107   mpdecimate
15108       Drop frames that do not differ greatly from the previous frame in order
15109       to reduce frame rate.
15110
15111       The main use of this filter is for very-low-bitrate encoding (e.g.
15112       streaming over dialup modem), but it could in theory be used for fixing
15113       movies that were inverse-telecined incorrectly.
15114
15115       A description of the accepted options follows.
15116
15117       max Set the maximum number of consecutive frames which can be dropped
15118           (if positive), or the minimum interval between dropped frames (if
15119           negative). If the value is 0, the frame is dropped disregarding the
15120           number of previous sequentially dropped frames.
15121
15122           Default value is 0.
15123
15124       hi
15125       lo
15126       frac
15127           Set the dropping threshold values.
15128
15129           Values for hi and lo are for 8x8 pixel blocks and represent actual
15130           pixel value differences, so a threshold of 64 corresponds to 1 unit
15131           of difference for each pixel, or the same spread out differently
15132           over the block.
15133
15134           A frame is a candidate for dropping if no 8x8 blocks differ by more
15135           than a threshold of hi, and if no more than frac blocks (1 meaning
15136           the whole image) differ by more than a threshold of lo.
15137
15138           Default value for hi is 64*12, default value for lo is 64*5, and
15139           default value for frac is 0.33.
15140
15141   msad
15142       Obtain the MSAD (Mean Sum of Absolute Differences) between two input
15143       videos.
15144
15145       This filter takes two input videos.
15146
15147       Both input videos must have the same resolution and pixel format for
15148       this filter to work correctly. Also it assumes that both inputs have
15149       the same number of frames, which are compared one by one.
15150
15151       The obtained per component, average, min and max MSAD is printed
15152       through the logging system.
15153
15154       The filter stores the calculated MSAD of each frame in frame metadata.
15155
15156       In the below example the input file main.mpg being processed is
15157       compared with the reference file ref.mpg.
15158
15159               ffmpeg -i main.mpg -i ref.mpg -lavfi msad -f null -
15160
15161   multiply
15162       Multiply first video stream pixels values with second video stream
15163       pixels values.
15164
15165       The filter accepts the following options:
15166
15167       scale
15168           Set the scale applied to second video stream. By default is 1.
15169           Allowed range is from 0 to 9.
15170
15171       offset
15172           Set the offset applied to second video stream. By default is 0.5.
15173           Allowed range is from "-1" to 1.
15174
15175       planes
15176           Specify planes from input video stream that will be processed.  By
15177           default all planes are processed.
15178
15179       Commands
15180
15181       This filter supports same commands as options.
15182
15183   negate
15184       Negate (invert) the input video.
15185
15186       It accepts the following option:
15187
15188       components
15189           Set components to negate.
15190
15191           Available values for components are:
15192
15193           y
15194           u
15195           v
15196           a
15197           r
15198           g
15199           b
15200       negate_alpha
15201           With value 1, it negates the alpha component, if present. Default
15202           value is 0.
15203
15204       Commands
15205
15206       This filter supports same commands as options.
15207
15208   nlmeans
15209       Denoise frames using Non-Local Means algorithm.
15210
15211       Each pixel is adjusted by looking for other pixels with similar
15212       contexts. This context similarity is defined by comparing their
15213       surrounding patches of size pxp. Patches are searched in an area of rxr
15214       around the pixel.
15215
15216       Note that the research area defines centers for patches, which means
15217       some patches will be made of pixels outside that research area.
15218
15219       The filter accepts the following options.
15220
15221       s   Set denoising strength. Default is 1.0. Must be in range [1.0,
15222           30.0].
15223
15224       p   Set patch size. Default is 7. Must be odd number in range [0, 99].
15225
15226       pc  Same as p but for chroma planes.
15227
15228           The default value is 0 and means automatic.
15229
15230       r   Set research size. Default is 15. Must be odd number in range [0,
15231           99].
15232
15233       rc  Same as r but for chroma planes.
15234
15235           The default value is 0 and means automatic.
15236
15237   nnedi
15238       Deinterlace video using neural network edge directed interpolation.
15239
15240       This filter accepts the following options:
15241
15242       weights
15243           Mandatory option, without binary file filter can not work.
15244           Currently file can be found here:
15245           https://github.com/dubhater/vapoursynth-nnedi3/blob/master/src/nnedi3_weights.bin
15246
15247       deint
15248           Set which frames to deinterlace, by default it is "all".  Can be
15249           "all" or "interlaced".
15250
15251       field
15252           Set mode of operation.
15253
15254           Can be one of the following:
15255
15256           af  Use frame flags, both fields.
15257
15258           a   Use frame flags, single field.
15259
15260           t   Use top field only.
15261
15262           b   Use bottom field only.
15263
15264           tf  Use both fields, top first.
15265
15266           bf  Use both fields, bottom first.
15267
15268       planes
15269           Set which planes to process, by default filter process all frames.
15270
15271       nsize
15272           Set size of local neighborhood around each pixel, used by the
15273           predictor neural network.
15274
15275           Can be one of the following:
15276
15277           s8x6
15278           s16x6
15279           s32x6
15280           s48x6
15281           s8x4
15282           s16x4
15283           s32x4
15284       nns Set the number of neurons in predictor neural network.  Can be one
15285           of the following:
15286
15287           n16
15288           n32
15289           n64
15290           n128
15291           n256
15292       qual
15293           Controls the number of different neural network predictions that
15294           are blended together to compute the final output value. Can be
15295           "fast", default or "slow".
15296
15297       etype
15298           Set which set of weights to use in the predictor.  Can be one of
15299           the following:
15300
15301           a, abs
15302               weights trained to minimize absolute error
15303
15304           s, mse
15305               weights trained to minimize squared error
15306
15307       pscrn
15308           Controls whether or not the prescreener neural network is used to
15309           decide which pixels should be processed by the predictor neural
15310           network and which can be handled by simple cubic interpolation.
15311           The prescreener is trained to know whether cubic interpolation will
15312           be sufficient for a pixel or whether it should be predicted by the
15313           predictor nn.  The computational complexity of the prescreener nn
15314           is much less than that of the predictor nn. Since most pixels can
15315           be handled by cubic interpolation, using the prescreener generally
15316           results in much faster processing.  The prescreener is pretty
15317           accurate, so the difference between using it and not using it is
15318           almost always unnoticeable.
15319
15320           Can be one of the following:
15321
15322           none
15323           original
15324           new
15325           new2
15326           new3
15327
15328           Default is "new".
15329
15330       Commands
15331
15332       This filter supports same commands as options, excluding weights
15333       option.
15334
15335   noformat
15336       Force libavfilter not to use any of the specified pixel formats for the
15337       input to the next filter.
15338
15339       It accepts the following parameters:
15340
15341       pix_fmts
15342           A '|'-separated list of pixel format names, such as
15343           pix_fmts=yuv420p|monow|rgb24".
15344
15345       Examples
15346
15347       •   Force libavfilter to use a format different from yuv420p for the
15348           input to the vflip filter:
15349
15350                   noformat=pix_fmts=yuv420p,vflip
15351
15352       •   Convert the input video to any of the formats not contained in the
15353           list:
15354
15355                   noformat=yuv420p|yuv444p|yuv410p
15356
15357   noise
15358       Add noise on video input frame.
15359
15360       The filter accepts the following options:
15361
15362       all_seed
15363       c0_seed
15364       c1_seed
15365       c2_seed
15366       c3_seed
15367           Set noise seed for specific pixel component or all pixel components
15368           in case of all_seed. Default value is 123457.
15369
15370       all_strength, alls
15371       c0_strength, c0s
15372       c1_strength, c1s
15373       c2_strength, c2s
15374       c3_strength, c3s
15375           Set noise strength for specific pixel component or all pixel
15376           components in case all_strength. Default value is 0. Allowed range
15377           is [0, 100].
15378
15379       all_flags, allf
15380       c0_flags, c0f
15381       c1_flags, c1f
15382       c2_flags, c2f
15383       c3_flags, c3f
15384           Set pixel component flags or set flags for all components if
15385           all_flags.  Available values for component flags are:
15386
15387           a   averaged temporal noise (smoother)
15388
15389           p   mix random noise with a (semi)regular pattern
15390
15391           t   temporal noise (noise pattern changes between frames)
15392
15393           u   uniform noise (gaussian otherwise)
15394
15395       Examples
15396
15397       Add temporal and uniform noise to input video:
15398
15399               noise=alls=20:allf=t+u
15400
15401   normalize
15402       Normalize RGB video (aka histogram stretching, contrast stretching).
15403       See: https://en.wikipedia.org/wiki/Normalization_(image_processing)
15404
15405       For each channel of each frame, the filter computes the input range and
15406       maps it linearly to the user-specified output range. The output range
15407       defaults to the full dynamic range from pure black to pure white.
15408
15409       Temporal smoothing can be used on the input range to reduce flickering
15410       (rapid changes in brightness) caused when small dark or bright objects
15411       enter or leave the scene. This is similar to the auto-exposure
15412       (automatic gain control) on a video camera, and, like a video camera,
15413       it may cause a period of over- or under-exposure of the video.
15414
15415       The R,G,B channels can be normalized independently, which may cause
15416       some color shifting, or linked together as a single channel, which
15417       prevents color shifting. Linked normalization preserves hue.
15418       Independent normalization does not, so it can be used to remove some
15419       color casts. Independent and linked normalization can be combined in
15420       any ratio.
15421
15422       The normalize filter accepts the following options:
15423
15424       blackpt
15425       whitept
15426           Colors which define the output range. The minimum input value is
15427           mapped to the blackpt. The maximum input value is mapped to the
15428           whitept.  The defaults are black and white respectively. Specifying
15429           white for blackpt and black for whitept will give color-inverted,
15430           normalized video. Shades of grey can be used to reduce the dynamic
15431           range (contrast). Specifying saturated colors here can create some
15432           interesting effects.
15433
15434       smoothing
15435           The number of previous frames to use for temporal smoothing. The
15436           input range of each channel is smoothed using a rolling average
15437           over the current frame and the smoothing previous frames. The
15438           default is 0 (no temporal smoothing).
15439
15440       independence
15441           Controls the ratio of independent (color shifting) channel
15442           normalization to linked (color preserving) normalization. 0.0 is
15443           fully linked, 1.0 is fully independent. Defaults to 1.0 (fully
15444           independent).
15445
15446       strength
15447           Overall strength of the filter. 1.0 is full strength. 0.0 is a
15448           rather expensive no-op. Defaults to 1.0 (full strength).
15449
15450       Commands
15451
15452       This filter supports same commands as options, excluding smoothing
15453       option.  The command accepts the same syntax of the corresponding
15454       option.
15455
15456       If the specified expression is not valid, it is kept at its current
15457       value.
15458
15459       Examples
15460
15461       Stretch video contrast to use the full dynamic range, with no temporal
15462       smoothing; may flicker depending on the source content:
15463
15464               normalize=blackpt=black:whitept=white:smoothing=0
15465
15466       As above, but with 50 frames of temporal smoothing; flicker should be
15467       reduced, depending on the source content:
15468
15469               normalize=blackpt=black:whitept=white:smoothing=50
15470
15471       As above, but with hue-preserving linked channel normalization:
15472
15473               normalize=blackpt=black:whitept=white:smoothing=50:independence=0
15474
15475       As above, but with half strength:
15476
15477               normalize=blackpt=black:whitept=white:smoothing=50:independence=0:strength=0.5
15478
15479       Map the darkest input color to red, the brightest input color to cyan:
15480
15481               normalize=blackpt=red:whitept=cyan
15482
15483   null
15484       Pass the video source unchanged to the output.
15485
15486   ocr
15487       Optical Character Recognition
15488
15489       This filter uses Tesseract for optical character recognition. To enable
15490       compilation of this filter, you need to configure FFmpeg with
15491       "--enable-libtesseract".
15492
15493       It accepts the following options:
15494
15495       datapath
15496           Set datapath to tesseract data. Default is to use whatever was set
15497           at installation.
15498
15499       language
15500           Set language, default is "eng".
15501
15502       whitelist
15503           Set character whitelist.
15504
15505       blacklist
15506           Set character blacklist.
15507
15508       The filter exports recognized text as the frame metadata
15509       "lavfi.ocr.text".  The filter exports confidence of recognized words as
15510       the frame metadata "lavfi.ocr.confidence".
15511
15512   ocv
15513       Apply a video transform using libopencv.
15514
15515       To enable this filter, install the libopencv library and headers and
15516       configure FFmpeg with "--enable-libopencv".
15517
15518       It accepts the following parameters:
15519
15520       filter_name
15521           The name of the libopencv filter to apply.
15522
15523       filter_params
15524           The parameters to pass to the libopencv filter. If not specified,
15525           the default values are assumed.
15526
15527       Refer to the official libopencv documentation for more precise
15528       information:
15529       <http://docs.opencv.org/master/modules/imgproc/doc/filtering.html>
15530
15531       Several libopencv filters are supported; see the following subsections.
15532
15533       dilate
15534
15535       Dilate an image by using a specific structuring element.  It
15536       corresponds to the libopencv function "cvDilate".
15537
15538       It accepts the parameters: struct_el|nb_iterations.
15539
15540       struct_el represents a structuring element, and has the syntax:
15541       colsxrows+anchor_xxanchor_y/shape
15542
15543       cols and rows represent the number of columns and rows of the
15544       structuring element, anchor_x and anchor_y the anchor point, and shape
15545       the shape for the structuring element. shape must be "rect", "cross",
15546       "ellipse", or "custom".
15547
15548       If the value for shape is "custom", it must be followed by a string of
15549       the form "=filename". The file with name filename is assumed to
15550       represent a binary image, with each printable character corresponding
15551       to a bright pixel. When a custom shape is used, cols and rows are
15552       ignored, the number or columns and rows of the read file are assumed
15553       instead.
15554
15555       The default value for struct_el is "3x3+0x0/rect".
15556
15557       nb_iterations specifies the number of times the transform is applied to
15558       the image, and defaults to 1.
15559
15560       Some examples:
15561
15562               # Use the default values
15563               ocv=dilate
15564
15565               # Dilate using a structuring element with a 5x5 cross, iterating two times
15566               ocv=filter_name=dilate:filter_params=5x5+2x2/cross|2
15567
15568               # Read the shape from the file diamond.shape, iterating two times.
15569               # The file diamond.shape may contain a pattern of characters like this
15570               #   *
15571               #  ***
15572               # *****
15573               #  ***
15574               #   *
15575               # The specified columns and rows are ignored
15576               # but the anchor point coordinates are not
15577               ocv=dilate:0x0+2x2/custom=diamond.shape|2
15578
15579       erode
15580
15581       Erode an image by using a specific structuring element.  It corresponds
15582       to the libopencv function "cvErode".
15583
15584       It accepts the parameters: struct_el:nb_iterations, with the same
15585       syntax and semantics as the dilate filter.
15586
15587       smooth
15588
15589       Smooth the input video.
15590
15591       The filter takes the following parameters:
15592       type|param1|param2|param3|param4.
15593
15594       type is the type of smooth filter to apply, and must be one of the
15595       following values: "blur", "blur_no_scale", "median", "gaussian", or
15596       "bilateral". The default value is "gaussian".
15597
15598       The meaning of param1, param2, param3, and param4 depends on the smooth
15599       type. param1 and param2 accept integer positive values or 0. param3 and
15600       param4 accept floating point values.
15601
15602       The default value for param1 is 3. The default value for the other
15603       parameters is 0.
15604
15605       These parameters correspond to the parameters assigned to the libopencv
15606       function "cvSmooth".
15607
15608   oscilloscope
15609       2D Video Oscilloscope.
15610
15611       Useful to measure spatial impulse, step responses, chroma delays, etc.
15612
15613       It accepts the following parameters:
15614
15615       x   Set scope center x position.
15616
15617       y   Set scope center y position.
15618
15619       s   Set scope size, relative to frame diagonal.
15620
15621       t   Set scope tilt/rotation.
15622
15623       o   Set trace opacity.
15624
15625       tx  Set trace center x position.
15626
15627       ty  Set trace center y position.
15628
15629       tw  Set trace width, relative to width of frame.
15630
15631       th  Set trace height, relative to height of frame.
15632
15633       c   Set which components to trace. By default it traces first three
15634           components.
15635
15636       g   Draw trace grid. By default is enabled.
15637
15638       st  Draw some statistics. By default is enabled.
15639
15640       sc  Draw scope. By default is enabled.
15641
15642       Commands
15643
15644       This filter supports same commands as options.  The command accepts the
15645       same syntax of the corresponding option.
15646
15647       If the specified expression is not valid, it is kept at its current
15648       value.
15649
15650       Examples
15651
15652       •   Inspect full first row of video frame.
15653
15654                   oscilloscope=x=0.5:y=0:s=1
15655
15656       •   Inspect full last row of video frame.
15657
15658                   oscilloscope=x=0.5:y=1:s=1
15659
15660       •   Inspect full 5th line of video frame of height 1080.
15661
15662                   oscilloscope=x=0.5:y=5/1080:s=1
15663
15664       •   Inspect full last column of video frame.
15665
15666                   oscilloscope=x=1:y=0.5:s=1:t=1
15667
15668   overlay
15669       Overlay one video on top of another.
15670
15671       It takes two inputs and has one output. The first input is the "main"
15672       video on which the second input is overlaid.
15673
15674       It accepts the following parameters:
15675
15676       A description of the accepted options follows.
15677
15678       x
15679       y   Set the expression for the x and y coordinates of the overlaid
15680           video on the main video. Default value is "0" for both expressions.
15681           In case the expression is invalid, it is set to a huge value
15682           (meaning that the overlay will not be displayed within the output
15683           visible area).
15684
15685       eof_action
15686           See framesync.
15687
15688       eval
15689           Set when the expressions for x, and y are evaluated.
15690
15691           It accepts the following values:
15692
15693           init
15694               only evaluate expressions once during the filter initialization
15695               or when a command is processed
15696
15697           frame
15698               evaluate expressions for each incoming frame
15699
15700           Default value is frame.
15701
15702       shortest
15703           See framesync.
15704
15705       format
15706           Set the format for the output video.
15707
15708           It accepts the following values:
15709
15710           yuv420
15711               force YUV420 output
15712
15713           yuv420p10
15714               force YUV420p10 output
15715
15716           yuv422
15717               force YUV422 output
15718
15719           yuv422p10
15720               force YUV422p10 output
15721
15722           yuv444
15723               force YUV444 output
15724
15725           rgb force packed RGB output
15726
15727           gbrp
15728               force planar RGB output
15729
15730           auto
15731               automatically pick format
15732
15733           Default value is yuv420.
15734
15735       repeatlast
15736           See framesync.
15737
15738       alpha
15739           Set format of alpha of the overlaid video, it can be straight or
15740           premultiplied. Default is straight.
15741
15742       The x, and y expressions can contain the following parameters.
15743
15744       main_w, W
15745       main_h, H
15746           The main input width and height.
15747
15748       overlay_w, w
15749       overlay_h, h
15750           The overlay input width and height.
15751
15752       x
15753       y   The computed values for x and y. They are evaluated for each new
15754           frame.
15755
15756       hsub
15757       vsub
15758           horizontal and vertical chroma subsample values of the output
15759           format. For example for the pixel format "yuv422p" hsub is 2 and
15760           vsub is 1.
15761
15762       n   the number of input frame, starting from 0
15763
15764       pos the position in the file of the input frame, NAN if unknown
15765
15766       t   The timestamp, expressed in seconds. It's NAN if the input
15767           timestamp is unknown.
15768
15769       This filter also supports the framesync options.
15770
15771       Note that the n, pos, t variables are available only when evaluation is
15772       done per frame, and will evaluate to NAN when eval is set to init.
15773
15774       Be aware that frames are taken from each input video in timestamp
15775       order, hence, if their initial timestamps differ, it is a good idea to
15776       pass the two inputs through a setpts=PTS-STARTPTS filter to have them
15777       begin in the same zero timestamp, as the example for the movie filter
15778       does.
15779
15780       You can chain together more overlays but you should test the efficiency
15781       of such approach.
15782
15783       Commands
15784
15785       This filter supports the following commands:
15786
15787       x
15788       y   Modify the x and y of the overlay input.  The command accepts the
15789           same syntax of the corresponding option.
15790
15791           If the specified expression is not valid, it is kept at its current
15792           value.
15793
15794       Examples
15795
15796       •   Draw the overlay at 10 pixels from the bottom right corner of the
15797           main video:
15798
15799                   overlay=main_w-overlay_w-10:main_h-overlay_h-10
15800
15801           Using named options the example above becomes:
15802
15803                   overlay=x=main_w-overlay_w-10:y=main_h-overlay_h-10
15804
15805       •   Insert a transparent PNG logo in the bottom left corner of the
15806           input, using the ffmpeg tool with the "-filter_complex" option:
15807
15808                   ffmpeg -i input -i logo -filter_complex 'overlay=10:main_h-overlay_h-10' output
15809
15810       •   Insert 2 different transparent PNG logos (second logo on bottom
15811           right corner) using the ffmpeg tool:
15812
15813                   ffmpeg -i input -i logo1 -i logo2 -filter_complex 'overlay=x=10:y=H-h-10,overlay=x=W-w-10:y=H-h-10' output
15814
15815       •   Add a transparent color layer on top of the main video; "WxH" must
15816           specify the size of the main input to the overlay filter:
15817
15818                   color=color=red@.3:size=WxH [over]; [in][over] overlay [out]
15819
15820       •   Play an original video and a filtered version (here with the
15821           deshake filter) side by side using the ffplay tool:
15822
15823                   ffplay input.avi -vf 'split[a][b]; [a]pad=iw*2:ih[src]; [b]deshake[filt]; [src][filt]overlay=w'
15824
15825           The above command is the same as:
15826
15827                   ffplay input.avi -vf 'split[b], pad=iw*2[src], [b]deshake, [src]overlay=w'
15828
15829       •   Make a sliding overlay appearing from the left to the right top
15830           part of the screen starting since time 2:
15831
15832                   overlay=x='if(gte(t,2), -w+(t-2)*20, NAN)':y=0
15833
15834       •   Compose output by putting two input videos side to side:
15835
15836                   ffmpeg -i left.avi -i right.avi -filter_complex "
15837                   nullsrc=size=200x100 [background];
15838                   [0:v] setpts=PTS-STARTPTS, scale=100x100 [left];
15839                   [1:v] setpts=PTS-STARTPTS, scale=100x100 [right];
15840                   [background][left]       overlay=shortest=1       [background+left];
15841                   [background+left][right] overlay=shortest=1:x=100 [left+right]
15842                   "
15843
15844       •   Mask 10-20 seconds of a video by applying the delogo filter to a
15845           section
15846
15847                   ffmpeg -i test.avi -codec:v:0 wmv2 -ar 11025 -b:v 9000k
15848                   -vf '[in]split[split_main][split_delogo];[split_delogo]trim=start=360:end=371,delogo=0:0:640:480[delogoed];[split_main][delogoed]overlay=eof_action=pass[out]'
15849                   masked.avi
15850
15851       •   Chain several overlays in cascade:
15852
15853                   nullsrc=s=200x200 [bg];
15854                   testsrc=s=100x100, split=4 [in0][in1][in2][in3];
15855                   [in0] lutrgb=r=0, [bg]   overlay=0:0     [mid0];
15856                   [in1] lutrgb=g=0, [mid0] overlay=100:0   [mid1];
15857                   [in2] lutrgb=b=0, [mid1] overlay=0:100   [mid2];
15858                   [in3] null,       [mid2] overlay=100:100 [out0]
15859
15860   overlay_cuda
15861       Overlay one video on top of another.
15862
15863       This is the CUDA variant of the overlay filter.  It only accepts CUDA
15864       frames. The underlying input pixel formats have to match.
15865
15866       It takes two inputs and has one output. The first input is the "main"
15867       video on which the second input is overlaid.
15868
15869       It accepts the following parameters:
15870
15871       x
15872       y   Set expressions for the x and y coordinates of the overlaid video
15873           on the main video.
15874
15875           They can contain the following parameters:
15876
15877           main_w, W
15878           main_h, H
15879               The main input width and height.
15880
15881           overlay_w, w
15882           overlay_h, h
15883               The overlay input width and height.
15884
15885           x
15886           y   The computed values for x and y. They are evaluated for each
15887               new frame.
15888
15889           n   The ordinal index of the main input frame, starting from 0.
15890
15891           pos The byte offset position in the file of the main input frame,
15892               NAN if unknown.
15893
15894           t   The timestamp of the main input frame, expressed in seconds,
15895               NAN if unknown.
15896
15897           Default value is "0" for both expressions.
15898
15899       eval
15900           Set when the expressions for x and y are evaluated.
15901
15902           It accepts the following values:
15903
15904           init
15905               Evaluate expressions once during filter initialization or when
15906               a command is processed.
15907
15908           frame
15909               Evaluate expressions for each incoming frame
15910
15911           Default value is frame.
15912
15913       eof_action
15914           See framesync.
15915
15916       shortest
15917           See framesync.
15918
15919       repeatlast
15920           See framesync.
15921
15922       This filter also supports the framesync options.
15923
15924   owdenoise
15925       Apply Overcomplete Wavelet denoiser.
15926
15927       The filter accepts the following options:
15928
15929       depth
15930           Set depth.
15931
15932           Larger depth values will denoise lower frequency components more,
15933           but slow down filtering.
15934
15935           Must be an int in the range 8-16, default is 8.
15936
15937       luma_strength, ls
15938           Set luma strength.
15939
15940           Must be a double value in the range 0-1000, default is 1.0.
15941
15942       chroma_strength, cs
15943           Set chroma strength.
15944
15945           Must be a double value in the range 0-1000, default is 1.0.
15946
15947   pad
15948       Add paddings to the input image, and place the original input at the
15949       provided x, y coordinates.
15950
15951       It accepts the following parameters:
15952
15953       width, w
15954       height, h
15955           Specify an expression for the size of the output image with the
15956           paddings added. If the value for width or height is 0, the
15957           corresponding input size is used for the output.
15958
15959           The width expression can reference the value set by the height
15960           expression, and vice versa.
15961
15962           The default value of width and height is 0.
15963
15964       x
15965       y   Specify the offsets to place the input image at within the padded
15966           area, with respect to the top/left border of the output image.
15967
15968           The x expression can reference the value set by the y expression,
15969           and vice versa.
15970
15971           The default value of x and y is 0.
15972
15973           If x or y evaluate to a negative number, they'll be changed so the
15974           input image is centered on the padded area.
15975
15976       color
15977           Specify the color of the padded area. For the syntax of this
15978           option, check the "Color" section in the ffmpeg-utils manual.
15979
15980           The default value of color is "black".
15981
15982       eval
15983           Specify when to evaluate  width, height, x and y expression.
15984
15985           It accepts the following values:
15986
15987           init
15988               Only evaluate expressions once during the filter initialization
15989               or when a command is processed.
15990
15991           frame
15992               Evaluate expressions for each incoming frame.
15993
15994           Default value is init.
15995
15996       aspect
15997           Pad to aspect instead to a resolution.
15998
15999       The value for the width, height, x, and y options are expressions
16000       containing the following constants:
16001
16002       in_w
16003       in_h
16004           The input video width and height.
16005
16006       iw
16007       ih  These are the same as in_w and in_h.
16008
16009       out_w
16010       out_h
16011           The output width and height (the size of the padded area), as
16012           specified by the width and height expressions.
16013
16014       ow
16015       oh  These are the same as out_w and out_h.
16016
16017       x
16018       y   The x and y offsets as specified by the x and y expressions, or NAN
16019           if not yet specified.
16020
16021       a   same as iw / ih
16022
16023       sar input sample aspect ratio
16024
16025       dar input display aspect ratio, it is the same as (iw / ih) * sar
16026
16027       hsub
16028       vsub
16029           The horizontal and vertical chroma subsample values. For example
16030           for the pixel format "yuv422p" hsub is 2 and vsub is 1.
16031
16032       Examples
16033
16034       •   Add paddings with the color "violet" to the input video. The output
16035           video size is 640x480, and the top-left corner of the input video
16036           is placed at column 0, row 40
16037
16038                   pad=640:480:0:40:violet
16039
16040           The example above is equivalent to the following command:
16041
16042                   pad=width=640:height=480:x=0:y=40:color=violet
16043
16044       •   Pad the input to get an output with dimensions increased by 3/2,
16045           and put the input video at the center of the padded area:
16046
16047                   pad="3/2*iw:3/2*ih:(ow-iw)/2:(oh-ih)/2"
16048
16049       •   Pad the input to get a squared output with size equal to the
16050           maximum value between the input width and height, and put the input
16051           video at the center of the padded area:
16052
16053                   pad="max(iw\,ih):ow:(ow-iw)/2:(oh-ih)/2"
16054
16055       •   Pad the input to get a final w/h ratio of 16:9:
16056
16057                   pad="ih*16/9:ih:(ow-iw)/2:(oh-ih)/2"
16058
16059       •   In case of anamorphic video, in order to set the output display
16060           aspect correctly, it is necessary to use sar in the expression,
16061           according to the relation:
16062
16063                   (ih * X / ih) * sar = output_dar
16064                   X = output_dar / sar
16065
16066           Thus the previous example needs to be modified to:
16067
16068                   pad="ih*16/9/sar:ih:(ow-iw)/2:(oh-ih)/2"
16069
16070       •   Double the output size and put the input video in the bottom-right
16071           corner of the output padded area:
16072
16073                   pad="2*iw:2*ih:ow-iw:oh-ih"
16074
16075   palettegen
16076       Generate one palette for a whole video stream.
16077
16078       It accepts the following options:
16079
16080       max_colors
16081           Set the maximum number of colors to quantize in the palette.  Note:
16082           the palette will still contain 256 colors; the unused palette
16083           entries will be black.
16084
16085       reserve_transparent
16086           Create a palette of 255 colors maximum and reserve the last one for
16087           transparency. Reserving the transparency color is useful for GIF
16088           optimization.  If not set, the maximum of colors in the palette
16089           will be 256. You probably want to disable this option for a
16090           standalone image.  Set by default.
16091
16092       transparency_color
16093           Set the color that will be used as background for transparency.
16094
16095       stats_mode
16096           Set statistics mode.
16097
16098           It accepts the following values:
16099
16100           full
16101               Compute full frame histograms.
16102
16103           diff
16104               Compute histograms only for the part that differs from previous
16105               frame. This might be relevant to give more importance to the
16106               moving part of your input if the background is static.
16107
16108           single
16109               Compute new histogram for each frame.
16110
16111           Default value is full.
16112
16113       use_alpha
16114           Create a palette of colors with alpha components.  Setting this,
16115           will automatically disable 'reserve_transparent'.
16116
16117       The filter also exports the frame metadata "lavfi.color_quant_ratio"
16118       ("nb_color_in / nb_color_out") which you can use to evaluate the degree
16119       of color quantization of the palette. This information is also visible
16120       at info logging level.
16121
16122       Examples
16123
16124       •   Generate a representative palette of a given video using ffmpeg:
16125
16126                   ffmpeg -i input.mkv -vf palettegen palette.png
16127
16128   paletteuse
16129       Use a palette to downsample an input video stream.
16130
16131       The filter takes two inputs: one video stream and a palette. The
16132       palette must be a 256 pixels image.
16133
16134       It accepts the following options:
16135
16136       dither
16137           Select dithering mode. Available algorithms are:
16138
16139           bayer
16140               Ordered 8x8 bayer dithering (deterministic)
16141
16142           heckbert
16143               Dithering as defined by Paul Heckbert in 1982 (simple error
16144               diffusion).  Note: this dithering is sometimes considered
16145               "wrong" and is included as a reference.
16146
16147           floyd_steinberg
16148               Floyd and Steingberg dithering (error diffusion)
16149
16150           sierra2
16151               Frankie Sierra dithering v2 (error diffusion)
16152
16153           sierra2_4a
16154               Frankie Sierra dithering v2 "Lite" (error diffusion)
16155
16156           Default is sierra2_4a.
16157
16158       bayer_scale
16159           When bayer dithering is selected, this option defines the scale of
16160           the pattern (how much the crosshatch pattern is visible). A low
16161           value means more visible pattern for less banding, and higher value
16162           means less visible pattern at the cost of more banding.
16163
16164           The option must be an integer value in the range [0,5]. Default is
16165           2.
16166
16167       diff_mode
16168           If set, define the zone to process
16169
16170           rectangle
16171               Only the changing rectangle will be reprocessed. This is
16172               similar to GIF cropping/offsetting compression mechanism. This
16173               option can be useful for speed if only a part of the image is
16174               changing, and has use cases such as limiting the scope of the
16175               error diffusal dither to the rectangle that bounds the moving
16176               scene (it leads to more deterministic output if the scene
16177               doesn't change much, and as a result less moving noise and
16178               better GIF compression).
16179
16180           Default is none.
16181
16182       new Take new palette for each output frame.
16183
16184       alpha_threshold
16185           Sets the alpha threshold for transparency. Alpha values above this
16186           threshold will be treated as completely opaque, and values below
16187           this threshold will be treated as completely transparent.
16188
16189           The option must be an integer value in the range [0,255]. Default
16190           is 128.
16191
16192       use_alpha
16193           Apply the palette by taking alpha values into account. Only useful
16194           with palettes that are containing multiple colors with alpha
16195           components.  Setting this will automatically disable
16196           'alpha_treshold'.
16197
16198       Examples
16199
16200       •   Use a palette (generated for example with palettegen) to encode a
16201           GIF using ffmpeg:
16202
16203                   ffmpeg -i input.mkv -i palette.png -lavfi paletteuse output.gif
16204
16205   perspective
16206       Correct perspective of video not recorded perpendicular to the screen.
16207
16208       A description of the accepted parameters follows.
16209
16210       x0
16211       y0
16212       x1
16213       y1
16214       x2
16215       y2
16216       x3
16217       y3  Set coordinates expression for top left, top right, bottom left and
16218           bottom right corners.  Default values are "0:0:W:0:0:H:W:H" with
16219           which perspective will remain unchanged.  If the "sense" option is
16220           set to "source", then the specified points will be sent to the
16221           corners of the destination. If the "sense" option is set to
16222           "destination", then the corners of the source will be sent to the
16223           specified coordinates.
16224
16225           The expressions can use the following variables:
16226
16227           W
16228           H   the width and height of video frame.
16229
16230           in  Input frame count.
16231
16232           on  Output frame count.
16233
16234       interpolation
16235           Set interpolation for perspective correction.
16236
16237           It accepts the following values:
16238
16239           linear
16240           cubic
16241
16242           Default value is linear.
16243
16244       sense
16245           Set interpretation of coordinate options.
16246
16247           It accepts the following values:
16248
16249           0, source
16250               Send point in the source specified by the given coordinates to
16251               the corners of the destination.
16252
16253           1, destination
16254               Send the corners of the source to the point in the destination
16255               specified by the given coordinates.
16256
16257               Default value is source.
16258
16259       eval
16260           Set when the expressions for coordinates x0,y0,...x3,y3 are
16261           evaluated.
16262
16263           It accepts the following values:
16264
16265           init
16266               only evaluate expressions once during the filter initialization
16267               or when a command is processed
16268
16269           frame
16270               evaluate expressions for each incoming frame
16271
16272           Default value is init.
16273
16274   phase
16275       Delay interlaced video by one field time so that the field order
16276       changes.
16277
16278       The intended use is to fix PAL movies that have been captured with the
16279       opposite field order to the film-to-video transfer.
16280
16281       A description of the accepted parameters follows.
16282
16283       mode
16284           Set phase mode.
16285
16286           It accepts the following values:
16287
16288           t   Capture field order top-first, transfer bottom-first.  Filter
16289               will delay the bottom field.
16290
16291           b   Capture field order bottom-first, transfer top-first.  Filter
16292               will delay the top field.
16293
16294           p   Capture and transfer with the same field order. This mode only
16295               exists for the documentation of the other options to refer to,
16296               but if you actually select it, the filter will faithfully do
16297               nothing.
16298
16299           a   Capture field order determined automatically by field flags,
16300               transfer opposite.  Filter selects among t and b modes on a
16301               frame by frame basis using field flags. If no field information
16302               is available, then this works just like u.
16303
16304           u   Capture unknown or varying, transfer opposite.  Filter selects
16305               among t and b on a frame by frame basis by analyzing the images
16306               and selecting the alternative that produces best match between
16307               the fields.
16308
16309           T   Capture top-first, transfer unknown or varying.  Filter selects
16310               among t and p using image analysis.
16311
16312           B   Capture bottom-first, transfer unknown or varying.  Filter
16313               selects among b and p using image analysis.
16314
16315           A   Capture determined by field flags, transfer unknown or varying.
16316               Filter selects among t, b and p using field flags and image
16317               analysis. If no field information is available, then this works
16318               just like U. This is the default mode.
16319
16320           U   Both capture and transfer unknown or varying.  Filter selects
16321               among t, b and p using image analysis only.
16322
16323       Commands
16324
16325       This filter supports the all above options as commands.
16326
16327   photosensitivity
16328       Reduce various flashes in video, so to help users with epilepsy.
16329
16330       It accepts the following options:
16331
16332       frames, f
16333           Set how many frames to use when filtering. Default is 30.
16334
16335       threshold, t
16336           Set detection threshold factor. Default is 1.  Lower is stricter.
16337
16338       skip
16339           Set how many pixels to skip when sampling frames. Default is 1.
16340           Allowed range is from 1 to 1024.
16341
16342       bypass
16343           Leave frames unchanged. Default is disabled.
16344
16345   pixdesctest
16346       Pixel format descriptor test filter, mainly useful for internal
16347       testing. The output video should be equal to the input video.
16348
16349       For example:
16350
16351               format=monow, pixdesctest
16352
16353       can be used to test the monowhite pixel format descriptor definition.
16354
16355   pixelize
16356       Apply pixelization to video stream.
16357
16358       The filter accepts the following options:
16359
16360       width, w
16361       height, h
16362           Set block dimensions that will be used for pixelization.  Default
16363           value is 16.
16364
16365       mode, m
16366           Set the mode of pixelization used.
16367
16368           Possible values are:
16369
16370           avg
16371           min
16372           max
16373
16374           Default value is "avg".
16375
16376       planes, p
16377           Set what planes to filter. Default is to filter all planes.
16378
16379       Commands
16380
16381       This filter supports all options as commands.
16382
16383   pixscope
16384       Display sample values of color channels. Mainly useful for checking
16385       color and levels. Minimum supported resolution is 640x480.
16386
16387       The filters accept the following options:
16388
16389       x   Set scope X position, relative offset on X axis.
16390
16391       y   Set scope Y position, relative offset on Y axis.
16392
16393       w   Set scope width.
16394
16395       h   Set scope height.
16396
16397       o   Set window opacity. This window also holds statistics about pixel
16398           area.
16399
16400       wx  Set window X position, relative offset on X axis.
16401
16402       wy  Set window Y position, relative offset on Y axis.
16403
16404       Commands
16405
16406       This filter supports same commands as options.
16407
16408   pp
16409       Enable the specified chain of postprocessing subfilters using
16410       libpostproc. This library should be automatically selected with a GPL
16411       build ("--enable-gpl").  Subfilters must be separated by '/' and can be
16412       disabled by prepending a '-'.  Each subfilter and some options have a
16413       short and a long name that can be used interchangeably, i.e. dr/dering
16414       are the same.
16415
16416       The filters accept the following options:
16417
16418       subfilters
16419           Set postprocessing subfilters string.
16420
16421       All subfilters share common options to determine their scope:
16422
16423       a/autoq
16424           Honor the quality commands for this subfilter.
16425
16426       c/chrom
16427           Do chrominance filtering, too (default).
16428
16429       y/nochrom
16430           Do luminance filtering only (no chrominance).
16431
16432       n/noluma
16433           Do chrominance filtering only (no luminance).
16434
16435       These options can be appended after the subfilter name, separated by a
16436       '|'.
16437
16438       Available subfilters are:
16439
16440       hb/hdeblock[|difference[|flatness]]
16441           Horizontal deblocking filter
16442
16443           difference
16444               Difference factor where higher values mean more deblocking
16445               (default: 32).
16446
16447           flatness
16448               Flatness threshold where lower values mean more deblocking
16449               (default: 39).
16450
16451       vb/vdeblock[|difference[|flatness]]
16452           Vertical deblocking filter
16453
16454           difference
16455               Difference factor where higher values mean more deblocking
16456               (default: 32).
16457
16458           flatness
16459               Flatness threshold where lower values mean more deblocking
16460               (default: 39).
16461
16462       ha/hadeblock[|difference[|flatness]]
16463           Accurate horizontal deblocking filter
16464
16465           difference
16466               Difference factor where higher values mean more deblocking
16467               (default: 32).
16468
16469           flatness
16470               Flatness threshold where lower values mean more deblocking
16471               (default: 39).
16472
16473       va/vadeblock[|difference[|flatness]]
16474           Accurate vertical deblocking filter
16475
16476           difference
16477               Difference factor where higher values mean more deblocking
16478               (default: 32).
16479
16480           flatness
16481               Flatness threshold where lower values mean more deblocking
16482               (default: 39).
16483
16484       The horizontal and vertical deblocking filters share the difference and
16485       flatness values so you cannot set different horizontal and vertical
16486       thresholds.
16487
16488       h1/x1hdeblock
16489           Experimental horizontal deblocking filter
16490
16491       v1/x1vdeblock
16492           Experimental vertical deblocking filter
16493
16494       dr/dering
16495           Deringing filter
16496
16497       tn/tmpnoise[|threshold1[|threshold2[|threshold3]]], temporal noise
16498       reducer
16499           threshold1
16500               larger -> stronger filtering
16501
16502           threshold2
16503               larger -> stronger filtering
16504
16505           threshold3
16506               larger -> stronger filtering
16507
16508       al/autolevels[:f/fullyrange], automatic brightness / contrast
16509       correction
16510           f/fullyrange
16511               Stretch luminance to "0-255".
16512
16513       lb/linblenddeint
16514           Linear blend deinterlacing filter that deinterlaces the given block
16515           by filtering all lines with a "(1 2 1)" filter.
16516
16517       li/linipoldeint
16518           Linear interpolating deinterlacing filter that deinterlaces the
16519           given block by linearly interpolating every second line.
16520
16521       ci/cubicipoldeint
16522           Cubic interpolating deinterlacing filter deinterlaces the given
16523           block by cubically interpolating every second line.
16524
16525       md/mediandeint
16526           Median deinterlacing filter that deinterlaces the given block by
16527           applying a median filter to every second line.
16528
16529       fd/ffmpegdeint
16530           FFmpeg deinterlacing filter that deinterlaces the given block by
16531           filtering every second line with a "(-1 4 2 4 -1)" filter.
16532
16533       l5/lowpass5
16534           Vertically applied FIR lowpass deinterlacing filter that
16535           deinterlaces the given block by filtering all lines with a "(-1 2 6
16536           2 -1)" filter.
16537
16538       fq/forceQuant[|quantizer]
16539           Overrides the quantizer table from the input with the constant
16540           quantizer you specify.
16541
16542           quantizer
16543               Quantizer to use
16544
16545       de/default
16546           Default pp filter combination ("hb|a,vb|a,dr|a")
16547
16548       fa/fast
16549           Fast pp filter combination ("h1|a,v1|a,dr|a")
16550
16551       ac  High quality pp filter combination ("ha|a|128|7,va|a,dr|a")
16552
16553       Examples
16554
16555       •   Apply horizontal and vertical deblocking, deringing and automatic
16556           brightness/contrast:
16557
16558                   pp=hb/vb/dr/al
16559
16560       •   Apply default filters without brightness/contrast correction:
16561
16562                   pp=de/-al
16563
16564       •   Apply default filters and temporal denoiser:
16565
16566                   pp=default/tmpnoise|1|2|3
16567
16568       •   Apply deblocking on luminance only, and switch vertical deblocking
16569           on or off automatically depending on available CPU time:
16570
16571                   pp=hb|y/vb|a
16572
16573   pp7
16574       Apply Postprocessing filter 7. It is variant of the spp filter, similar
16575       to spp = 6 with 7 point DCT, where only the center sample is used after
16576       IDCT.
16577
16578       The filter accepts the following options:
16579
16580       qp  Force a constant quantization parameter. It accepts an integer in
16581           range 0 to 63. If not set, the filter will use the QP from the
16582           video stream (if available).
16583
16584       mode
16585           Set thresholding mode. Available modes are:
16586
16587           hard
16588               Set hard thresholding.
16589
16590           soft
16591               Set soft thresholding (better de-ringing effect, but likely
16592               blurrier).
16593
16594           medium
16595               Set medium thresholding (good results, default).
16596
16597   premultiply
16598       Apply alpha premultiply effect to input video stream using first plane
16599       of second stream as alpha.
16600
16601       Both streams must have same dimensions and same pixel format.
16602
16603       The filter accepts the following option:
16604
16605       planes
16606           Set which planes will be processed, unprocessed planes will be
16607           copied.  By default value 0xf, all planes will be processed.
16608
16609       inplace
16610           Do not require 2nd input for processing, instead use alpha plane
16611           from input stream.
16612
16613   prewitt
16614       Apply prewitt operator to input video stream.
16615
16616       The filter accepts the following option:
16617
16618       planes
16619           Set which planes will be processed, unprocessed planes will be
16620           copied.  By default value 0xf, all planes will be processed.
16621
16622       scale
16623           Set value which will be multiplied with filtered result.
16624
16625       delta
16626           Set value which will be added to filtered result.
16627
16628       Commands
16629
16630       This filter supports the all above options as commands.
16631
16632   pseudocolor
16633       Alter frame colors in video with pseudocolors.
16634
16635       This filter accepts the following options:
16636
16637       c0  set pixel first component expression
16638
16639       c1  set pixel second component expression
16640
16641       c2  set pixel third component expression
16642
16643       c3  set pixel fourth component expression, corresponds to the alpha
16644           component
16645
16646       index, i
16647           set component to use as base for altering colors
16648
16649       preset, p
16650           Pick one of built-in LUTs. By default is set to none.
16651
16652           Available LUTs:
16653
16654           magma
16655           inferno
16656           plasma
16657           viridis
16658           turbo
16659           cividis
16660           range1
16661           range2
16662           shadows
16663           highlights
16664           solar
16665           nominal
16666           preferred
16667           total
16668       opacity
16669           Set opacity of output colors. Allowed range is from 0 to 1.
16670           Default value is set to 1.
16671
16672       Each of the expression options specifies the expression to use for
16673       computing the lookup table for the corresponding pixel component
16674       values.
16675
16676       The expressions can contain the following constants and functions:
16677
16678       w
16679       h   The input width and height.
16680
16681       val The input value for the pixel component.
16682
16683       ymin, umin, vmin, amin
16684           The minimum allowed component value.
16685
16686       ymax, umax, vmax, amax
16687           The maximum allowed component value.
16688
16689       All expressions default to "val".
16690
16691       Commands
16692
16693       This filter supports the all above options as commands.
16694
16695       Examples
16696
16697       •   Change too high luma values to gradient:
16698
16699                   pseudocolor="'if(between(val,ymax,amax),lerp(ymin,ymax,(val-ymax)/(amax-ymax)),-1):if(between(val,ymax,amax),lerp(umax,umin,(val-ymax)/(amax-ymax)),-1):if(between(val,ymax,amax),lerp(vmin,vmax,(val-ymax)/(amax-ymax)),-1):-1'"
16700
16701   psnr
16702       Obtain the average, maximum and minimum PSNR (Peak Signal to Noise
16703       Ratio) between two input videos.
16704
16705       This filter takes in input two input videos, the first input is
16706       considered the "main" source and is passed unchanged to the output. The
16707       second input is used as a "reference" video for computing the PSNR.
16708
16709       Both video inputs must have the same resolution and pixel format for
16710       this filter to work correctly. Also it assumes that both inputs have
16711       the same number of frames, which are compared one by one.
16712
16713       The obtained average PSNR is printed through the logging system.
16714
16715       The filter stores the accumulated MSE (mean squared error) of each
16716       frame, and at the end of the processing it is averaged across all
16717       frames equally, and the following formula is applied to obtain the
16718       PSNR:
16719
16720               PSNR = 10*log10(MAX^2/MSE)
16721
16722       Where MAX is the average of the maximum values of each component of the
16723       image.
16724
16725       The description of the accepted parameters follows.
16726
16727       stats_file, f
16728           If specified the filter will use the named file to save the PSNR of
16729           each individual frame. When filename equals "-" the data is sent to
16730           standard output.
16731
16732       stats_version
16733           Specifies which version of the stats file format to use. Details of
16734           each format are written below.  Default value is 1.
16735
16736       stats_add_max
16737           Determines whether the max value is output to the stats log.
16738           Default value is 0.  Requires stats_version >= 2. If this is set
16739           and stats_version < 2, the filter will return an error.
16740
16741       This filter also supports the framesync options.
16742
16743       The file printed if stats_file is selected, contains a sequence of
16744       key/value pairs of the form key:value for each compared couple of
16745       frames.
16746
16747       If a stats_version greater than 1 is specified, a header line precedes
16748       the list of per-frame-pair stats, with key value pairs following the
16749       frame format with the following parameters:
16750
16751       psnr_log_version
16752           The version of the log file format. Will match stats_version.
16753
16754       fields
16755           A comma separated list of the per-frame-pair parameters included in
16756           the log.
16757
16758       A description of each shown per-frame-pair parameter follows:
16759
16760       n   sequential number of the input frame, starting from 1
16761
16762       mse_avg
16763           Mean Square Error pixel-by-pixel average difference of the compared
16764           frames, averaged over all the image components.
16765
16766       mse_y, mse_u, mse_v, mse_r, mse_g, mse_b, mse_a
16767           Mean Square Error pixel-by-pixel average difference of the compared
16768           frames for the component specified by the suffix.
16769
16770       psnr_y, psnr_u, psnr_v, psnr_r, psnr_g, psnr_b, psnr_a
16771           Peak Signal to Noise ratio of the compared frames for the component
16772           specified by the suffix.
16773
16774       max_avg, max_y, max_u, max_v
16775           Maximum allowed value for each channel, and average over all
16776           channels.
16777
16778       Examples
16779
16780       •   For example:
16781
16782                   movie=ref_movie.mpg, setpts=PTS-STARTPTS [main];
16783                   [main][ref] psnr="stats_file=stats.log" [out]
16784
16785           On this example the input file being processed is compared with the
16786           reference file ref_movie.mpg. The PSNR of each individual frame is
16787           stored in stats.log.
16788
16789       •   Another example with different containers:
16790
16791                   ffmpeg -i main.mpg -i ref.mkv -lavfi  "[0:v]settb=AVTB,setpts=PTS-STARTPTS[main];[1:v]settb=AVTB,setpts=PTS-STARTPTS[ref];[main][ref]psnr" -f null -
16792
16793   pullup
16794       Pulldown reversal (inverse telecine) filter, capable of handling mixed
16795       hard-telecine, 24000/1001 fps progressive, and 30000/1001 fps
16796       progressive content.
16797
16798       The pullup filter is designed to take advantage of future context in
16799       making its decisions. This filter is stateless in the sense that it
16800       does not lock onto a pattern to follow, but it instead looks forward to
16801       the following fields in order to identify matches and rebuild
16802       progressive frames.
16803
16804       To produce content with an even framerate, insert the fps filter after
16805       pullup, use "fps=24000/1001" if the input frame rate is 29.97fps,
16806       "fps=24" for 30fps and the (rare) telecined 25fps input.
16807
16808       The filter accepts the following options:
16809
16810       jl
16811       jr
16812       jt
16813       jb  These options set the amount of "junk" to ignore at the left,
16814           right, top, and bottom of the image, respectively. Left and right
16815           are in units of 8 pixels, while top and bottom are in units of 2
16816           lines.  The default is 8 pixels on each side.
16817
16818       sb  Set the strict breaks. Setting this option to 1 will reduce the
16819           chances of filter generating an occasional mismatched frame, but it
16820           may also cause an excessive number of frames to be dropped during
16821           high motion sequences.  Conversely, setting it to -1 will make
16822           filter match fields more easily.  This may help processing of video
16823           where there is slight blurring between the fields, but may also
16824           cause there to be interlaced frames in the output.  Default value
16825           is 0.
16826
16827       mp  Set the metric plane to use. It accepts the following values:
16828
16829           l   Use luma plane.
16830
16831           u   Use chroma blue plane.
16832
16833           v   Use chroma red plane.
16834
16835           This option may be set to use chroma plane instead of the default
16836           luma plane for doing filter's computations. This may improve
16837           accuracy on very clean source material, but more likely will
16838           decrease accuracy, especially if there is chroma noise (rainbow
16839           effect) or any grayscale video.  The main purpose of setting mp to
16840           a chroma plane is to reduce CPU load and make pullup usable in
16841           realtime on slow machines.
16842
16843       For best results (without duplicated frames in the output file) it is
16844       necessary to change the output frame rate. For example, to inverse
16845       telecine NTSC input:
16846
16847               ffmpeg -i input -vf pullup -r 24000/1001 ...
16848
16849   qp
16850       Change video quantization parameters (QP).
16851
16852       The filter accepts the following option:
16853
16854       qp  Set expression for quantization parameter.
16855
16856       The expression is evaluated through the eval API and can contain, among
16857       others, the following constants:
16858
16859       known
16860           1 if index is not 129, 0 otherwise.
16861
16862       qp  Sequential index starting from -129 to 128.
16863
16864       Examples
16865
16866       •   Some equation like:
16867
16868                   qp=2+2*sin(PI*qp)
16869
16870   random
16871       Flush video frames from internal cache of frames into a random order.
16872       No frame is discarded.  Inspired by frei0r nervous filter.
16873
16874       frames
16875           Set size in number of frames of internal cache, in range from 2 to
16876           512. Default is 30.
16877
16878       seed
16879           Set seed for random number generator, must be an integer included
16880           between 0 and "UINT32_MAX". If not specified, or if explicitly set
16881           to less than 0, the filter will try to use a good random seed on a
16882           best effort basis.
16883
16884   readeia608
16885       Read closed captioning (EIA-608) information from the top lines of a
16886       video frame.
16887
16888       This filter adds frame metadata for "lavfi.readeia608.X.cc" and
16889       "lavfi.readeia608.X.line", where "X" is the number of the identified
16890       line with EIA-608 data (starting from 0). A description of each
16891       metadata value follows:
16892
16893       lavfi.readeia608.X.cc
16894           The two bytes stored as EIA-608 data (printed in hexadecimal).
16895
16896       lavfi.readeia608.X.line
16897           The number of the line on which the EIA-608 data was identified and
16898           read.
16899
16900       This filter accepts the following options:
16901
16902       scan_min
16903           Set the line to start scanning for EIA-608 data. Default is 0.
16904
16905       scan_max
16906           Set the line to end scanning for EIA-608 data. Default is 29.
16907
16908       spw Set the ratio of width reserved for sync code detection.  Default
16909           is 0.27. Allowed range is "[0.1 - 0.7]".
16910
16911       chp Enable checking the parity bit. In the event of a parity error, the
16912           filter will output 0x00 for that character. Default is false.
16913
16914       lp  Lowpass lines prior to further processing. Default is enabled.
16915
16916       Commands
16917
16918       This filter supports the all above options as commands.
16919
16920       Examples
16921
16922       •   Output a csv with presentation time and the first two lines of
16923           identified EIA-608 captioning data.
16924
16925                   ffprobe -f lavfi -i movie=captioned_video.mov,readeia608 -show_entries frame=pts_time:frame_tags=lavfi.readeia608.0.cc,lavfi.readeia608.1.cc -of csv
16926
16927   readvitc
16928       Read vertical interval timecode (VITC) information from the top lines
16929       of a video frame.
16930
16931       The filter adds frame metadata key "lavfi.readvitc.tc_str" with the
16932       timecode value, if a valid timecode has been detected. Further metadata
16933       key "lavfi.readvitc.found" is set to 0/1 depending on whether timecode
16934       data has been found or not.
16935
16936       This filter accepts the following options:
16937
16938       scan_max
16939           Set the maximum number of lines to scan for VITC data. If the value
16940           is set to "-1" the full video frame is scanned. Default is 45.
16941
16942       thr_b
16943           Set the luma threshold for black. Accepts float numbers in the
16944           range [0.0,1.0], default value is 0.2. The value must be equal or
16945           less than "thr_w".
16946
16947       thr_w
16948           Set the luma threshold for white. Accepts float numbers in the
16949           range [0.0,1.0], default value is 0.6. The value must be equal or
16950           greater than "thr_b".
16951
16952       Examples
16953
16954       •   Detect and draw VITC data onto the video frame; if no valid VITC is
16955           detected, draw "--:--:--:--" as a placeholder:
16956
16957                   ffmpeg -i input.avi -filter:v 'readvitc,drawtext=fontfile=FreeMono.ttf:text=%{metadata\\:lavfi.readvitc.tc_str\\:--\\\\\\:--\\\\\\:--\\\\\\:--}:x=(w-tw)/2:y=400-ascent'
16958
16959   remap
16960       Remap pixels using 2nd: Xmap and 3rd: Ymap input video stream.
16961
16962       Destination pixel at position (X, Y) will be picked from source (x, y)
16963       position where x = Xmap(X, Y) and y = Ymap(X, Y). If mapping values are
16964       out of range, zero value for pixel will be used for destination pixel.
16965
16966       Xmap and Ymap input video streams must be of same dimensions. Output
16967       video stream will have Xmap/Ymap video stream dimensions.  Xmap and
16968       Ymap input video streams are 16bit depth, single channel.
16969
16970       format
16971           Specify pixel format of output from this filter. Can be "color" or
16972           "gray".  Default is "color".
16973
16974       fill
16975           Specify the color of the unmapped pixels. For the syntax of this
16976           option, check the "Color" section in the ffmpeg-utils manual.
16977           Default color is "black".
16978
16979   removegrain
16980       The removegrain filter is a spatial denoiser for progressive video.
16981
16982       m0  Set mode for the first plane.
16983
16984       m1  Set mode for the second plane.
16985
16986       m2  Set mode for the third plane.
16987
16988       m3  Set mode for the fourth plane.
16989
16990       Range of mode is from 0 to 24. Description of each mode follows:
16991
16992       0   Leave input plane unchanged. Default.
16993
16994       1   Clips the pixel with the minimum and maximum of the 8 neighbour
16995           pixels.
16996
16997       2   Clips the pixel with the second minimum and maximum of the 8
16998           neighbour pixels.
16999
17000       3   Clips the pixel with the third minimum and maximum of the 8
17001           neighbour pixels.
17002
17003       4   Clips the pixel with the fourth minimum and maximum of the 8
17004           neighbour pixels.  This is equivalent to a median filter.
17005
17006       5   Line-sensitive clipping giving the minimal change.
17007
17008       6   Line-sensitive clipping, intermediate.
17009
17010       7   Line-sensitive clipping, intermediate.
17011
17012       8   Line-sensitive clipping, intermediate.
17013
17014       9   Line-sensitive clipping on a line where the neighbours pixels are
17015           the closest.
17016
17017       10  Replaces the target pixel with the closest neighbour.
17018
17019       11  [1 2 1] horizontal and vertical kernel blur.
17020
17021       12  Same as mode 11.
17022
17023       13  Bob mode, interpolates top field from the line where the neighbours
17024           pixels are the closest.
17025
17026       14  Bob mode, interpolates bottom field from the line where the
17027           neighbours pixels are the closest.
17028
17029       15  Bob mode, interpolates top field. Same as 13 but with a more
17030           complicated interpolation formula.
17031
17032       16  Bob mode, interpolates bottom field. Same as 14 but with a more
17033           complicated interpolation formula.
17034
17035       17  Clips the pixel with the minimum and maximum of respectively the
17036           maximum and minimum of each pair of opposite neighbour pixels.
17037
17038       18  Line-sensitive clipping using opposite neighbours whose greatest
17039           distance from the current pixel is minimal.
17040
17041       19  Replaces the pixel with the average of its 8 neighbours.
17042
17043       20  Averages the 9 pixels ([1 1 1] horizontal and vertical blur).
17044
17045       21  Clips pixels using the averages of opposite neighbour.
17046
17047       22  Same as mode 21 but simpler and faster.
17048
17049       23  Small edge and halo removal, but reputed useless.
17050
17051       24  Similar as 23.
17052
17053   removelogo
17054       Suppress a TV station logo, using an image file to determine which
17055       pixels comprise the logo. It works by filling in the pixels that
17056       comprise the logo with neighboring pixels.
17057
17058       The filter accepts the following options:
17059
17060       filename, f
17061           Set the filter bitmap file, which can be any image format supported
17062           by libavformat. The width and height of the image file must match
17063           those of the video stream being processed.
17064
17065       Pixels in the provided bitmap image with a value of zero are not
17066       considered part of the logo, non-zero pixels are considered part of the
17067       logo. If you use white (255) for the logo and black (0) for the rest,
17068       you will be safe. For making the filter bitmap, it is recommended to
17069       take a screen capture of a black frame with the logo visible, and then
17070       using a threshold filter followed by the erode filter once or twice.
17071
17072       If needed, little splotches can be fixed manually. Remember that if
17073       logo pixels are not covered, the filter quality will be much reduced.
17074       Marking too many pixels as part of the logo does not hurt as much, but
17075       it will increase the amount of blurring needed to cover over the image
17076       and will destroy more information than necessary, and extra pixels will
17077       slow things down on a large logo.
17078
17079   repeatfields
17080       This filter uses the repeat_field flag from the Video ES headers and
17081       hard repeats fields based on its value.
17082
17083   reverse
17084       Reverse a video clip.
17085
17086       Warning: This filter requires memory to buffer the entire clip, so
17087       trimming is suggested.
17088
17089       Examples
17090
17091       •   Take the first 5 seconds of a clip, and reverse it.
17092
17093                   trim=end=5,reverse
17094
17095   rgbashift
17096       Shift R/G/B/A pixels horizontally and/or vertically.
17097
17098       The filter accepts the following options:
17099
17100       rh  Set amount to shift red horizontally.
17101
17102       rv  Set amount to shift red vertically.
17103
17104       gh  Set amount to shift green horizontally.
17105
17106       gv  Set amount to shift green vertically.
17107
17108       bh  Set amount to shift blue horizontally.
17109
17110       bv  Set amount to shift blue vertically.
17111
17112       ah  Set amount to shift alpha horizontally.
17113
17114       av  Set amount to shift alpha vertically.
17115
17116       edge
17117           Set edge mode, can be smear, default, or warp.
17118
17119       Commands
17120
17121       This filter supports the all above options as commands.
17122
17123   roberts
17124       Apply roberts cross operator to input video stream.
17125
17126       The filter accepts the following option:
17127
17128       planes
17129           Set which planes will be processed, unprocessed planes will be
17130           copied.  By default value 0xf, all planes will be processed.
17131
17132       scale
17133           Set value which will be multiplied with filtered result.
17134
17135       delta
17136           Set value which will be added to filtered result.
17137
17138       Commands
17139
17140       This filter supports the all above options as commands.
17141
17142   rotate
17143       Rotate video by an arbitrary angle expressed in radians.
17144
17145       The filter accepts the following options:
17146
17147       A description of the optional parameters follows.
17148
17149       angle, a
17150           Set an expression for the angle by which to rotate the input video
17151           clockwise, expressed as a number of radians. A negative value will
17152           result in a counter-clockwise rotation. By default it is set to
17153           "0".
17154
17155           This expression is evaluated for each frame.
17156
17157       out_w, ow
17158           Set the output width expression, default value is "iw".  This
17159           expression is evaluated just once during configuration.
17160
17161       out_h, oh
17162           Set the output height expression, default value is "ih".  This
17163           expression is evaluated just once during configuration.
17164
17165       bilinear
17166           Enable bilinear interpolation if set to 1, a value of 0 disables
17167           it. Default value is 1.
17168
17169       fillcolor, c
17170           Set the color used to fill the output area not covered by the
17171           rotated image. For the general syntax of this option, check the
17172           "Color" section in the ffmpeg-utils manual.  If the special value
17173           "none" is selected then no background is printed (useful for
17174           example if the background is never shown).
17175
17176           Default value is "black".
17177
17178       The expressions for the angle and the output size can contain the
17179       following constants and functions:
17180
17181       n   sequential number of the input frame, starting from 0. It is always
17182           NAN before the first frame is filtered.
17183
17184       t   time in seconds of the input frame, it is set to 0 when the filter
17185           is configured. It is always NAN before the first frame is filtered.
17186
17187       hsub
17188       vsub
17189           horizontal and vertical chroma subsample values. For example for
17190           the pixel format "yuv422p" hsub is 2 and vsub is 1.
17191
17192       in_w, iw
17193       in_h, ih
17194           the input video width and height
17195
17196       out_w, ow
17197       out_h, oh
17198           the output width and height, that is the size of the padded area as
17199           specified by the width and height expressions
17200
17201       rotw(a)
17202       roth(a)
17203           the minimal width/height required for completely containing the
17204           input video rotated by a radians.
17205
17206           These are only available when computing the out_w and out_h
17207           expressions.
17208
17209       Examples
17210
17211       •   Rotate the input by PI/6 radians clockwise:
17212
17213                   rotate=PI/6
17214
17215       •   Rotate the input by PI/6 radians counter-clockwise:
17216
17217                   rotate=-PI/6
17218
17219       •   Rotate the input by 45 degrees clockwise:
17220
17221                   rotate=45*PI/180
17222
17223       •   Apply a constant rotation with period T, starting from an angle of
17224           PI/3:
17225
17226                   rotate=PI/3+2*PI*t/T
17227
17228       •   Make the input video rotation oscillating with a period of T
17229           seconds and an amplitude of A radians:
17230
17231                   rotate=A*sin(2*PI/T*t)
17232
17233       •   Rotate the video, output size is chosen so that the whole rotating
17234           input video is always completely contained in the output:
17235
17236                   rotate='2*PI*t:ow=hypot(iw,ih):oh=ow'
17237
17238       •   Rotate the video, reduce the output size so that no background is
17239           ever shown:
17240
17241                   rotate=2*PI*t:ow='min(iw,ih)/sqrt(2)':oh=ow:c=none
17242
17243       Commands
17244
17245       The filter supports the following commands:
17246
17247       a, angle
17248           Set the angle expression.  The command accepts the same syntax of
17249           the corresponding option.
17250
17251           If the specified expression is not valid, it is kept at its current
17252           value.
17253
17254   sab
17255       Apply Shape Adaptive Blur.
17256
17257       The filter accepts the following options:
17258
17259       luma_radius, lr
17260           Set luma blur filter strength, must be a value in range 0.1-4.0,
17261           default value is 1.0. A greater value will result in a more blurred
17262           image, and in slower processing.
17263
17264       luma_pre_filter_radius, lpfr
17265           Set luma pre-filter radius, must be a value in the 0.1-2.0 range,
17266           default value is 1.0.
17267
17268       luma_strength, ls
17269           Set luma maximum difference between pixels to still be considered,
17270           must be a value in the 0.1-100.0 range, default value is 1.0.
17271
17272       chroma_radius, cr
17273           Set chroma blur filter strength, must be a value in range -0.9-4.0.
17274           A greater value will result in a more blurred image, and in slower
17275           processing.
17276
17277       chroma_pre_filter_radius, cpfr
17278           Set chroma pre-filter radius, must be a value in the -0.9-2.0
17279           range.
17280
17281       chroma_strength, cs
17282           Set chroma maximum difference between pixels to still be
17283           considered, must be a value in the -0.9-100.0 range.
17284
17285       Each chroma option value, if not explicitly specified, is set to the
17286       corresponding luma option value.
17287
17288   scale
17289       Scale (resize) the input video, using the libswscale library.
17290
17291       The scale filter forces the output display aspect ratio to be the same
17292       of the input, by changing the output sample aspect ratio.
17293
17294       If the input image format is different from the format requested by the
17295       next filter, the scale filter will convert the input to the requested
17296       format.
17297
17298       Options
17299
17300       The filter accepts the following options, or any of the options
17301       supported by the libswscale scaler.
17302
17303       See the ffmpeg-scaler manual for the complete list of scaler options.
17304
17305       width, w
17306       height, h
17307           Set the output video dimension expression. Default value is the
17308           input dimension.
17309
17310           If the width or w value is 0, the input width is used for the
17311           output. If the height or h value is 0, the input height is used for
17312           the output.
17313
17314           If one and only one of the values is -n with n >= 1, the scale
17315           filter will use a value that maintains the aspect ratio of the
17316           input image, calculated from the other specified dimension. After
17317           that it will, however, make sure that the calculated dimension is
17318           divisible by n and adjust the value if necessary.
17319
17320           If both values are -n with n >= 1, the behavior will be identical
17321           to both values being set to 0 as previously detailed.
17322
17323           See below for the list of accepted constants for use in the
17324           dimension expression.
17325
17326       eval
17327           Specify when to evaluate width and height expression. It accepts
17328           the following values:
17329
17330           init
17331               Only evaluate expressions once during the filter initialization
17332               or when a command is processed.
17333
17334           frame
17335               Evaluate expressions for each incoming frame.
17336
17337           Default value is init.
17338
17339       interl
17340           Set the interlacing mode. It accepts the following values:
17341
17342           1   Force interlaced aware scaling.
17343
17344           0   Do not apply interlaced scaling.
17345
17346           -1  Select interlaced aware scaling depending on whether the source
17347               frames are flagged as interlaced or not.
17348
17349           Default value is 0.
17350
17351       flags
17352           Set libswscale scaling flags. See the ffmpeg-scaler manual for the
17353           complete list of values. If not explicitly specified the filter
17354           applies the default flags.
17355
17356       param0, param1
17357           Set libswscale input parameters for scaling algorithms that need
17358           them. See the ffmpeg-scaler manual for the complete documentation.
17359           If not explicitly specified the filter applies empty parameters.
17360
17361       size, s
17362           Set the video size. For the syntax of this option, check the "Video
17363           size" section in the ffmpeg-utils manual.
17364
17365       in_color_matrix
17366       out_color_matrix
17367           Set in/output YCbCr color space type.
17368
17369           This allows the autodetected value to be overridden as well as
17370           allows forcing a specific value used for the output and encoder.
17371
17372           If not specified, the color space type depends on the pixel format.
17373
17374           Possible values:
17375
17376           auto
17377               Choose automatically.
17378
17379           bt709
17380               Format conforming to International Telecommunication Union
17381               (ITU) Recommendation BT.709.
17382
17383           fcc Set color space conforming to the United States Federal
17384               Communications Commission (FCC) Code of Federal Regulations
17385               (CFR) Title 47 (2003) 73.682 (a).
17386
17387           bt601
17388           bt470
17389           smpte170m
17390               Set color space conforming to:
17391
17392               •   ITU Radiocommunication Sector (ITU-R) Recommendation BT.601
17393
17394               •   ITU-R Rec. BT.470-6 (1998) Systems B, B1, and G
17395
17396               •   Society of Motion Picture and Television Engineers (SMPTE)
17397                   ST 170:2004
17398
17399           smpte240m
17400               Set color space conforming to SMPTE ST 240:1999.
17401
17402           bt2020
17403               Set color space conforming to ITU-R BT.2020 non-constant
17404               luminance system.
17405
17406       in_range
17407       out_range
17408           Set in/output YCbCr sample range.
17409
17410           This allows the autodetected value to be overridden as well as
17411           allows forcing a specific value used for the output and encoder. If
17412           not specified, the range depends on the pixel format. Possible
17413           values:
17414
17415           auto/unknown
17416               Choose automatically.
17417
17418           jpeg/full/pc
17419               Set full range (0-255 in case of 8-bit luma).
17420
17421           mpeg/limited/tv
17422               Set "MPEG" range (16-235 in case of 8-bit luma).
17423
17424       force_original_aspect_ratio
17425           Enable decreasing or increasing output video width or height if
17426           necessary to keep the original aspect ratio. Possible values:
17427
17428           disable
17429               Scale the video as specified and disable this feature.
17430
17431           decrease
17432               The output video dimensions will automatically be decreased if
17433               needed.
17434
17435           increase
17436               The output video dimensions will automatically be increased if
17437               needed.
17438
17439           One useful instance of this option is that when you know a specific
17440           device's maximum allowed resolution, you can use this to limit the
17441           output video to that, while retaining the aspect ratio. For
17442           example, device A allows 1280x720 playback, and your video is
17443           1920x800. Using this option (set it to decrease) and specifying
17444           1280x720 to the command line makes the output 1280x533.
17445
17446           Please note that this is a different thing than specifying -1 for w
17447           or h, you still need to specify the output resolution for this
17448           option to work.
17449
17450       force_divisible_by
17451           Ensures that both the output dimensions, width and height, are
17452           divisible by the given integer when used together with
17453           force_original_aspect_ratio. This works similar to using "-n" in
17454           the w and h options.
17455
17456           This option respects the value set for force_original_aspect_ratio,
17457           increasing or decreasing the resolution accordingly. The video's
17458           aspect ratio may be slightly modified.
17459
17460           This option can be handy if you need to have a video fit within or
17461           exceed a defined resolution using force_original_aspect_ratio but
17462           also have encoder restrictions on width or height divisibility.
17463
17464       The values of the w and h options are expressions containing the
17465       following constants:
17466
17467       in_w
17468       in_h
17469           The input width and height
17470
17471       iw
17472       ih  These are the same as in_w and in_h.
17473
17474       out_w
17475       out_h
17476           The output (scaled) width and height
17477
17478       ow
17479       oh  These are the same as out_w and out_h
17480
17481       a   The same as iw / ih
17482
17483       sar input sample aspect ratio
17484
17485       dar The input display aspect ratio. Calculated from "(iw / ih) * sar".
17486
17487       hsub
17488       vsub
17489           horizontal and vertical input chroma subsample values. For example
17490           for the pixel format "yuv422p" hsub is 2 and vsub is 1.
17491
17492       ohsub
17493       ovsub
17494           horizontal and vertical output chroma subsample values. For example
17495           for the pixel format "yuv422p" hsub is 2 and vsub is 1.
17496
17497       n   The (sequential) number of the input frame, starting from 0.  Only
17498           available with "eval=frame".
17499
17500       t   The presentation timestamp of the input frame, expressed as a
17501           number of seconds. Only available with "eval=frame".
17502
17503       pos The position (byte offset) of the frame in the input stream, or NaN
17504           if this information is unavailable and/or meaningless (for example
17505           in case of synthetic video).  Only available with "eval=frame".
17506
17507       Examples
17508
17509       •   Scale the input video to a size of 200x100
17510
17511                   scale=w=200:h=100
17512
17513           This is equivalent to:
17514
17515                   scale=200:100
17516
17517           or:
17518
17519                   scale=200x100
17520
17521       •   Specify a size abbreviation for the output size:
17522
17523                   scale=qcif
17524
17525           which can also be written as:
17526
17527                   scale=size=qcif
17528
17529       •   Scale the input to 2x:
17530
17531                   scale=w=2*iw:h=2*ih
17532
17533       •   The above is the same as:
17534
17535                   scale=2*in_w:2*in_h
17536
17537       •   Scale the input to 2x with forced interlaced scaling:
17538
17539                   scale=2*iw:2*ih:interl=1
17540
17541       •   Scale the input to half size:
17542
17543                   scale=w=iw/2:h=ih/2
17544
17545       •   Increase the width, and set the height to the same size:
17546
17547                   scale=3/2*iw:ow
17548
17549       •   Seek Greek harmony:
17550
17551                   scale=iw:1/PHI*iw
17552                   scale=ih*PHI:ih
17553
17554       •   Increase the height, and set the width to 3/2 of the height:
17555
17556                   scale=w=3/2*oh:h=3/5*ih
17557
17558       •   Increase the size, making the size a multiple of the chroma
17559           subsample values:
17560
17561                   scale="trunc(3/2*iw/hsub)*hsub:trunc(3/2*ih/vsub)*vsub"
17562
17563       •   Increase the width to a maximum of 500 pixels, keeping the same
17564           aspect ratio as the input:
17565
17566                   scale=w='min(500\, iw*3/2):h=-1'
17567
17568       •   Make pixels square by combining scale and setsar:
17569
17570                   scale='trunc(ih*dar):ih',setsar=1/1
17571
17572       •   Make pixels square by combining scale and setsar, making sure the
17573           resulting resolution is even (required by some codecs):
17574
17575                   scale='trunc(ih*dar/2)*2:trunc(ih/2)*2',setsar=1/1
17576
17577       Commands
17578
17579       This filter supports the following commands:
17580
17581       width, w
17582       height, h
17583           Set the output video dimension expression.  The command accepts the
17584           same syntax of the corresponding option.
17585
17586           If the specified expression is not valid, it is kept at its current
17587           value.
17588
17589   scale_cuda
17590       Scale (resize) and convert (pixel format) the input video, using
17591       accelerated CUDA kernels.  Setting the output width and height works in
17592       the same way as for the scale filter.
17593
17594       The filter accepts the following options:
17595
17596       w
17597       h   Set the output video dimension expression. Default value is the
17598           input dimension.
17599
17600           Allows for the same expressions as the scale filter.
17601
17602       interp_algo
17603           Sets the algorithm used for scaling:
17604
17605           nearest
17606               Nearest neighbour
17607
17608               Used by default if input parameters match the desired output.
17609
17610           bilinear
17611               Bilinear
17612
17613           bicubic
17614               Bicubic
17615
17616               This is the default.
17617
17618           lanczos
17619               Lanczos
17620
17621       format
17622           Controls the output pixel format. By default, or if none is
17623           specified, the input pixel format is used.
17624
17625           The filter does not support converting between YUV and RGB pixel
17626           formats.
17627
17628       passthrough
17629           If set to 0, every frame is processed, even if no conversion is
17630           neccesary.  This mode can be useful to use the filter as a buffer
17631           for a downstream frame-consumer that exhausts the limited decoder
17632           frame pool.
17633
17634           If set to 1, frames are passed through as-is if they match the
17635           desired output parameters. This is the default behaviour.
17636
17637       param
17638           Algorithm-Specific parameter.
17639
17640           Affects the curves of the bicubic algorithm.
17641
17642       force_original_aspect_ratio
17643       force_divisible_by
17644           Work the same as the identical scale filter options.
17645
17646       Examples
17647
17648       •   Scale input to 720p, keeping aspect ratio and ensuring the output
17649           is yuv420p.
17650
17651                   scale_cuda=-2:720:format=yuv420p
17652
17653       •   Upscale to 4K using nearest neighbour algorithm.
17654
17655                   scale_cuda=4096:2160:interp_algo=nearest
17656
17657       •   Don't do any conversion or scaling, but copy all input frames into
17658           newly allocated ones.  This can be useful to deal with a filter and
17659           encode chain that otherwise exhausts the decoders frame pool.
17660
17661                   scale_cuda=passthrough=0
17662
17663   scale_npp
17664       Use the NVIDIA Performance Primitives (libnpp) to perform scaling
17665       and/or pixel format conversion on CUDA video frames. Setting the output
17666       width and height works in the same way as for the scale filter.
17667
17668       The following additional options are accepted:
17669
17670       format
17671           The pixel format of the output CUDA frames. If set to the string
17672           "same" (the default), the input format will be kept. Note that
17673           automatic format negotiation and conversion is not yet supported
17674           for hardware frames
17675
17676       interp_algo
17677           The interpolation algorithm used for resizing. One of the
17678           following:
17679
17680           nn  Nearest neighbour.
17681
17682           linear
17683           cubic
17684           cubic2p_bspline
17685               2-parameter cubic (B=1, C=0)
17686
17687           cubic2p_catmullrom
17688               2-parameter cubic (B=0, C=1/2)
17689
17690           cubic2p_b05c03
17691               2-parameter cubic (B=1/2, C=3/10)
17692
17693           super
17694               Supersampling
17695
17696           lanczos
17697       force_original_aspect_ratio
17698           Enable decreasing or increasing output video width or height if
17699           necessary to keep the original aspect ratio. Possible values:
17700
17701           disable
17702               Scale the video as specified and disable this feature.
17703
17704           decrease
17705               The output video dimensions will automatically be decreased if
17706               needed.
17707
17708           increase
17709               The output video dimensions will automatically be increased if
17710               needed.
17711
17712           One useful instance of this option is that when you know a specific
17713           device's maximum allowed resolution, you can use this to limit the
17714           output video to that, while retaining the aspect ratio. For
17715           example, device A allows 1280x720 playback, and your video is
17716           1920x800. Using this option (set it to decrease) and specifying
17717           1280x720 to the command line makes the output 1280x533.
17718
17719           Please note that this is a different thing than specifying -1 for w
17720           or h, you still need to specify the output resolution for this
17721           option to work.
17722
17723       force_divisible_by
17724           Ensures that both the output dimensions, width and height, are
17725           divisible by the given integer when used together with
17726           force_original_aspect_ratio. This works similar to using "-n" in
17727           the w and h options.
17728
17729           This option respects the value set for force_original_aspect_ratio,
17730           increasing or decreasing the resolution accordingly. The video's
17731           aspect ratio may be slightly modified.
17732
17733           This option can be handy if you need to have a video fit within or
17734           exceed a defined resolution using force_original_aspect_ratio but
17735           also have encoder restrictions on width or height divisibility.
17736
17737       eval
17738           Specify when to evaluate width and height expression. It accepts
17739           the following values:
17740
17741           init
17742               Only evaluate expressions once during the filter initialization
17743               or when a command is processed.
17744
17745           frame
17746               Evaluate expressions for each incoming frame.
17747
17748       The values of the w and h options are expressions containing the
17749       following constants:
17750
17751       in_w
17752       in_h
17753           The input width and height
17754
17755       iw
17756       ih  These are the same as in_w and in_h.
17757
17758       out_w
17759       out_h
17760           The output (scaled) width and height
17761
17762       ow
17763       oh  These are the same as out_w and out_h
17764
17765       a   The same as iw / ih
17766
17767       sar input sample aspect ratio
17768
17769       dar The input display aspect ratio. Calculated from "(iw / ih) * sar".
17770
17771       n   The (sequential) number of the input frame, starting from 0.  Only
17772           available with "eval=frame".
17773
17774       t   The presentation timestamp of the input frame, expressed as a
17775           number of seconds. Only available with "eval=frame".
17776
17777       pos The position (byte offset) of the frame in the input stream, or NaN
17778           if this information is unavailable and/or meaningless (for example
17779           in case of synthetic video).  Only available with "eval=frame".
17780
17781   scale2ref
17782       Scale (resize) the input video, based on a reference video.
17783
17784       See the scale filter for available options, scale2ref supports the same
17785       but uses the reference video instead of the main input as basis.
17786       scale2ref also supports the following additional constants for the w
17787       and h options:
17788
17789       main_w
17790       main_h
17791           The main input video's width and height
17792
17793       main_a
17794           The same as main_w / main_h
17795
17796       main_sar
17797           The main input video's sample aspect ratio
17798
17799       main_dar, mdar
17800           The main input video's display aspect ratio. Calculated from
17801           "(main_w / main_h) * main_sar".
17802
17803       main_hsub
17804       main_vsub
17805           The main input video's horizontal and vertical chroma subsample
17806           values.  For example for the pixel format "yuv422p" hsub is 2 and
17807           vsub is 1.
17808
17809       main_n
17810           The (sequential) number of the main input frame, starting from 0.
17811           Only available with "eval=frame".
17812
17813       main_t
17814           The presentation timestamp of the main input frame, expressed as a
17815           number of seconds. Only available with "eval=frame".
17816
17817       main_pos
17818           The position (byte offset) of the frame in the main input stream,
17819           or NaN if this information is unavailable and/or meaningless (for
17820           example in case of synthetic video).  Only available with
17821           "eval=frame".
17822
17823       Examples
17824
17825       •   Scale a subtitle stream (b) to match the main video (a) in size
17826           before overlaying
17827
17828                   'scale2ref[b][a];[a][b]overlay'
17829
17830       •   Scale a logo to 1/10th the height of a video, while preserving its
17831           display aspect ratio.
17832
17833                   [logo-in][video-in]scale2ref=w=oh*mdar:h=ih/10[logo-out][video-out]
17834
17835       Commands
17836
17837       This filter supports the following commands:
17838
17839       width, w
17840       height, h
17841           Set the output video dimension expression.  The command accepts the
17842           same syntax of the corresponding option.
17843
17844           If the specified expression is not valid, it is kept at its current
17845           value.
17846
17847   scale2ref_npp
17848       Use the NVIDIA Performance Primitives (libnpp) to scale (resize) the
17849       input video, based on a reference video.
17850
17851       See the scale_npp filter for available options, scale2ref_npp supports
17852       the same but uses the reference video instead of the main input as
17853       basis. scale2ref_npp also supports the following additional constants
17854       for the w and h options:
17855
17856       main_w
17857       main_h
17858           The main input video's width and height
17859
17860       main_a
17861           The same as main_w / main_h
17862
17863       main_sar
17864           The main input video's sample aspect ratio
17865
17866       main_dar, mdar
17867           The main input video's display aspect ratio. Calculated from
17868           "(main_w / main_h) * main_sar".
17869
17870       main_n
17871           The (sequential) number of the main input frame, starting from 0.
17872           Only available with "eval=frame".
17873
17874       main_t
17875           The presentation timestamp of the main input frame, expressed as a
17876           number of seconds. Only available with "eval=frame".
17877
17878       main_pos
17879           The position (byte offset) of the frame in the main input stream,
17880           or NaN if this information is unavailable and/or meaningless (for
17881           example in case of synthetic video).  Only available with
17882           "eval=frame".
17883
17884       Examples
17885
17886       •   Scale a subtitle stream (b) to match the main video (a) in size
17887           before overlaying
17888
17889                   'scale2ref_npp[b][a];[a][b]overlay_cuda'
17890
17891       •   Scale a logo to 1/10th the height of a video, while preserving its
17892           display aspect ratio.
17893
17894                   [logo-in][video-in]scale2ref_npp=w=oh*mdar:h=ih/10[logo-out][video-out]
17895
17896   scharr
17897       Apply scharr operator to input video stream.
17898
17899       The filter accepts the following option:
17900
17901       planes
17902           Set which planes will be processed, unprocessed planes will be
17903           copied.  By default value 0xf, all planes will be processed.
17904
17905       scale
17906           Set value which will be multiplied with filtered result.
17907
17908       delta
17909           Set value which will be added to filtered result.
17910
17911       Commands
17912
17913       This filter supports the all above options as commands.
17914
17915   scroll
17916       Scroll input video horizontally and/or vertically by constant speed.
17917
17918       The filter accepts the following options:
17919
17920       horizontal, h
17921           Set the horizontal scrolling speed. Default is 0. Allowed range is
17922           from -1 to 1.  Negative values changes scrolling direction.
17923
17924       vertical, v
17925           Set the vertical scrolling speed. Default is 0. Allowed range is
17926           from -1 to 1.  Negative values changes scrolling direction.
17927
17928       hpos
17929           Set the initial horizontal scrolling position. Default is 0.
17930           Allowed range is from 0 to 1.
17931
17932       vpos
17933           Set the initial vertical scrolling position. Default is 0. Allowed
17934           range is from 0 to 1.
17935
17936       Commands
17937
17938       This filter supports the following commands:
17939
17940       horizontal, h
17941           Set the horizontal scrolling speed.
17942
17943       vertical, v
17944           Set the vertical scrolling speed.
17945
17946   scdet
17947       Detect video scene change.
17948
17949       This filter sets frame metadata with mafd between frame, the scene
17950       score, and forward the frame to the next filter, so they can use these
17951       metadata to detect scene change or others.
17952
17953       In addition, this filter logs a message and sets frame metadata when it
17954       detects a scene change by threshold.
17955
17956       "lavfi.scd.mafd" metadata keys are set with mafd for every frame.
17957
17958       "lavfi.scd.score" metadata keys are set with scene change score for
17959       every frame to detect scene change.
17960
17961       "lavfi.scd.time" metadata keys are set with current filtered frame time
17962       which detect scene change with threshold.
17963
17964       The filter accepts the following options:
17965
17966       threshold, t
17967           Set the scene change detection threshold as a percentage of maximum
17968           change. Good values are in the "[8.0, 14.0]" range. The range for
17969           threshold is "[0., 100.]".
17970
17971           Default value is 10..
17972
17973       sc_pass, s
17974           Set the flag to pass scene change frames to the next filter.
17975           Default value is 0 You can enable it if you want to get snapshot of
17976           scene change frames only.
17977
17978   selectivecolor
17979       Adjust cyan, magenta, yellow and black (CMYK) to certain ranges of
17980       colors (such as "reds", "yellows", "greens", "cyans", ...). The
17981       adjustment range is defined by the "purity" of the color (that is, how
17982       saturated it already is).
17983
17984       This filter is similar to the Adobe Photoshop Selective Color tool.
17985
17986       The filter accepts the following options:
17987
17988       correction_method
17989           Select color correction method.
17990
17991           Available values are:
17992
17993           absolute
17994               Specified adjustments are applied "as-is" (added/subtracted to
17995               original pixel component value).
17996
17997           relative
17998               Specified adjustments are relative to the original component
17999               value.
18000
18001           Default is "absolute".
18002
18003       reds
18004           Adjustments for red pixels (pixels where the red component is the
18005           maximum)
18006
18007       yellows
18008           Adjustments for yellow pixels (pixels where the blue component is
18009           the minimum)
18010
18011       greens
18012           Adjustments for green pixels (pixels where the green component is
18013           the maximum)
18014
18015       cyans
18016           Adjustments for cyan pixels (pixels where the red component is the
18017           minimum)
18018
18019       blues
18020           Adjustments for blue pixels (pixels where the blue component is the
18021           maximum)
18022
18023       magentas
18024           Adjustments for magenta pixels (pixels where the green component is
18025           the minimum)
18026
18027       whites
18028           Adjustments for white pixels (pixels where all components are
18029           greater than 128)
18030
18031       neutrals
18032           Adjustments for all pixels except pure black and pure white
18033
18034       blacks
18035           Adjustments for black pixels (pixels where all components are
18036           lesser than 128)
18037
18038       psfile
18039           Specify a Photoshop selective color file (".asv") to import the
18040           settings from.
18041
18042       All the adjustment settings (reds, yellows, ...) accept up to 4 space
18043       separated floating point adjustment values in the [-1,1] range,
18044       respectively to adjust the amount of cyan, magenta, yellow and black
18045       for the pixels of its range.
18046
18047       Examples
18048
18049       •   Increase cyan by 50% and reduce yellow by 33% in every green areas,
18050           and increase magenta by 27% in blue areas:
18051
18052                   selectivecolor=greens=.5 0 -.33 0:blues=0 .27
18053
18054       •   Use a Photoshop selective color preset:
18055
18056                   selectivecolor=psfile=MySelectiveColorPresets/Misty.asv
18057
18058   separatefields
18059       The "separatefields" takes a frame-based video input and splits each
18060       frame into its components fields, producing a new half height clip with
18061       twice the frame rate and twice the frame count.
18062
18063       This filter use field-dominance information in frame to decide which of
18064       each pair of fields to place first in the output.  If it gets it wrong
18065       use setfield filter before "separatefields" filter.
18066
18067   setdar, setsar
18068       The "setdar" filter sets the Display Aspect Ratio for the filter output
18069       video.
18070
18071       This is done by changing the specified Sample (aka Pixel) Aspect Ratio,
18072       according to the following equation:
18073
18074               <DAR> = <HORIZONTAL_RESOLUTION> / <VERTICAL_RESOLUTION> * <SAR>
18075
18076       Keep in mind that the "setdar" filter does not modify the pixel
18077       dimensions of the video frame. Also, the display aspect ratio set by
18078       this filter may be changed by later filters in the filterchain, e.g. in
18079       case of scaling or if another "setdar" or a "setsar" filter is applied.
18080
18081       The "setsar" filter sets the Sample (aka Pixel) Aspect Ratio for the
18082       filter output video.
18083
18084       Note that as a consequence of the application of this filter, the
18085       output display aspect ratio will change according to the equation
18086       above.
18087
18088       Keep in mind that the sample aspect ratio set by the "setsar" filter
18089       may be changed by later filters in the filterchain, e.g. if another
18090       "setsar" or a "setdar" filter is applied.
18091
18092       It accepts the following parameters:
18093
18094       r, ratio, dar ("setdar" only), sar ("setsar" only)
18095           Set the aspect ratio used by the filter.
18096
18097           The parameter can be a floating point number string, an expression,
18098           or a string of the form num:den, where num and den are the
18099           numerator and denominator of the aspect ratio. If the parameter is
18100           not specified, it is assumed the value "0".  In case the form
18101           "num:den" is used, the ":" character should be escaped.
18102
18103       max Set the maximum integer value to use for expressing numerator and
18104           denominator when reducing the expressed aspect ratio to a rational.
18105           Default value is 100.
18106
18107       The parameter sar is an expression containing the following constants:
18108
18109       E, PI, PHI
18110           These are approximated values for the mathematical constants e
18111           (Euler's number), pi (Greek pi), and phi (the golden ratio).
18112
18113       w, h
18114           The input width and height.
18115
18116       a   These are the same as w / h.
18117
18118       sar The input sample aspect ratio.
18119
18120       dar The input display aspect ratio. It is the same as (w / h) * sar.
18121
18122       hsub, vsub
18123           Horizontal and vertical chroma subsample values. For example, for
18124           the pixel format "yuv422p" hsub is 2 and vsub is 1.
18125
18126       Examples
18127
18128       •   To change the display aspect ratio to 16:9, specify one of the
18129           following:
18130
18131                   setdar=dar=1.77777
18132                   setdar=dar=16/9
18133
18134       •   To change the sample aspect ratio to 10:11, specify:
18135
18136                   setsar=sar=10/11
18137
18138       •   To set a display aspect ratio of 16:9, and specify a maximum
18139           integer value of 1000 in the aspect ratio reduction, use the
18140           command:
18141
18142                   setdar=ratio=16/9:max=1000
18143
18144   setfield
18145       Force field for the output video frame.
18146
18147       The "setfield" filter marks the interlace type field for the output
18148       frames. It does not change the input frame, but only sets the
18149       corresponding property, which affects how the frame is treated by
18150       following filters (e.g. "fieldorder" or "yadif").
18151
18152       The filter accepts the following options:
18153
18154       mode
18155           Available values are:
18156
18157           auto
18158               Keep the same field property.
18159
18160           bff Mark the frame as bottom-field-first.
18161
18162           tff Mark the frame as top-field-first.
18163
18164           prog
18165               Mark the frame as progressive.
18166
18167   setparams
18168       Force frame parameter for the output video frame.
18169
18170       The "setparams" filter marks interlace and color range for the output
18171       frames. It does not change the input frame, but only sets the
18172       corresponding property, which affects how the frame is treated by
18173       filters/encoders.
18174
18175       field_mode
18176           Available values are:
18177
18178           auto
18179               Keep the same field property (default).
18180
18181           bff Mark the frame as bottom-field-first.
18182
18183           tff Mark the frame as top-field-first.
18184
18185           prog
18186               Mark the frame as progressive.
18187
18188       range
18189           Available values are:
18190
18191           auto
18192               Keep the same color range property (default).
18193
18194           unspecified, unknown
18195               Mark the frame as unspecified color range.
18196
18197           limited, tv, mpeg
18198               Mark the frame as limited range.
18199
18200           full, pc, jpeg
18201               Mark the frame as full range.
18202
18203       color_primaries
18204           Set the color primaries.  Available values are:
18205
18206           auto
18207               Keep the same color primaries property (default).
18208
18209           bt709
18210           unknown
18211           bt470m
18212           bt470bg
18213           smpte170m
18214           smpte240m
18215           film
18216           bt2020
18217           smpte428
18218           smpte431
18219           smpte432
18220           jedec-p22
18221       color_trc
18222           Set the color transfer.  Available values are:
18223
18224           auto
18225               Keep the same color trc property (default).
18226
18227           bt709
18228           unknown
18229           bt470m
18230           bt470bg
18231           smpte170m
18232           smpte240m
18233           linear
18234           log100
18235           log316
18236           iec61966-2-4
18237           bt1361e
18238           iec61966-2-1
18239           bt2020-10
18240           bt2020-12
18241           smpte2084
18242           smpte428
18243           arib-std-b67
18244       colorspace
18245           Set the colorspace.  Available values are:
18246
18247           auto
18248               Keep the same colorspace property (default).
18249
18250           gbr
18251           bt709
18252           unknown
18253           fcc
18254           bt470bg
18255           smpte170m
18256           smpte240m
18257           ycgco
18258           bt2020nc
18259           bt2020c
18260           smpte2085
18261           chroma-derived-nc
18262           chroma-derived-c
18263           ictcp
18264
18265   sharpen_npp
18266       Use the NVIDIA Performance Primitives (libnpp) to perform image
18267       sharpening with border control.
18268
18269       The following additional options are accepted:
18270
18271       border_type
18272           Type of sampling to be used ad frame borders. One of the following:
18273
18274           replicate
18275               Replicate pixel values.
18276
18277   shear
18278       Apply shear transform to input video.
18279
18280       This filter supports the following options:
18281
18282       shx Shear factor in X-direction. Default value is 0.  Allowed range is
18283           from -2 to 2.
18284
18285       shy Shear factor in Y-direction. Default value is 0.  Allowed range is
18286           from -2 to 2.
18287
18288       fillcolor, c
18289           Set the color used to fill the output area not covered by the
18290           transformed video. For the general syntax of this option, check the
18291           "Color" section in the ffmpeg-utils manual.  If the special value
18292           "none" is selected then no background is printed (useful for
18293           example if the background is never shown).
18294
18295           Default value is "black".
18296
18297       interp
18298           Set interpolation type. Can be "bilinear" or "nearest". Default is
18299           "bilinear".
18300
18301       Commands
18302
18303       This filter supports the all above options as commands.
18304
18305   showinfo
18306       Show a line containing various information for each input video frame.
18307       The input video is not modified.
18308
18309       This filter supports the following options:
18310
18311       checksum
18312           Calculate checksums of each plane. By default enabled.
18313
18314       The shown line contains a sequence of key/value pairs of the form
18315       key:value.
18316
18317       The following values are shown in the output:
18318
18319       n   The (sequential) number of the input frame, starting from 0.
18320
18321       pts The Presentation TimeStamp of the input frame, expressed as a
18322           number of time base units. The time base unit depends on the filter
18323           input pad.
18324
18325       pts_time
18326           The Presentation TimeStamp of the input frame, expressed as a
18327           number of seconds.
18328
18329       pos The position of the frame in the input stream, or -1 if this
18330           information is unavailable and/or meaningless (for example in case
18331           of synthetic video).
18332
18333       fmt The pixel format name.
18334
18335       sar The sample aspect ratio of the input frame, expressed in the form
18336           num/den.
18337
18338       s   The size of the input frame. For the syntax of this option, check
18339           the "Video size" section in the ffmpeg-utils manual.
18340
18341       i   The type of interlaced mode ("P" for "progressive", "T" for top
18342           field first, "B" for bottom field first).
18343
18344       iskey
18345           This is 1 if the frame is a key frame, 0 otherwise.
18346
18347       type
18348           The picture type of the input frame ("I" for an I-frame, "P" for a
18349           P-frame, "B" for a B-frame, or "?" for an unknown type).  Also
18350           refer to the documentation of the "AVPictureType" enum and of the
18351           "av_get_picture_type_char" function defined in libavutil/avutil.h.
18352
18353       checksum
18354           The Adler-32 checksum (printed in hexadecimal) of all the planes of
18355           the input frame.
18356
18357       plane_checksum
18358           The Adler-32 checksum (printed in hexadecimal) of each plane of the
18359           input frame, expressed in the form "[c0 c1 c2 c3]".
18360
18361       mean
18362           The mean value of pixels in each plane of the input frame,
18363           expressed in the form "[mean0 mean1 mean2 mean3]".
18364
18365       stdev
18366           The standard deviation of pixel values in each plane of the input
18367           frame, expressed in the form "[stdev0 stdev1 stdev2 stdev3]".
18368
18369   showpalette
18370       Displays the 256 colors palette of each frame. This filter is only
18371       relevant for pal8 pixel format frames.
18372
18373       It accepts the following option:
18374
18375       s   Set the size of the box used to represent one palette color entry.
18376           Default is 30 (for a "30x30" pixel box).
18377
18378   shuffleframes
18379       Reorder and/or duplicate and/or drop video frames.
18380
18381       It accepts the following parameters:
18382
18383       mapping
18384           Set the destination indexes of input frames.  This is space or '|'
18385           separated list of indexes that maps input frames to output frames.
18386           Number of indexes also sets maximal value that each index may have.
18387           '-1' index have special meaning and that is to drop frame.
18388
18389       The first frame has the index 0. The default is to keep the input
18390       unchanged.
18391
18392       Examples
18393
18394       •   Swap second and third frame of every three frames of the input:
18395
18396                   ffmpeg -i INPUT -vf "shuffleframes=0 2 1" OUTPUT
18397
18398       •   Swap 10th and 1st frame of every ten frames of the input:
18399
18400                   ffmpeg -i INPUT -vf "shuffleframes=9 1 2 3 4 5 6 7 8 0" OUTPUT
18401
18402   shufflepixels
18403       Reorder pixels in video frames.
18404
18405       This filter accepts the following options:
18406
18407       direction, d
18408           Set shuffle direction. Can be forward or inverse direction.
18409           Default direction is forward.
18410
18411       mode, m
18412           Set shuffle mode. Can be horizontal, vertical or block mode.
18413
18414       width, w
18415       height, h
18416           Set shuffle block_size. In case of horizontal shuffle mode only
18417           width part of size is used, and in case of vertical shuffle mode
18418           only height part of size is used.
18419
18420       seed, s
18421           Set random seed used with shuffling pixels. Mainly useful to set to
18422           be able to reverse filtering process to get original input.  For
18423           example, to reverse forward shuffle you need to use same parameters
18424           and exact same seed and to set direction to inverse.
18425
18426   shuffleplanes
18427       Reorder and/or duplicate video planes.
18428
18429       It accepts the following parameters:
18430
18431       map0
18432           The index of the input plane to be used as the first output plane.
18433
18434       map1
18435           The index of the input plane to be used as the second output plane.
18436
18437       map2
18438           The index of the input plane to be used as the third output plane.
18439
18440       map3
18441           The index of the input plane to be used as the fourth output plane.
18442
18443       The first plane has the index 0. The default is to keep the input
18444       unchanged.
18445
18446       Examples
18447
18448       •   Swap the second and third planes of the input:
18449
18450                   ffmpeg -i INPUT -vf shuffleplanes=0:2:1:3 OUTPUT
18451
18452   signalstats
18453       Evaluate various visual metrics that assist in determining issues
18454       associated with the digitization of analog video media.
18455
18456       By default the filter will log these metadata values:
18457
18458       YMIN
18459           Display the minimal Y value contained within the input frame.
18460           Expressed in range of [0-255].
18461
18462       YLOW
18463           Display the Y value at the 10% percentile within the input frame.
18464           Expressed in range of [0-255].
18465
18466       YAVG
18467           Display the average Y value within the input frame. Expressed in
18468           range of [0-255].
18469
18470       YHIGH
18471           Display the Y value at the 90% percentile within the input frame.
18472           Expressed in range of [0-255].
18473
18474       YMAX
18475           Display the maximum Y value contained within the input frame.
18476           Expressed in range of [0-255].
18477
18478       UMIN
18479           Display the minimal U value contained within the input frame.
18480           Expressed in range of [0-255].
18481
18482       ULOW
18483           Display the U value at the 10% percentile within the input frame.
18484           Expressed in range of [0-255].
18485
18486       UAVG
18487           Display the average U value within the input frame. Expressed in
18488           range of [0-255].
18489
18490       UHIGH
18491           Display the U value at the 90% percentile within the input frame.
18492           Expressed in range of [0-255].
18493
18494       UMAX
18495           Display the maximum U value contained within the input frame.
18496           Expressed in range of [0-255].
18497
18498       VMIN
18499           Display the minimal V value contained within the input frame.
18500           Expressed in range of [0-255].
18501
18502       VLOW
18503           Display the V value at the 10% percentile within the input frame.
18504           Expressed in range of [0-255].
18505
18506       VAVG
18507           Display the average V value within the input frame. Expressed in
18508           range of [0-255].
18509
18510       VHIGH
18511           Display the V value at the 90% percentile within the input frame.
18512           Expressed in range of [0-255].
18513
18514       VMAX
18515           Display the maximum V value contained within the input frame.
18516           Expressed in range of [0-255].
18517
18518       SATMIN
18519           Display the minimal saturation value contained within the input
18520           frame.  Expressed in range of [0-~181.02].
18521
18522       SATLOW
18523           Display the saturation value at the 10% percentile within the input
18524           frame.  Expressed in range of [0-~181.02].
18525
18526       SATAVG
18527           Display the average saturation value within the input frame.
18528           Expressed in range of [0-~181.02].
18529
18530       SATHIGH
18531           Display the saturation value at the 90% percentile within the input
18532           frame.  Expressed in range of [0-~181.02].
18533
18534       SATMAX
18535           Display the maximum saturation value contained within the input
18536           frame.  Expressed in range of [0-~181.02].
18537
18538       HUEMED
18539           Display the median value for hue within the input frame. Expressed
18540           in range of [0-360].
18541
18542       HUEAVG
18543           Display the average value for hue within the input frame. Expressed
18544           in range of [0-360].
18545
18546       YDIF
18547           Display the average of sample value difference between all values
18548           of the Y plane in the current frame and corresponding values of the
18549           previous input frame.  Expressed in range of [0-255].
18550
18551       UDIF
18552           Display the average of sample value difference between all values
18553           of the U plane in the current frame and corresponding values of the
18554           previous input frame.  Expressed in range of [0-255].
18555
18556       VDIF
18557           Display the average of sample value difference between all values
18558           of the V plane in the current frame and corresponding values of the
18559           previous input frame.  Expressed in range of [0-255].
18560
18561       YBITDEPTH
18562           Display bit depth of Y plane in current frame.  Expressed in range
18563           of [0-16].
18564
18565       UBITDEPTH
18566           Display bit depth of U plane in current frame.  Expressed in range
18567           of [0-16].
18568
18569       VBITDEPTH
18570           Display bit depth of V plane in current frame.  Expressed in range
18571           of [0-16].
18572
18573       The filter accepts the following options:
18574
18575       stat
18576       out stat specify an additional form of image analysis.  out output
18577           video with the specified type of pixel highlighted.
18578
18579           Both options accept the following values:
18580
18581           tout
18582               Identify temporal outliers pixels. A temporal outlier is a
18583               pixel unlike the neighboring pixels of the same field. Examples
18584               of temporal outliers include the results of video dropouts,
18585               head clogs, or tape tracking issues.
18586
18587           vrep
18588               Identify vertical line repetition. Vertical line repetition
18589               includes similar rows of pixels within a frame. In born-digital
18590               video vertical line repetition is common, but this pattern is
18591               uncommon in video digitized from an analog source. When it
18592               occurs in video that results from the digitization of an analog
18593               source it can indicate concealment from a dropout compensator.
18594
18595           brng
18596               Identify pixels that fall outside of legal broadcast range.
18597
18598       color, c
18599           Set the highlight color for the out option. The default color is
18600           yellow.
18601
18602       Examples
18603
18604       •   Output data of various video metrics:
18605
18606                   ffprobe -f lavfi movie=example.mov,signalstats="stat=tout+vrep+brng" -show_frames
18607
18608       •   Output specific data about the minimum and maximum values of the Y
18609           plane per frame:
18610
18611                   ffprobe -f lavfi movie=example.mov,signalstats -show_entries frame_tags=lavfi.signalstats.YMAX,lavfi.signalstats.YMIN
18612
18613       •   Playback video while highlighting pixels that are outside of
18614           broadcast range in red.
18615
18616                   ffplay example.mov -vf signalstats="out=brng:color=red"
18617
18618       •   Playback video with signalstats metadata drawn over the frame.
18619
18620                   ffplay example.mov -vf signalstats=stat=brng+vrep+tout,drawtext=fontfile=FreeSerif.ttf:textfile=signalstat_drawtext.txt
18621
18622           The contents of signalstat_drawtext.txt used in the command are:
18623
18624                   time %{pts:hms}
18625                   Y (%{metadata:lavfi.signalstats.YMIN}-%{metadata:lavfi.signalstats.YMAX})
18626                   U (%{metadata:lavfi.signalstats.UMIN}-%{metadata:lavfi.signalstats.UMAX})
18627                   V (%{metadata:lavfi.signalstats.VMIN}-%{metadata:lavfi.signalstats.VMAX})
18628                   saturation maximum: %{metadata:lavfi.signalstats.SATMAX}
18629
18630   signature
18631       Calculates the MPEG-7 Video Signature. The filter can handle more than
18632       one input. In this case the matching between the inputs can be
18633       calculated additionally.  The filter always passes through the first
18634       input. The signature of each stream can be written into a file.
18635
18636       It accepts the following options:
18637
18638       detectmode
18639           Enable or disable the matching process.
18640
18641           Available values are:
18642
18643           off Disable the calculation of a matching (default).
18644
18645           full
18646               Calculate the matching for the whole video and output whether
18647               the whole video matches or only parts.
18648
18649           fast
18650               Calculate only until a matching is found or the video ends.
18651               Should be faster in some cases.
18652
18653       nb_inputs
18654           Set the number of inputs. The option value must be a non negative
18655           integer.  Default value is 1.
18656
18657       filename
18658           Set the path to which the output is written. If there is more than
18659           one input, the path must be a prototype, i.e. must contain %d or
18660           %0nd (where n is a positive integer), that will be replaced with
18661           the input number. If no filename is specified, no output will be
18662           written. This is the default.
18663
18664       format
18665           Choose the output format.
18666
18667           Available values are:
18668
18669           binary
18670               Use the specified binary representation (default).
18671
18672           xml Use the specified xml representation.
18673
18674       th_d
18675           Set threshold to detect one word as similar. The option value must
18676           be an integer greater than zero. The default value is 9000.
18677
18678       th_dc
18679           Set threshold to detect all words as similar. The option value must
18680           be an integer greater than zero. The default value is 60000.
18681
18682       th_xh
18683           Set threshold to detect frames as similar. The option value must be
18684           an integer greater than zero. The default value is 116.
18685
18686       th_di
18687           Set the minimum length of a sequence in frames to recognize it as
18688           matching sequence. The option value must be a non negative integer
18689           value.  The default value is 0.
18690
18691       th_it
18692           Set the minimum relation, that matching frames to all frames must
18693           have.  The option value must be a double value between 0 and 1. The
18694           default value is 0.5.
18695
18696       Examples
18697
18698       •   To calculate the signature of an input video and store it in
18699           signature.bin:
18700
18701                   ffmpeg -i input.mkv -vf signature=filename=signature.bin -map 0:v -f null -
18702
18703       •   To detect whether two videos match and store the signatures in XML
18704           format in signature0.xml and signature1.xml:
18705
18706                   ffmpeg -i input1.mkv -i input2.mkv -filter_complex "[0:v][1:v] signature=nb_inputs=2:detectmode=full:format=xml:filename=signature%d.xml" -map :v -f null -
18707
18708   siti
18709       Calculate Spatial Info (SI) and Temporal Info (TI) scores for a video,
18710       as defined in ITU-T P.910: Subjective video quality assessment methods
18711       for multimedia applications. Available PDF at
18712       <https://www.itu.int/rec/T-REC-P.910-199909-S/en >.
18713
18714       It accepts the following option:
18715
18716       print_summary
18717           If set to 1, Summary statistics will be printed to the console.
18718           Default 0.
18719
18720       Examples
18721
18722       •   To calculate SI/TI metrics and print summary:
18723
18724                   ffmpeg -i input.mp4 -vf siti=print_summary=1 -f null -
18725
18726   smartblur
18727       Blur the input video without impacting the outlines.
18728
18729       It accepts the following options:
18730
18731       luma_radius, lr
18732           Set the luma radius. The option value must be a float number in the
18733           range [0.1,5.0] that specifies the variance of the gaussian filter
18734           used to blur the image (slower if larger). Default value is 1.0.
18735
18736       luma_strength, ls
18737           Set the luma strength. The option value must be a float number in
18738           the range [-1.0,1.0] that configures the blurring. A value included
18739           in [0.0,1.0] will blur the image whereas a value included in
18740           [-1.0,0.0] will sharpen the image. Default value is 1.0.
18741
18742       luma_threshold, lt
18743           Set the luma threshold used as a coefficient to determine whether a
18744           pixel should be blurred or not. The option value must be an integer
18745           in the range [-30,30]. A value of 0 will filter all the image, a
18746           value included in [0,30] will filter flat areas and a value
18747           included in [-30,0] will filter edges. Default value is 0.
18748
18749       chroma_radius, cr
18750           Set the chroma radius. The option value must be a float number in
18751           the range [0.1,5.0] that specifies the variance of the gaussian
18752           filter used to blur the image (slower if larger). Default value is
18753           luma_radius.
18754
18755       chroma_strength, cs
18756           Set the chroma strength. The option value must be a float number in
18757           the range [-1.0,1.0] that configures the blurring. A value included
18758           in [0.0,1.0] will blur the image whereas a value included in
18759           [-1.0,0.0] will sharpen the image. Default value is luma_strength.
18760
18761       chroma_threshold, ct
18762           Set the chroma threshold used as a coefficient to determine whether
18763           a pixel should be blurred or not. The option value must be an
18764           integer in the range [-30,30]. A value of 0 will filter all the
18765           image, a value included in [0,30] will filter flat areas and a
18766           value included in [-30,0] will filter edges. Default value is
18767           luma_threshold.
18768
18769       If a chroma option is not explicitly set, the corresponding luma value
18770       is set.
18771
18772   sobel
18773       Apply sobel operator to input video stream.
18774
18775       The filter accepts the following option:
18776
18777       planes
18778           Set which planes will be processed, unprocessed planes will be
18779           copied.  By default value 0xf, all planes will be processed.
18780
18781       scale
18782           Set value which will be multiplied with filtered result.
18783
18784       delta
18785           Set value which will be added to filtered result.
18786
18787       Commands
18788
18789       This filter supports the all above options as commands.
18790
18791   spp
18792       Apply a simple postprocessing filter that compresses and decompresses
18793       the image at several (or - in the case of quality level 6 - all) shifts
18794       and average the results.
18795
18796       The filter accepts the following options:
18797
18798       quality
18799           Set quality. This option defines the number of levels for
18800           averaging. It accepts an integer in the range 0-6. If set to 0, the
18801           filter will have no effect. A value of 6 means the higher quality.
18802           For each increment of that value the speed drops by a factor of
18803           approximately 2.  Default value is 3.
18804
18805       qp  Force a constant quantization parameter. If not set, the filter
18806           will use the QP from the video stream (if available).
18807
18808       mode
18809           Set thresholding mode. Available modes are:
18810
18811           hard
18812               Set hard thresholding (default).
18813
18814           soft
18815               Set soft thresholding (better de-ringing effect, but likely
18816               blurrier).
18817
18818       use_bframe_qp
18819           Enable the use of the QP from the B-Frames if set to 1. Using this
18820           option may cause flicker since the B-Frames have often larger QP.
18821           Default is 0 (not enabled).
18822
18823       Commands
18824
18825       This filter supports the following commands:
18826
18827       quality, level
18828           Set quality level. The value "max" can be used to set the maximum
18829           level, currently 6.
18830
18831   sr
18832       Scale the input by applying one of the super-resolution methods based
18833       on convolutional neural networks. Supported models:
18834
18835       •   Super-Resolution Convolutional Neural Network model (SRCNN).  See
18836           <https://arxiv.org/abs/1501.00092>.
18837
18838       •   Efficient Sub-Pixel Convolutional Neural Network model (ESPCN).
18839           See <https://arxiv.org/abs/1609.05158>.
18840
18841       Training scripts as well as scripts for model file (.pb) saving can be
18842       found at <https://github.com/XueweiMeng/sr/tree/sr_dnn_native>.
18843       Original repository is at
18844       <https://github.com/HighVoltageRocknRoll/sr.git>.
18845
18846       Native model files (.model) can be generated from TensorFlow model
18847       files (.pb) by using tools/python/convert.py
18848
18849       The filter accepts the following options:
18850
18851       dnn_backend
18852           Specify which DNN backend to use for model loading and execution.
18853           This option accepts the following values:
18854
18855           native
18856               Native implementation of DNN loading and execution.
18857
18858           tensorflow
18859               TensorFlow backend. To enable this backend you need to install
18860               the TensorFlow for C library (see
18861               <https://www.tensorflow.org/install/lang_c>) and configure
18862               FFmpeg with "--enable-libtensorflow"
18863
18864           Default value is native.
18865
18866       model
18867           Set path to model file specifying network architecture and its
18868           parameters.  Note that different backends use different file
18869           formats. TensorFlow backend can load files for both formats, while
18870           native backend can load files for only its format.
18871
18872       scale_factor
18873           Set scale factor for SRCNN model. Allowed values are 2, 3 and 4.
18874           Default value is 2. Scale factor is necessary for SRCNN model,
18875           because it accepts input upscaled using bicubic upscaling with
18876           proper scale factor.
18877
18878       To get full functionality (such as async execution), please use the
18879       dnn_processing filter.
18880
18881   ssim
18882       Obtain the SSIM (Structural SImilarity Metric) between two input
18883       videos.
18884
18885       This filter takes in input two input videos, the first input is
18886       considered the "main" source and is passed unchanged to the output. The
18887       second input is used as a "reference" video for computing the SSIM.
18888
18889       Both video inputs must have the same resolution and pixel format for
18890       this filter to work correctly. Also it assumes that both inputs have
18891       the same number of frames, which are compared one by one.
18892
18893       The filter stores the calculated SSIM of each frame.
18894
18895       The description of the accepted parameters follows.
18896
18897       stats_file, f
18898           If specified the filter will use the named file to save the SSIM of
18899           each individual frame. When filename equals "-" the data is sent to
18900           standard output.
18901
18902       The file printed if stats_file is selected, contains a sequence of
18903       key/value pairs of the form key:value for each compared couple of
18904       frames.
18905
18906       A description of each shown parameter follows:
18907
18908       n   sequential number of the input frame, starting from 1
18909
18910       Y, U, V, R, G, B
18911           SSIM of the compared frames for the component specified by the
18912           suffix.
18913
18914       All SSIM of the compared frames for the whole frame.
18915
18916       dB  Same as above but in dB representation.
18917
18918       This filter also supports the framesync options.
18919
18920       Examples
18921
18922       •   For example:
18923
18924                   movie=ref_movie.mpg, setpts=PTS-STARTPTS [main];
18925                   [main][ref] ssim="stats_file=stats.log" [out]
18926
18927           On this example the input file being processed is compared with the
18928           reference file ref_movie.mpg. The SSIM of each individual frame is
18929           stored in stats.log.
18930
18931       •   Another example with both psnr and ssim at same time:
18932
18933                   ffmpeg -i main.mpg -i ref.mpg -lavfi  "ssim;[0:v][1:v]psnr" -f null -
18934
18935       •   Another example with different containers:
18936
18937                   ffmpeg -i main.mpg -i ref.mkv -lavfi  "[0:v]settb=AVTB,setpts=PTS-STARTPTS[main];[1:v]settb=AVTB,setpts=PTS-STARTPTS[ref];[main][ref]ssim" -f null -
18938
18939   stereo3d
18940       Convert between different stereoscopic image formats.
18941
18942       The filters accept the following options:
18943
18944       in  Set stereoscopic image format of input.
18945
18946           Available values for input image formats are:
18947
18948           sbsl
18949               side by side parallel (left eye left, right eye right)
18950
18951           sbsr
18952               side by side crosseye (right eye left, left eye right)
18953
18954           sbs2l
18955               side by side parallel with half width resolution (left eye
18956               left, right eye right)
18957
18958           sbs2r
18959               side by side crosseye with half width resolution (right eye
18960               left, left eye right)
18961
18962           abl
18963           tbl above-below (left eye above, right eye below)
18964
18965           abr
18966           tbr above-below (right eye above, left eye below)
18967
18968           ab2l
18969           tb2l
18970               above-below with half height resolution (left eye above, right
18971               eye below)
18972
18973           ab2r
18974           tb2r
18975               above-below with half height resolution (right eye above, left
18976               eye below)
18977
18978           al  alternating frames (left eye first, right eye second)
18979
18980           ar  alternating frames (right eye first, left eye second)
18981
18982           irl interleaved rows (left eye has top row, right eye starts on
18983               next row)
18984
18985           irr interleaved rows (right eye has top row, left eye starts on
18986               next row)
18987
18988           icl interleaved columns, left eye first
18989
18990           icr interleaved columns, right eye first
18991
18992               Default value is sbsl.
18993
18994       out Set stereoscopic image format of output.
18995
18996           sbsl
18997               side by side parallel (left eye left, right eye right)
18998
18999           sbsr
19000               side by side crosseye (right eye left, left eye right)
19001
19002           sbs2l
19003               side by side parallel with half width resolution (left eye
19004               left, right eye right)
19005
19006           sbs2r
19007               side by side crosseye with half width resolution (right eye
19008               left, left eye right)
19009
19010           abl
19011           tbl above-below (left eye above, right eye below)
19012
19013           abr
19014           tbr above-below (right eye above, left eye below)
19015
19016           ab2l
19017           tb2l
19018               above-below with half height resolution (left eye above, right
19019               eye below)
19020
19021           ab2r
19022           tb2r
19023               above-below with half height resolution (right eye above, left
19024               eye below)
19025
19026           al  alternating frames (left eye first, right eye second)
19027
19028           ar  alternating frames (right eye first, left eye second)
19029
19030           irl interleaved rows (left eye has top row, right eye starts on
19031               next row)
19032
19033           irr interleaved rows (right eye has top row, left eye starts on
19034               next row)
19035
19036           arbg
19037               anaglyph red/blue gray (red filter on left eye, blue filter on
19038               right eye)
19039
19040           argg
19041               anaglyph red/green gray (red filter on left eye, green filter
19042               on right eye)
19043
19044           arcg
19045               anaglyph red/cyan gray (red filter on left eye, cyan filter on
19046               right eye)
19047
19048           arch
19049               anaglyph red/cyan half colored (red filter on left eye, cyan
19050               filter on right eye)
19051
19052           arcc
19053               anaglyph red/cyan color (red filter on left eye, cyan filter on
19054               right eye)
19055
19056           arcd
19057               anaglyph red/cyan color optimized with the least squares
19058               projection of dubois (red filter on left eye, cyan filter on
19059               right eye)
19060
19061           agmg
19062               anaglyph green/magenta gray (green filter on left eye, magenta
19063               filter on right eye)
19064
19065           agmh
19066               anaglyph green/magenta half colored (green filter on left eye,
19067               magenta filter on right eye)
19068
19069           agmc
19070               anaglyph green/magenta colored (green filter on left eye,
19071               magenta filter on right eye)
19072
19073           agmd
19074               anaglyph green/magenta color optimized with the least squares
19075               projection of dubois (green filter on left eye, magenta filter
19076               on right eye)
19077
19078           aybg
19079               anaglyph yellow/blue gray (yellow filter on left eye, blue
19080               filter on right eye)
19081
19082           aybh
19083               anaglyph yellow/blue half colored (yellow filter on left eye,
19084               blue filter on right eye)
19085
19086           aybc
19087               anaglyph yellow/blue colored (yellow filter on left eye, blue
19088               filter on right eye)
19089
19090           aybd
19091               anaglyph yellow/blue color optimized with the least squares
19092               projection of dubois (yellow filter on left eye, blue filter on
19093               right eye)
19094
19095           ml  mono output (left eye only)
19096
19097           mr  mono output (right eye only)
19098
19099           chl checkerboard, left eye first
19100
19101           chr checkerboard, right eye first
19102
19103           icl interleaved columns, left eye first
19104
19105           icr interleaved columns, right eye first
19106
19107           hdmi
19108               HDMI frame pack
19109
19110           Default value is arcd.
19111
19112       Examples
19113
19114       •   Convert input video from side by side parallel to anaglyph
19115           yellow/blue dubois:
19116
19117                   stereo3d=sbsl:aybd
19118
19119       •   Convert input video from above below (left eye above, right eye
19120           below) to side by side crosseye.
19121
19122                   stereo3d=abl:sbsr
19123
19124   streamselect, astreamselect
19125       Select video or audio streams.
19126
19127       The filter accepts the following options:
19128
19129       inputs
19130           Set number of inputs. Default is 2.
19131
19132       map Set input indexes to remap to outputs.
19133
19134       Commands
19135
19136       The "streamselect" and "astreamselect" filter supports the following
19137       commands:
19138
19139       map Set input indexes to remap to outputs.
19140
19141       Examples
19142
19143       •   Select first 5 seconds 1st stream and rest of time 2nd stream:
19144
19145                   sendcmd='5.0 streamselect map 1',streamselect=inputs=2:map=0
19146
19147       •   Same as above, but for audio:
19148
19149                   asendcmd='5.0 astreamselect map 1',astreamselect=inputs=2:map=0
19150
19151   subtitles
19152       Draw subtitles on top of input video using the libass library.
19153
19154       To enable compilation of this filter you need to configure FFmpeg with
19155       "--enable-libass". This filter also requires a build with libavcodec
19156       and libavformat to convert the passed subtitles file to ASS (Advanced
19157       Substation Alpha) subtitles format.
19158
19159       The filter accepts the following options:
19160
19161       filename, f
19162           Set the filename of the subtitle file to read. It must be
19163           specified.
19164
19165       original_size
19166           Specify the size of the original video, the video for which the ASS
19167           file was composed. For the syntax of this option, check the "Video
19168           size" section in the ffmpeg-utils manual.  Due to a misdesign in
19169           ASS aspect ratio arithmetic, this is necessary to correctly scale
19170           the fonts if the aspect ratio has been changed.
19171
19172       fontsdir
19173           Set a directory path containing fonts that can be used by the
19174           filter.  These fonts will be used in addition to whatever the font
19175           provider uses.
19176
19177       alpha
19178           Process alpha channel, by default alpha channel is untouched.
19179
19180       charenc
19181           Set subtitles input character encoding. "subtitles" filter only.
19182           Only useful if not UTF-8.
19183
19184       stream_index, si
19185           Set subtitles stream index. "subtitles" filter only.
19186
19187       force_style
19188           Override default style or script info parameters of the subtitles.
19189           It accepts a string containing ASS style format "KEY=VALUE" couples
19190           separated by ",".
19191
19192       If the first key is not specified, it is assumed that the first value
19193       specifies the filename.
19194
19195       For example, to render the file sub.srt on top of the input video, use
19196       the command:
19197
19198               subtitles=sub.srt
19199
19200       which is equivalent to:
19201
19202               subtitles=filename=sub.srt
19203
19204       To render the default subtitles stream from file video.mkv, use:
19205
19206               subtitles=video.mkv
19207
19208       To render the second subtitles stream from that file, use:
19209
19210               subtitles=video.mkv:si=1
19211
19212       To make the subtitles stream from sub.srt appear in 80% transparent
19213       blue "DejaVu Serif", use:
19214
19215               subtitles=sub.srt:force_style='Fontname=DejaVu Serif,PrimaryColour=&HCCFF0000'
19216
19217   super2xsai
19218       Scale the input by 2x and smooth using the Super2xSaI (Scale and
19219       Interpolate) pixel art scaling algorithm.
19220
19221       Useful for enlarging pixel art images without reducing sharpness.
19222
19223   swaprect
19224       Swap two rectangular objects in video.
19225
19226       This filter accepts the following options:
19227
19228       w   Set object width.
19229
19230       h   Set object height.
19231
19232       x1  Set 1st rect x coordinate.
19233
19234       y1  Set 1st rect y coordinate.
19235
19236       x2  Set 2nd rect x coordinate.
19237
19238       y2  Set 2nd rect y coordinate.
19239
19240           All expressions are evaluated once for each frame.
19241
19242       The all options are expressions containing the following constants:
19243
19244       w
19245       h   The input width and height.
19246
19247       a   same as w / h
19248
19249       sar input sample aspect ratio
19250
19251       dar input display aspect ratio, it is the same as (w / h) * sar
19252
19253       n   The number of the input frame, starting from 0.
19254
19255       t   The timestamp expressed in seconds. It's NAN if the input timestamp
19256           is unknown.
19257
19258       pos the position in the file of the input frame, NAN if unknown
19259
19260       Commands
19261
19262       This filter supports the all above options as commands.
19263
19264   swapuv
19265       Swap U & V plane.
19266
19267   tblend
19268       Blend successive video frames.
19269
19270       See blend
19271
19272   telecine
19273       Apply telecine process to the video.
19274
19275       This filter accepts the following options:
19276
19277       first_field
19278           top, t
19279               top field first
19280
19281           bottom, b
19282               bottom field first The default value is "top".
19283
19284       pattern
19285           A string of numbers representing the pulldown pattern you wish to
19286           apply.  The default value is 23.
19287
19288               Some typical patterns:
19289
19290               NTSC output (30i):
19291               27.5p: 32222
19292               24p: 23 (classic)
19293               24p: 2332 (preferred)
19294               20p: 33
19295               18p: 334
19296               16p: 3444
19297
19298               PAL output (25i):
19299               27.5p: 12222
19300               24p: 222222222223 ("Euro pulldown")
19301               16.67p: 33
19302               16p: 33333334
19303
19304   thistogram
19305       Compute and draw a color distribution histogram for the input video
19306       across time.
19307
19308       Unlike histogram video filter which only shows histogram of single
19309       input frame at certain time, this filter shows also past histograms of
19310       number of frames defined by "width" option.
19311
19312       The computed histogram is a representation of the color component
19313       distribution in an image.
19314
19315       The filter accepts the following options:
19316
19317       width, w
19318           Set width of single color component output. Default value is 0.
19319           Value of 0 means width will be picked from input video.  This also
19320           set number of passed histograms to keep.  Allowed range is [0,
19321           8192].
19322
19323       display_mode, d
19324           Set display mode.  It accepts the following values:
19325
19326           stack
19327               Per color component graphs are placed below each other.
19328
19329           parade
19330               Per color component graphs are placed side by side.
19331
19332           overlay
19333               Presents information identical to that in the "parade", except
19334               that the graphs representing color components are superimposed
19335               directly over one another.
19336
19337           Default is "stack".
19338
19339       levels_mode, m
19340           Set mode. Can be either "linear", or "logarithmic".  Default is
19341           "linear".
19342
19343       components, c
19344           Set what color components to display.  Default is 7.
19345
19346       bgopacity, b
19347           Set background opacity. Default is 0.9.
19348
19349       envelope, e
19350           Show envelope. Default is disabled.
19351
19352       ecolor, ec
19353           Set envelope color. Default is "gold".
19354
19355       slide
19356           Set slide mode.
19357
19358           Available values for slide is:
19359
19360           frame
19361               Draw new frame when right border is reached.
19362
19363           replace
19364               Replace old columns with new ones.
19365
19366           scroll
19367               Scroll from right to left.
19368
19369           rscroll
19370               Scroll from left to right.
19371
19372           picture
19373               Draw single picture.
19374
19375           Default is "replace".
19376
19377   threshold
19378       Apply threshold effect to video stream.
19379
19380       This filter needs four video streams to perform thresholding.  First
19381       stream is stream we are filtering.  Second stream is holding threshold
19382       values, third stream is holding min values, and last, fourth stream is
19383       holding max values.
19384
19385       The filter accepts the following option:
19386
19387       planes
19388           Set which planes will be processed, unprocessed planes will be
19389           copied.  By default value 0xf, all planes will be processed.
19390
19391       For example if first stream pixel's component value is less then
19392       threshold value of pixel component from 2nd threshold stream, third
19393       stream value will picked, otherwise fourth stream pixel component value
19394       will be picked.
19395
19396       Using color source filter one can perform various types of
19397       thresholding:
19398
19399       Commands
19400
19401       This filter supports the all options as commands.
19402
19403       Examples
19404
19405       •   Binary threshold, using gray color as threshold:
19406
19407                   ffmpeg -i 320x240.avi -f lavfi -i color=gray -f lavfi -i color=black -f lavfi -i color=white -lavfi threshold output.avi
19408
19409       •   Inverted binary threshold, using gray color as threshold:
19410
19411                   ffmpeg -i 320x240.avi -f lavfi -i color=gray -f lavfi -i color=white -f lavfi -i color=black -lavfi threshold output.avi
19412
19413       •   Truncate binary threshold, using gray color as threshold:
19414
19415                   ffmpeg -i 320x240.avi -f lavfi -i color=gray -i 320x240.avi -f lavfi -i color=gray -lavfi threshold output.avi
19416
19417       •   Threshold to zero, using gray color as threshold:
19418
19419                   ffmpeg -i 320x240.avi -f lavfi -i color=gray -f lavfi -i color=white -i 320x240.avi -lavfi threshold output.avi
19420
19421       •   Inverted threshold to zero, using gray color as threshold:
19422
19423                   ffmpeg -i 320x240.avi -f lavfi -i color=gray -i 320x240.avi -f lavfi -i color=white -lavfi threshold output.avi
19424
19425   thumbnail
19426       Select the most representative frame in a given sequence of consecutive
19427       frames.
19428
19429       The filter accepts the following options:
19430
19431       n   Set the frames batch size to analyze; in a set of n frames, the
19432           filter will pick one of them, and then handle the next batch of n
19433           frames until the end. Default is 100.
19434
19435       Since the filter keeps track of the whole frames sequence, a bigger n
19436       value will result in a higher memory usage, so a high value is not
19437       recommended.
19438
19439       Examples
19440
19441       •   Extract one picture each 50 frames:
19442
19443                   thumbnail=50
19444
19445       •   Complete example of a thumbnail creation with ffmpeg:
19446
19447                   ffmpeg -i in.avi -vf thumbnail,scale=300:200 -frames:v 1 out.png
19448
19449   tile
19450       Tile several successive frames together.
19451
19452       The untile filter can do the reverse.
19453
19454       The filter accepts the following options:
19455
19456       layout
19457           Set the grid size in the form "COLUMNSxROWS". Range is upto
19458           UINT_MAX cells.  Default is "6x5".
19459
19460       nb_frames
19461           Set the maximum number of frames to render in the given area. It
19462           must be less than or equal to wxh. The default value is 0, meaning
19463           all the area will be used.
19464
19465       margin
19466           Set the outer border margin in pixels. Range is 0 to 1024. Default
19467           is 0.
19468
19469       padding
19470           Set the inner border thickness (i.e. the number of pixels between
19471           frames). For more advanced padding options (such as having
19472           different values for the edges), refer to the pad video filter.
19473           Range is 0 to 1024. Default is 0.
19474
19475       color
19476           Specify the color of the unused area. For the syntax of this
19477           option, check the "Color" section in the ffmpeg-utils manual.  The
19478           default value of color is "black".
19479
19480       overlap
19481           Set the number of frames to overlap when tiling several successive
19482           frames together.  The value must be between 0 and nb_frames - 1.
19483           Default is 0.
19484
19485       init_padding
19486           Set the number of frames to initially be empty before displaying
19487           first output frame.  This controls how soon will one get first
19488           output frame.  The value must be between 0 and nb_frames - 1.
19489           Default is 0.
19490
19491       Examples
19492
19493       •   Produce 8x8 PNG tiles of all keyframes (-skip_frame nokey) in a
19494           movie:
19495
19496                   ffmpeg -skip_frame nokey -i file.avi -vf 'scale=128:72,tile=8x8' -an -vsync 0 keyframes%03d.png
19497
19498           The -vsync 0 is necessary to prevent ffmpeg from duplicating each
19499           output frame to accommodate the originally detected frame rate.
19500
19501       •   Display 5 pictures in an area of "3x2" frames, with 7 pixels
19502           between them, and 2 pixels of initial margin, using mixed flat and
19503           named options:
19504
19505                   tile=3x2:nb_frames=5:padding=7:margin=2
19506
19507   tinterlace
19508       Perform various types of temporal field interlacing.
19509
19510       Frames are counted starting from 1, so the first input frame is
19511       considered odd.
19512
19513       The filter accepts the following options:
19514
19515       mode
19516           Specify the mode of the interlacing. This option can also be
19517           specified as a value alone. See below for a list of values for this
19518           option.
19519
19520           Available values are:
19521
19522           merge, 0
19523               Move odd frames into the upper field, even into the lower
19524               field, generating a double height frame at half frame rate.
19525
19526                        ------> time
19527                       Input:
19528                       Frame 1         Frame 2         Frame 3         Frame 4
19529
19530                       11111           22222           33333           44444
19531                       11111           22222           33333           44444
19532                       11111           22222           33333           44444
19533                       11111           22222           33333           44444
19534
19535                       Output:
19536                       11111                           33333
19537                       22222                           44444
19538                       11111                           33333
19539                       22222                           44444
19540                       11111                           33333
19541                       22222                           44444
19542                       11111                           33333
19543                       22222                           44444
19544
19545           drop_even, 1
19546               Only output odd frames, even frames are dropped, generating a
19547               frame with unchanged height at half frame rate.
19548
19549                        ------> time
19550                       Input:
19551                       Frame 1         Frame 2         Frame 3         Frame 4
19552
19553                       11111           22222           33333           44444
19554                       11111           22222           33333           44444
19555                       11111           22222           33333           44444
19556                       11111           22222           33333           44444
19557
19558                       Output:
19559                       11111                           33333
19560                       11111                           33333
19561                       11111                           33333
19562                       11111                           33333
19563
19564           drop_odd, 2
19565               Only output even frames, odd frames are dropped, generating a
19566               frame with unchanged height at half frame rate.
19567
19568                        ------> time
19569                       Input:
19570                       Frame 1         Frame 2         Frame 3         Frame 4
19571
19572                       11111           22222           33333           44444
19573                       11111           22222           33333           44444
19574                       11111           22222           33333           44444
19575                       11111           22222           33333           44444
19576
19577                       Output:
19578                                       22222                           44444
19579                                       22222                           44444
19580                                       22222                           44444
19581                                       22222                           44444
19582
19583           pad, 3
19584               Expand each frame to full height, but pad alternate lines with
19585               black, generating a frame with double height at the same input
19586               frame rate.
19587
19588                        ------> time
19589                       Input:
19590                       Frame 1         Frame 2         Frame 3         Frame 4
19591
19592                       11111           22222           33333           44444
19593                       11111           22222           33333           44444
19594                       11111           22222           33333           44444
19595                       11111           22222           33333           44444
19596
19597                       Output:
19598                       11111           .....           33333           .....
19599                       .....           22222           .....           44444
19600                       11111           .....           33333           .....
19601                       .....           22222           .....           44444
19602                       11111           .....           33333           .....
19603                       .....           22222           .....           44444
19604                       11111           .....           33333           .....
19605                       .....           22222           .....           44444
19606
19607           interleave_top, 4
19608               Interleave the upper field from odd frames with the lower field
19609               from even frames, generating a frame with unchanged height at
19610               half frame rate.
19611
19612                        ------> time
19613                       Input:
19614                       Frame 1         Frame 2         Frame 3         Frame 4
19615
19616                       11111<-         22222           33333<-         44444
19617                       11111           22222<-         33333           44444<-
19618                       11111<-         22222           33333<-         44444
19619                       11111           22222<-         33333           44444<-
19620
19621                       Output:
19622                       11111                           33333
19623                       22222                           44444
19624                       11111                           33333
19625                       22222                           44444
19626
19627           interleave_bottom, 5
19628               Interleave the lower field from odd frames with the upper field
19629               from even frames, generating a frame with unchanged height at
19630               half frame rate.
19631
19632                        ------> time
19633                       Input:
19634                       Frame 1         Frame 2         Frame 3         Frame 4
19635
19636                       11111           22222<-         33333           44444<-
19637                       11111<-         22222           33333<-         44444
19638                       11111           22222<-         33333           44444<-
19639                       11111<-         22222           33333<-         44444
19640
19641                       Output:
19642                       22222                           44444
19643                       11111                           33333
19644                       22222                           44444
19645                       11111                           33333
19646
19647           interlacex2, 6
19648               Double frame rate with unchanged height. Frames are inserted
19649               each containing the second temporal field from the previous
19650               input frame and the first temporal field from the next input
19651               frame. This mode relies on the top_field_first flag. Useful for
19652               interlaced video displays with no field synchronisation.
19653
19654                        ------> time
19655                       Input:
19656                       Frame 1         Frame 2         Frame 3         Frame 4
19657
19658                       11111           22222           33333           44444
19659                        11111           22222           33333           44444
19660                       11111           22222           33333           44444
19661                        11111           22222           33333           44444
19662
19663                       Output:
19664                       11111   22222   22222   33333   33333   44444   44444
19665                        11111   11111   22222   22222   33333   33333   44444
19666                       11111   22222   22222   33333   33333   44444   44444
19667                        11111   11111   22222   22222   33333   33333   44444
19668
19669           mergex2, 7
19670               Move odd frames into the upper field, even into the lower
19671               field, generating a double height frame at same frame rate.
19672
19673                        ------> time
19674                       Input:
19675                       Frame 1         Frame 2         Frame 3         Frame 4
19676
19677                       11111           22222           33333           44444
19678                       11111           22222           33333           44444
19679                       11111           22222           33333           44444
19680                       11111           22222           33333           44444
19681
19682                       Output:
19683                       11111           33333           33333           55555
19684                       22222           22222           44444           44444
19685                       11111           33333           33333           55555
19686                       22222           22222           44444           44444
19687                       11111           33333           33333           55555
19688                       22222           22222           44444           44444
19689                       11111           33333           33333           55555
19690                       22222           22222           44444           44444
19691
19692           Numeric values are deprecated but are accepted for backward
19693           compatibility reasons.
19694
19695           Default mode is "merge".
19696
19697       flags
19698           Specify flags influencing the filter process.
19699
19700           Available value for flags is:
19701
19702           low_pass_filter, vlpf
19703               Enable linear vertical low-pass filtering in the filter.
19704               Vertical low-pass filtering is required when creating an
19705               interlaced destination from a progressive source which contains
19706               high-frequency vertical detail. Filtering will reduce interlace
19707               'twitter' and Moire patterning.
19708
19709           complex_filter, cvlpf
19710               Enable complex vertical low-pass filtering.  This will slightly
19711               less reduce interlace 'twitter' and Moire patterning but better
19712               retain detail and subjective sharpness impression.
19713
19714           bypass_il
19715               Bypass already interlaced frames, only adjust the frame rate.
19716
19717           Vertical low-pass filtering and bypassing already interlaced frames
19718           can only be enabled for mode interleave_top and interleave_bottom.
19719
19720   tmedian
19721       Pick median pixels from several successive input video frames.
19722
19723       The filter accepts the following options:
19724
19725       radius
19726           Set radius of median filter.  Default is 1. Allowed range is from 1
19727           to 127.
19728
19729       planes
19730           Set which planes to filter. Default value is 15, by which all
19731           planes are processed.
19732
19733       percentile
19734           Set median percentile. Default value is 0.5.  Default value of 0.5
19735           will pick always median values, while 0 will pick minimum values,
19736           and 1 maximum values.
19737
19738       Commands
19739
19740       This filter supports all above options as commands, excluding option
19741       "radius".
19742
19743   tmidequalizer
19744       Apply Temporal Midway Video Equalization effect.
19745
19746       Midway Video Equalization adjusts a sequence of video frames to have
19747       the same histograms, while maintaining their dynamics as much as
19748       possible. It's useful for e.g. matching exposures from a video frames
19749       sequence.
19750
19751       This filter accepts the following option:
19752
19753       radius
19754           Set filtering radius. Default is 5. Allowed range is from 1 to 127.
19755
19756       sigma
19757           Set filtering sigma. Default is 0.5. This controls strength of
19758           filtering.  Setting this option to 0 effectively does nothing.
19759
19760       planes
19761           Set which planes to process. Default is 15, which is all available
19762           planes.
19763
19764   tmix
19765       Mix successive video frames.
19766
19767       A description of the accepted options follows.
19768
19769       frames
19770           The number of successive frames to mix. If unspecified, it defaults
19771           to 3.
19772
19773       weights
19774           Specify weight of each input video frame.  Each weight is separated
19775           by space. If number of weights is smaller than number of frames
19776           last specified weight will be used for all remaining unset weights.
19777
19778       scale
19779           Specify scale, if it is set it will be multiplied with sum of each
19780           weight multiplied with pixel values to give final destination pixel
19781           value. By default scale is auto scaled to sum of weights.
19782
19783       planes
19784           Set which planes to filter. Default is all. Allowed range is from 0
19785           to 15.
19786
19787       Examples
19788
19789       •   Average 7 successive frames:
19790
19791                   tmix=frames=7:weights="1 1 1 1 1 1 1"
19792
19793       •   Apply simple temporal convolution:
19794
19795                   tmix=frames=3:weights="-1 3 -1"
19796
19797       •   Similar as above but only showing temporal differences:
19798
19799                   tmix=frames=3:weights="-1 2 -1":scale=1
19800
19801       Commands
19802
19803       This filter supports the following commands:
19804
19805       weights
19806       scale
19807       planes
19808           Syntax is same as option with same name.
19809
19810   tonemap
19811       Tone map colors from different dynamic ranges.
19812
19813       This filter expects data in single precision floating point, as it
19814       needs to operate on (and can output) out-of-range values. Another
19815       filter, such as zscale, is needed to convert the resulting frame to a
19816       usable format.
19817
19818       The tonemapping algorithms implemented only work on linear light, so
19819       input data should be linearized beforehand (and possibly correctly
19820       tagged).
19821
19822               ffmpeg -i INPUT -vf zscale=transfer=linear,tonemap=clip,zscale=transfer=bt709,format=yuv420p OUTPUT
19823
19824       Options
19825
19826       The filter accepts the following options.
19827
19828       tonemap
19829           Set the tone map algorithm to use.
19830
19831           Possible values are:
19832
19833           none
19834               Do not apply any tone map, only desaturate overbright pixels.
19835
19836           clip
19837               Hard-clip any out-of-range values. Use it for perfect color
19838               accuracy for in-range values, while distorting out-of-range
19839               values.
19840
19841           linear
19842               Stretch the entire reference gamut to a linear multiple of the
19843               display.
19844
19845           gamma
19846               Fit a logarithmic transfer between the tone curves.
19847
19848           reinhard
19849               Preserve overall image brightness with a simple curve, using
19850               nonlinear contrast, which results in flattening details and
19851               degrading color accuracy.
19852
19853           hable
19854               Preserve both dark and bright details better than reinhard, at
19855               the cost of slightly darkening everything. Use it when detail
19856               preservation is more important than color and brightness
19857               accuracy.
19858
19859           mobius
19860               Smoothly map out-of-range values, while retaining contrast and
19861               colors for in-range material as much as possible. Use it when
19862               color accuracy is more important than detail preservation.
19863
19864           Default is none.
19865
19866       param
19867           Tune the tone mapping algorithm.
19868
19869           This affects the following algorithms:
19870
19871           none
19872               Ignored.
19873
19874           linear
19875               Specifies the scale factor to use while stretching.  Default to
19876               1.0.
19877
19878           gamma
19879               Specifies the exponent of the function.  Default to 1.8.
19880
19881           clip
19882               Specify an extra linear coefficient to multiply into the signal
19883               before clipping.  Default to 1.0.
19884
19885           reinhard
19886               Specify the local contrast coefficient at the display peak.
19887               Default to 0.5, which means that in-gamut values will be about
19888               half as bright as when clipping.
19889
19890           hable
19891               Ignored.
19892
19893           mobius
19894               Specify the transition point from linear to mobius transform.
19895               Every value below this point is guaranteed to be mapped 1:1.
19896               The higher the value, the more accurate the result will be, at
19897               the cost of losing bright details.  Default to 0.3, which due
19898               to the steep initial slope still preserves in-range colors
19899               fairly accurately.
19900
19901       desat
19902           Apply desaturation for highlights that exceed this level of
19903           brightness. The higher the parameter, the more color information
19904           will be preserved. This setting helps prevent unnaturally blown-out
19905           colors for super-highlights, by (smoothly) turning into white
19906           instead. This makes images feel more natural, at the cost of
19907           reducing information about out-of-range colors.
19908
19909           The default of 2.0 is somewhat conservative and will mostly just
19910           apply to skies or directly sunlit surfaces. A setting of 0.0
19911           disables this option.
19912
19913           This option works only if the input frame has a supported color
19914           tag.
19915
19916       peak
19917           Override signal/nominal/reference peak with this value. Useful when
19918           the embedded peak information in display metadata is not reliable
19919           or when tone mapping from a lower range to a higher range.
19920
19921   tpad
19922       Temporarily pad video frames.
19923
19924       The filter accepts the following options:
19925
19926       start
19927           Specify number of delay frames before input video stream. Default
19928           is 0.
19929
19930       stop
19931           Specify number of padding frames after input video stream.  Set to
19932           -1 to pad indefinitely. Default is 0.
19933
19934       start_mode
19935           Set kind of frames added to beginning of stream.  Can be either add
19936           or clone.  With add frames of solid-color are added.  With clone
19937           frames are clones of first frame.  Default is add.
19938
19939       stop_mode
19940           Set kind of frames added to end of stream.  Can be either add or
19941           clone.  With add frames of solid-color are added.  With clone
19942           frames are clones of last frame.  Default is add.
19943
19944       start_duration, stop_duration
19945           Specify the duration of the start/stop delay. See the Time duration
19946           section in the ffmpeg-utils(1) manual for the accepted syntax.
19947           These options override start and stop. Default is 0.
19948
19949       color
19950           Specify the color of the padded area. For the syntax of this
19951           option, check the "Color" section in the ffmpeg-utils manual.
19952
19953           The default value of color is "black".
19954
19955   transpose
19956       Transpose rows with columns in the input video and optionally flip it.
19957
19958       It accepts the following parameters:
19959
19960       dir Specify the transposition direction.
19961
19962           Can assume the following values:
19963
19964           0, 4, cclock_flip
19965               Rotate by 90 degrees counterclockwise and vertically flip
19966               (default), that is:
19967
19968                       L.R     L.l
19969                       . . ->  . .
19970                       l.r     R.r
19971
19972           1, 5, clock
19973               Rotate by 90 degrees clockwise, that is:
19974
19975                       L.R     l.L
19976                       . . ->  . .
19977                       l.r     r.R
19978
19979           2, 6, cclock
19980               Rotate by 90 degrees counterclockwise, that is:
19981
19982                       L.R     R.r
19983                       . . ->  . .
19984                       l.r     L.l
19985
19986           3, 7, clock_flip
19987               Rotate by 90 degrees clockwise and vertically flip, that is:
19988
19989                       L.R     r.R
19990                       . . ->  . .
19991                       l.r     l.L
19992
19993           For values between 4-7, the transposition is only done if the input
19994           video geometry is portrait and not landscape. These values are
19995           deprecated, the "passthrough" option should be used instead.
19996
19997           Numerical values are deprecated, and should be dropped in favor of
19998           symbolic constants.
19999
20000       passthrough
20001           Do not apply the transposition if the input geometry matches the
20002           one specified by the specified value. It accepts the following
20003           values:
20004
20005           none
20006               Always apply transposition.
20007
20008           portrait
20009               Preserve portrait geometry (when height >= width).
20010
20011           landscape
20012               Preserve landscape geometry (when width >= height).
20013
20014           Default value is "none".
20015
20016       For example to rotate by 90 degrees clockwise and preserve portrait
20017       layout:
20018
20019               transpose=dir=1:passthrough=portrait
20020
20021       The command above can also be specified as:
20022
20023               transpose=1:portrait
20024
20025   transpose_npp
20026       Transpose rows with columns in the input video and optionally flip it.
20027       For more in depth examples see the transpose video filter, which shares
20028       mostly the same options.
20029
20030       It accepts the following parameters:
20031
20032       dir Specify the transposition direction.
20033
20034           Can assume the following values:
20035
20036           cclock_flip
20037               Rotate by 90 degrees counterclockwise and vertically flip.
20038               (default)
20039
20040           clock
20041               Rotate by 90 degrees clockwise.
20042
20043           cclock
20044               Rotate by 90 degrees counterclockwise.
20045
20046           clock_flip
20047               Rotate by 90 degrees clockwise and vertically flip.
20048
20049       passthrough
20050           Do not apply the transposition if the input geometry matches the
20051           one specified by the specified value. It accepts the following
20052           values:
20053
20054           none
20055               Always apply transposition. (default)
20056
20057           portrait
20058               Preserve portrait geometry (when height >= width).
20059
20060           landscape
20061               Preserve landscape geometry (when width >= height).
20062
20063   trim
20064       Trim the input so that the output contains one continuous subpart of
20065       the input.
20066
20067       It accepts the following parameters:
20068
20069       start
20070           Specify the time of the start of the kept section, i.e. the frame
20071           with the timestamp start will be the first frame in the output.
20072
20073       end Specify the time of the first frame that will be dropped, i.e. the
20074           frame immediately preceding the one with the timestamp end will be
20075           the last frame in the output.
20076
20077       start_pts
20078           This is the same as start, except this option sets the start
20079           timestamp in timebase units instead of seconds.
20080
20081       end_pts
20082           This is the same as end, except this option sets the end timestamp
20083           in timebase units instead of seconds.
20084
20085       duration
20086           The maximum duration of the output in seconds.
20087
20088       start_frame
20089           The number of the first frame that should be passed to the output.
20090
20091       end_frame
20092           The number of the first frame that should be dropped.
20093
20094       start, end, and duration are expressed as time duration specifications;
20095       see the Time duration section in the ffmpeg-utils(1) manual for the
20096       accepted syntax.
20097
20098       Note that the first two sets of the start/end options and the duration
20099       option look at the frame timestamp, while the _frame variants simply
20100       count the frames that pass through the filter. Also note that this
20101       filter does not modify the timestamps. If you wish for the output
20102       timestamps to start at zero, insert a setpts filter after the trim
20103       filter.
20104
20105       If multiple start or end options are set, this filter tries to be
20106       greedy and keep all the frames that match at least one of the specified
20107       constraints. To keep only the part that matches all the constraints at
20108       once, chain multiple trim filters.
20109
20110       The defaults are such that all the input is kept. So it is possible to
20111       set e.g.  just the end values to keep everything before the specified
20112       time.
20113
20114       Examples:
20115
20116       •   Drop everything except the second minute of input:
20117
20118                   ffmpeg -i INPUT -vf trim=60:120
20119
20120       •   Keep only the first second:
20121
20122                   ffmpeg -i INPUT -vf trim=duration=1
20123
20124   unpremultiply
20125       Apply alpha unpremultiply effect to input video stream using first
20126       plane of second stream as alpha.
20127
20128       Both streams must have same dimensions and same pixel format.
20129
20130       The filter accepts the following option:
20131
20132       planes
20133           Set which planes will be processed, unprocessed planes will be
20134           copied.  By default value 0xf, all planes will be processed.
20135
20136           If the format has 1 or 2 components, then luma is bit 0.  If the
20137           format has 3 or 4 components: for RGB formats bit 0 is green, bit 1
20138           is blue and bit 2 is red; for YUV formats bit 0 is luma, bit 1 is
20139           chroma-U and bit 2 is chroma-V.  If present, the alpha channel is
20140           always the last bit.
20141
20142       inplace
20143           Do not require 2nd input for processing, instead use alpha plane
20144           from input stream.
20145
20146   unsharp
20147       Sharpen or blur the input video.
20148
20149       It accepts the following parameters:
20150
20151       luma_msize_x, lx
20152           Set the luma matrix horizontal size. It must be an odd integer
20153           between 3 and 23. The default value is 5.
20154
20155       luma_msize_y, ly
20156           Set the luma matrix vertical size. It must be an odd integer
20157           between 3 and 23. The default value is 5.
20158
20159       luma_amount, la
20160           Set the luma effect strength. It must be a floating point number,
20161           reasonable values lay between -1.5 and 1.5.
20162
20163           Negative values will blur the input video, while positive values
20164           will sharpen it, a value of zero will disable the effect.
20165
20166           Default value is 1.0.
20167
20168       chroma_msize_x, cx
20169           Set the chroma matrix horizontal size. It must be an odd integer
20170           between 3 and 23. The default value is 5.
20171
20172       chroma_msize_y, cy
20173           Set the chroma matrix vertical size. It must be an odd integer
20174           between 3 and 23. The default value is 5.
20175
20176       chroma_amount, ca
20177           Set the chroma effect strength. It must be a floating point number,
20178           reasonable values lay between -1.5 and 1.5.
20179
20180           Negative values will blur the input video, while positive values
20181           will sharpen it, a value of zero will disable the effect.
20182
20183           Default value is 0.0.
20184
20185       alpha_msize_x, ax
20186           Set the alpha matrix horizontal size. It must be an odd integer
20187           between 3 and 23. The default value is 5.
20188
20189       alpha_msize_y, ay
20190           Set the alpha matrix vertical size. It must be an odd integer
20191           between 3 and 23. The default value is 5.
20192
20193       alpha_amount, aa
20194           Set the alpha effect strength. It must be a floating point number,
20195           reasonable values lay between -1.5 and 1.5.
20196
20197           Negative values will blur the input video, while positive values
20198           will sharpen it, a value of zero will disable the effect.
20199
20200           Default value is 0.0.
20201
20202       All parameters are optional and default to the equivalent of the string
20203       '5:5:1.0:5:5:0.0'.
20204
20205       Examples
20206
20207       •   Apply strong luma sharpen effect:
20208
20209                   unsharp=luma_msize_x=7:luma_msize_y=7:luma_amount=2.5
20210
20211       •   Apply a strong blur of both luma and chroma parameters:
20212
20213                   unsharp=7:7:-2:7:7:-2
20214
20215   untile
20216       Decompose a video made of tiled images into the individual images.
20217
20218       The frame rate of the output video is the frame rate of the input video
20219       multiplied by the number of tiles.
20220
20221       This filter does the reverse of tile.
20222
20223       The filter accepts the following options:
20224
20225       layout
20226           Set the grid size (i.e. the number of lines and columns). For the
20227           syntax of this option, check the "Video size" section in the
20228           ffmpeg-utils manual.
20229
20230       Examples
20231
20232       •   Produce a 1-second video from a still image file made of 25 frames
20233           stacked vertically, like an analogic film reel:
20234
20235                   ffmpeg -r 1 -i image.jpg -vf untile=1x25 movie.mkv
20236
20237   uspp
20238       Apply ultra slow/simple postprocessing filter that compresses and
20239       decompresses the image at several (or - in the case of quality level 8
20240       - all) shifts and average the results.
20241
20242       The way this differs from the behavior of spp is that uspp actually
20243       encodes & decodes each case with libavcodec Snow, whereas spp uses a
20244       simplified intra only 8x8 DCT similar to MJPEG.
20245
20246       This filter is only available in ffmpeg version 4.4 or earlier.
20247
20248       The filter accepts the following options:
20249
20250       quality
20251           Set quality. This option defines the number of levels for
20252           averaging. It accepts an integer in the range 0-8. If set to 0, the
20253           filter will have no effect. A value of 8 means the higher quality.
20254           For each increment of that value the speed drops by a factor of
20255           approximately 2.  Default value is 3.
20256
20257       qp  Force a constant quantization parameter. If not set, the filter
20258           will use the QP from the video stream (if available).
20259
20260   v360
20261       Convert 360 videos between various formats.
20262
20263       The filter accepts the following options:
20264
20265       input
20266       output
20267           Set format of the input/output video.
20268
20269           Available formats:
20270
20271           e
20272           equirect
20273               Equirectangular projection.
20274
20275           c3x2
20276           c6x1
20277           c1x6
20278               Cubemap with 3x2/6x1/1x6 layout.
20279
20280               Format specific options:
20281
20282               in_pad
20283               out_pad
20284                   Set padding proportion for the input/output cubemap. Values
20285                   in decimals.
20286
20287                   Example values:
20288
20289                   0   No padding.
20290
20291                   0.01
20292                       1% of face is padding. For example, with 1920x1280
20293                       resolution face size would be 640x640 and padding would
20294                       be 3 pixels from each side. (640 * 0.01 = 6 pixels)
20295
20296                   Default value is @samp{0}.  Maximum value is @samp{0.1}.
20297
20298               fin_pad
20299               fout_pad
20300                   Set fixed padding for the input/output cubemap. Values in
20301                   pixels.
20302
20303                   Default value is @samp{0}. If greater than zero it
20304                   overrides other padding options.
20305
20306               in_forder
20307               out_forder
20308                   Set order of faces for the input/output cubemap. Choose one
20309                   direction for each position.
20310
20311                   Designation of directions:
20312
20313                   r   right
20314
20315                   l   left
20316
20317                   u   up
20318
20319                   d   down
20320
20321                   f   forward
20322
20323                   b   back
20324
20325                   Default value is @samp{rludfb}.
20326
20327               in_frot
20328               out_frot
20329                   Set rotation of faces for the input/output cubemap. Choose
20330                   one angle for each position.
20331
20332                   Designation of angles:
20333
20334                   0   0 degrees clockwise
20335
20336                   1   90 degrees clockwise
20337
20338                   2   180 degrees clockwise
20339
20340                   3   270 degrees clockwise
20341
20342                   Default value is @samp{000000}.
20343
20344           eac Equi-Angular Cubemap.
20345
20346           flat
20347           gnomonic
20348           rectilinear
20349               Regular video.
20350
20351               Format specific options:
20352
20353               h_fov
20354               v_fov
20355               d_fov
20356                   Set output horizontal/vertical/diagonal field of view.
20357                   Values in degrees.
20358
20359                   If diagonal field of view is set it overrides horizontal
20360                   and vertical field of view.
20361
20362               ih_fov
20363               iv_fov
20364               id_fov
20365                   Set input horizontal/vertical/diagonal field of view.
20366                   Values in degrees.
20367
20368                   If diagonal field of view is set it overrides horizontal
20369                   and vertical field of view.
20370
20371           dfisheye
20372               Dual fisheye.
20373
20374               Format specific options:
20375
20376               h_fov
20377               v_fov
20378               d_fov
20379                   Set output horizontal/vertical/diagonal field of view.
20380                   Values in degrees.
20381
20382                   If diagonal field of view is set it overrides horizontal
20383                   and vertical field of view.
20384
20385               ih_fov
20386               iv_fov
20387               id_fov
20388                   Set input horizontal/vertical/diagonal field of view.
20389                   Values in degrees.
20390
20391                   If diagonal field of view is set it overrides horizontal
20392                   and vertical field of view.
20393
20394           barrel
20395           fb
20396           barrelsplit
20397               Facebook's 360 formats.
20398
20399           sg  Stereographic format.
20400
20401               Format specific options:
20402
20403               h_fov
20404               v_fov
20405               d_fov
20406                   Set output horizontal/vertical/diagonal field of view.
20407                   Values in degrees.
20408
20409                   If diagonal field of view is set it overrides horizontal
20410                   and vertical field of view.
20411
20412               ih_fov
20413               iv_fov
20414               id_fov
20415                   Set input horizontal/vertical/diagonal field of view.
20416                   Values in degrees.
20417
20418                   If diagonal field of view is set it overrides horizontal
20419                   and vertical field of view.
20420
20421           mercator
20422               Mercator format.
20423
20424           ball
20425               Ball format, gives significant distortion toward the back.
20426
20427           hammer
20428               Hammer-Aitoff map projection format.
20429
20430           sinusoidal
20431               Sinusoidal map projection format.
20432
20433           fisheye
20434               Fisheye projection.
20435
20436               Format specific options:
20437
20438               h_fov
20439               v_fov
20440               d_fov
20441                   Set output horizontal/vertical/diagonal field of view.
20442                   Values in degrees.
20443
20444                   If diagonal field of view is set it overrides horizontal
20445                   and vertical field of view.
20446
20447               ih_fov
20448               iv_fov
20449               id_fov
20450                   Set input horizontal/vertical/diagonal field of view.
20451                   Values in degrees.
20452
20453                   If diagonal field of view is set it overrides horizontal
20454                   and vertical field of view.
20455
20456           pannini
20457               Pannini projection.
20458
20459               Format specific options:
20460
20461               h_fov
20462                   Set output pannini parameter.
20463
20464               ih_fov
20465                   Set input pannini parameter.
20466
20467           cylindrical
20468               Cylindrical projection.
20469
20470               Format specific options:
20471
20472               h_fov
20473               v_fov
20474               d_fov
20475                   Set output horizontal/vertical/diagonal field of view.
20476                   Values in degrees.
20477
20478                   If diagonal field of view is set it overrides horizontal
20479                   and vertical field of view.
20480
20481               ih_fov
20482               iv_fov
20483               id_fov
20484                   Set input horizontal/vertical/diagonal field of view.
20485                   Values in degrees.
20486
20487                   If diagonal field of view is set it overrides horizontal
20488                   and vertical field of view.
20489
20490           perspective
20491               Perspective projection. (output only)
20492
20493               Format specific options:
20494
20495               v_fov
20496                   Set perspective parameter.
20497
20498           tetrahedron
20499               Tetrahedron projection.
20500
20501           tsp Truncated square pyramid projection.
20502
20503           he
20504           hequirect
20505               Half equirectangular projection.
20506
20507           equisolid
20508               Equisolid format.
20509
20510               Format specific options:
20511
20512               h_fov
20513               v_fov
20514               d_fov
20515                   Set output horizontal/vertical/diagonal field of view.
20516                   Values in degrees.
20517
20518                   If diagonal field of view is set it overrides horizontal
20519                   and vertical field of view.
20520
20521               ih_fov
20522               iv_fov
20523               id_fov
20524                   Set input horizontal/vertical/diagonal field of view.
20525                   Values in degrees.
20526
20527                   If diagonal field of view is set it overrides horizontal
20528                   and vertical field of view.
20529
20530           og  Orthographic format.
20531
20532               Format specific options:
20533
20534               h_fov
20535               v_fov
20536               d_fov
20537                   Set output horizontal/vertical/diagonal field of view.
20538                   Values in degrees.
20539
20540                   If diagonal field of view is set it overrides horizontal
20541                   and vertical field of view.
20542
20543               ih_fov
20544               iv_fov
20545               id_fov
20546                   Set input horizontal/vertical/diagonal field of view.
20547                   Values in degrees.
20548
20549                   If diagonal field of view is set it overrides horizontal
20550                   and vertical field of view.
20551
20552           octahedron
20553               Octahedron projection.
20554
20555           cylindricalea
20556               Cylindrical Equal Area projection.
20557
20558       interp
20559           Set interpolation method.Note: more complex interpolation methods
20560           require much more memory to run.
20561
20562           Available methods:
20563
20564           near
20565           nearest
20566               Nearest neighbour.
20567
20568           line
20569           linear
20570               Bilinear interpolation.
20571
20572           lagrange9
20573               Lagrange9 interpolation.
20574
20575           cube
20576           cubic
20577               Bicubic interpolation.
20578
20579           lanc
20580           lanczos
20581               Lanczos interpolation.
20582
20583           sp16
20584           spline16
20585               Spline16 interpolation.
20586
20587           gauss
20588           gaussian
20589               Gaussian interpolation.
20590
20591           mitchell
20592               Mitchell interpolation.
20593
20594           Default value is @samp{line}.
20595
20596       w
20597       h   Set the output video resolution.
20598
20599           Default resolution depends on formats.
20600
20601       in_stereo
20602       out_stereo
20603           Set the input/output stereo format.
20604
20605           2d  2D mono
20606
20607           sbs Side by side
20608
20609           tb  Top bottom
20610
20611           Default value is @samp{2d} for input and output format.
20612
20613       yaw
20614       pitch
20615       roll
20616           Set rotation for the output video. Values in degrees.
20617
20618       rorder
20619           Set rotation order for the output video. Choose one item for each
20620           position.
20621
20622           y, Y
20623               yaw
20624
20625           p, P
20626               pitch
20627
20628           r, R
20629               roll
20630
20631           Default value is @samp{ypr}.
20632
20633       h_flip
20634       v_flip
20635       d_flip
20636           Flip the output video horizontally(swaps
20637           left-right)/vertically(swaps up-down)/in-depth(swaps back-forward).
20638           Boolean values.
20639
20640       ih_flip
20641       iv_flip
20642           Set if input video is flipped horizontally/vertically. Boolean
20643           values.
20644
20645       in_trans
20646           Set if input video is transposed. Boolean value, by default
20647           disabled.
20648
20649       out_trans
20650           Set if output video needs to be transposed. Boolean value, by
20651           default disabled.
20652
20653       h_offset
20654       v_offset
20655           Set output horizontal/vertical off-axis offset. Default is set to
20656           0.  Allowed range is from -1 to 1.
20657
20658       alpha_mask
20659           Build mask in alpha plane for all unmapped pixels by marking them
20660           fully transparent. Boolean value, by default disabled.
20661
20662       reset_rot
20663           Reset rotation of output video. Boolean value, by default disabled.
20664
20665       Examples
20666
20667       •   Convert equirectangular video to cubemap with 3x2 layout and 1%
20668           padding using bicubic interpolation:
20669
20670                   ffmpeg -i input.mkv -vf v360=e:c3x2:cubic:out_pad=0.01 output.mkv
20671
20672       •   Extract back view of Equi-Angular Cubemap:
20673
20674                   ffmpeg -i input.mkv -vf v360=eac:flat:yaw=180 output.mkv
20675
20676       •   Convert transposed and horizontally flipped Equi-Angular Cubemap in
20677           side-by-side stereo format to equirectangular top-bottom stereo
20678           format:
20679
20680                   v360=eac:equirect:in_stereo=sbs:in_trans=1:ih_flip=1:out_stereo=tb
20681
20682       Commands
20683
20684       This filter supports subset of above options as commands.
20685
20686   vaguedenoiser
20687       Apply a wavelet based denoiser.
20688
20689       It transforms each frame from the video input into the wavelet domain,
20690       using Cohen-Daubechies-Feauveau 9/7. Then it applies some filtering to
20691       the obtained coefficients. It does an inverse wavelet transform after.
20692       Due to wavelet properties, it should give a nice smoothed result, and
20693       reduced noise, without blurring picture features.
20694
20695       This filter accepts the following options:
20696
20697       threshold
20698           The filtering strength. The higher, the more filtered the video
20699           will be.  Hard thresholding can use a higher threshold than soft
20700           thresholding before the video looks overfiltered. Default value is
20701           2.
20702
20703       method
20704           The filtering method the filter will use.
20705
20706           It accepts the following values:
20707
20708           hard
20709               All values under the threshold will be zeroed.
20710
20711           soft
20712               All values under the threshold will be zeroed. All values above
20713               will be reduced by the threshold.
20714
20715           garrote
20716               Scales or nullifies coefficients - intermediary between (more)
20717               soft and (less) hard thresholding.
20718
20719           Default is garrote.
20720
20721       nsteps
20722           Number of times, the wavelet will decompose the picture. Picture
20723           can't be decomposed beyond a particular point (typically, 8 for a
20724           640x480 frame - as 2^9 = 512 > 480). Valid values are integers
20725           between 1 and 32. Default value is 6.
20726
20727       percent
20728           Partial of full denoising (limited coefficients shrinking), from 0
20729           to 100. Default value is 85.
20730
20731       planes
20732           A list of the planes to process. By default all planes are
20733           processed.
20734
20735       type
20736           The threshold type the filter will use.
20737
20738           It accepts the following values:
20739
20740           universal
20741               Threshold used is same for all decompositions.
20742
20743           bayes
20744               Threshold used depends also on each decomposition coefficients.
20745
20746           Default is universal.
20747
20748   varblur
20749       Apply variable blur filter by using 2nd video stream to set blur
20750       radius.  The 2nd stream must have the same dimensions.
20751
20752       This filter accepts the following options:
20753
20754       min_r
20755           Set min allowed radius. Allowed range is from 0 to 254. Default is
20756           0.
20757
20758       max_r
20759           Set max allowed radius. Allowed range is from 1 to 255. Default is
20760           8.
20761
20762       planes
20763           Set which planes to process. By default, all are used.
20764
20765       The "varblur" filter also supports the framesync options.
20766
20767       Commands
20768
20769       This filter supports all the above options as commands.
20770
20771   vectorscope
20772       Display 2 color component values in the two dimensional graph (which is
20773       called a vectorscope).
20774
20775       This filter accepts the following options:
20776
20777       mode, m
20778           Set vectorscope mode.
20779
20780           It accepts the following values:
20781
20782           gray
20783           tint
20784               Gray values are displayed on graph, higher brightness means
20785               more pixels have same component color value on location in
20786               graph. This is the default mode.
20787
20788           color
20789               Gray values are displayed on graph. Surrounding pixels values
20790               which are not present in video frame are drawn in gradient of 2
20791               color components which are set by option "x" and "y". The 3rd
20792               color component is static.
20793
20794           color2
20795               Actual color components values present in video frame are
20796               displayed on graph.
20797
20798           color3
20799               Similar as color2 but higher frequency of same values "x" and
20800               "y" on graph increases value of another color component, which
20801               is luminance by default values of "x" and "y".
20802
20803           color4
20804               Actual colors present in video frame are displayed on graph. If
20805               two different colors map to same position on graph then color
20806               with higher value of component not present in graph is picked.
20807
20808           color5
20809               Gray values are displayed on graph. Similar to "color" but with
20810               3rd color component picked from radial gradient.
20811
20812       x   Set which color component will be represented on X-axis. Default is
20813           1.
20814
20815       y   Set which color component will be represented on Y-axis. Default is
20816           2.
20817
20818       intensity, i
20819           Set intensity, used by modes: gray, color, color3 and color5 for
20820           increasing brightness of color component which represents frequency
20821           of (X, Y) location in graph.
20822
20823       envelope, e
20824           none
20825               No envelope, this is default.
20826
20827           instant
20828               Instant envelope, even darkest single pixel will be clearly
20829               highlighted.
20830
20831           peak
20832               Hold maximum and minimum values presented in graph over time.
20833               This way you can still spot out of range values without
20834               constantly looking at vectorscope.
20835
20836           peak+instant
20837               Peak and instant envelope combined together.
20838
20839       graticule, g
20840           Set what kind of graticule to draw.
20841
20842           none
20843           green
20844           color
20845           invert
20846       opacity, o
20847           Set graticule opacity.
20848
20849       flags, f
20850           Set graticule flags.
20851
20852           white
20853               Draw graticule for white point.
20854
20855           black
20856               Draw graticule for black point.
20857
20858           name
20859               Draw color points short names.
20860
20861       bgopacity, b
20862           Set background opacity.
20863
20864       lthreshold, l
20865           Set low threshold for color component not represented on X or Y
20866           axis.  Values lower than this value will be ignored. Default is 0.
20867           Note this value is multiplied with actual max possible value one
20868           pixel component can have. So for 8-bit input and low threshold
20869           value of 0.1 actual threshold is 0.1 * 255 = 25.
20870
20871       hthreshold, h
20872           Set high threshold for color component not represented on X or Y
20873           axis.  Values higher than this value will be ignored. Default is 1.
20874           Note this value is multiplied with actual max possible value one
20875           pixel component can have. So for 8-bit input and high threshold
20876           value of 0.9 actual threshold is 0.9 * 255 = 230.
20877
20878       colorspace, c
20879           Set what kind of colorspace to use when drawing graticule.
20880
20881           auto
20882           601
20883           709
20884
20885           Default is auto.
20886
20887       tint0, t0
20888       tint1, t1
20889           Set color tint for gray/tint vectorscope mode. By default both
20890           options are zero.  This means no tint, and output will remain gray.
20891
20892   vidstabdetect
20893       Analyze video stabilization/deshaking. Perform pass 1 of 2, see
20894       vidstabtransform for pass 2.
20895
20896       This filter generates a file with relative translation and rotation
20897       transform information about subsequent frames, which is then used by
20898       the vidstabtransform filter.
20899
20900       To enable compilation of this filter you need to configure FFmpeg with
20901       "--enable-libvidstab".
20902
20903       This filter accepts the following options:
20904
20905       result
20906           Set the path to the file used to write the transforms information.
20907           Default value is transforms.trf.
20908
20909       shakiness
20910           Set how shaky the video is and how quick the camera is. It accepts
20911           an integer in the range 1-10, a value of 1 means little shakiness,
20912           a value of 10 means strong shakiness. Default value is 5.
20913
20914       accuracy
20915           Set the accuracy of the detection process. It must be a value in
20916           the range 1-15. A value of 1 means low accuracy, a value of 15
20917           means high accuracy. Default value is 15.
20918
20919       stepsize
20920           Set stepsize of the search process. The region around minimum is
20921           scanned with 1 pixel resolution. Default value is 6.
20922
20923       mincontrast
20924           Set minimum contrast. Below this value a local measurement field is
20925           discarded. Must be a floating point value in the range 0-1. Default
20926           value is 0.3.
20927
20928       tripod
20929           Set reference frame number for tripod mode.
20930
20931           If enabled, the motion of the frames is compared to a reference
20932           frame in the filtered stream, identified by the specified number.
20933           The idea is to compensate all movements in a more-or-less static
20934           scene and keep the camera view absolutely still.
20935
20936           If set to 0, it is disabled. The frames are counted starting from
20937           1.
20938
20939       show
20940           Show fields and transforms in the resulting frames. It accepts an
20941           integer in the range 0-2. Default value is 0, which disables any
20942           visualization.
20943
20944       Examples
20945
20946       •   Use default values:
20947
20948                   vidstabdetect
20949
20950       •   Analyze strongly shaky movie and put the results in file
20951           mytransforms.trf:
20952
20953                   vidstabdetect=shakiness=10:accuracy=15:result="mytransforms.trf"
20954
20955       •   Visualize the result of internal transformations in the resulting
20956           video:
20957
20958                   vidstabdetect=show=1
20959
20960       •   Analyze a video with medium shakiness using ffmpeg:
20961
20962                   ffmpeg -i input -vf vidstabdetect=shakiness=5:show=1 dummy.avi
20963
20964   vidstabtransform
20965       Video stabilization/deshaking: pass 2 of 2, see vidstabdetect for pass
20966       1.
20967
20968       Read a file with transform information for each frame and
20969       apply/compensate them. Together with the vidstabdetect filter this can
20970       be used to deshake videos. See also
20971       <http://public.hronopik.de/vid.stab>. It is important to also use the
20972       unsharp filter, see below.
20973
20974       To enable compilation of this filter you need to configure FFmpeg with
20975       "--enable-libvidstab".
20976
20977       Options
20978
20979       input
20980           Set path to the file used to read the transforms. Default value is
20981           transforms.trf.
20982
20983       smoothing
20984           Set the number of frames (value*2 + 1) used for lowpass filtering
20985           the camera movements. Default value is 10.
20986
20987           For example a number of 10 means that 21 frames are used (10 in the
20988           past and 10 in the future) to smoothen the motion in the video. A
20989           larger value leads to a smoother video, but limits the acceleration
20990           of the camera (pan/tilt movements). 0 is a special case where a
20991           static camera is simulated.
20992
20993       optalgo
20994           Set the camera path optimization algorithm.
20995
20996           Accepted values are:
20997
20998           gauss
20999               gaussian kernel low-pass filter on camera motion (default)
21000
21001           avg averaging on transformations
21002
21003       maxshift
21004           Set maximal number of pixels to translate frames. Default value is
21005           -1, meaning no limit.
21006
21007       maxangle
21008           Set maximal angle in radians (degree*PI/180) to rotate frames.
21009           Default value is -1, meaning no limit.
21010
21011       crop
21012           Specify how to deal with borders that may be visible due to
21013           movement compensation.
21014
21015           Available values are:
21016
21017           keep
21018               keep image information from previous frame (default)
21019
21020           black
21021               fill the border black
21022
21023       invert
21024           Invert transforms if set to 1. Default value is 0.
21025
21026       relative
21027           Consider transforms as relative to previous frame if set to 1,
21028           absolute if set to 0. Default value is 0.
21029
21030       zoom
21031           Set percentage to zoom. A positive value will result in a zoom-in
21032           effect, a negative value in a zoom-out effect. Default value is 0
21033           (no zoom).
21034
21035       optzoom
21036           Set optimal zooming to avoid borders.
21037
21038           Accepted values are:
21039
21040           0   disabled
21041
21042           1   optimal static zoom value is determined (only very strong
21043               movements will lead to visible borders) (default)
21044
21045           2   optimal adaptive zoom value is determined (no borders will be
21046               visible), see zoomspeed
21047
21048           Note that the value given at zoom is added to the one calculated
21049           here.
21050
21051       zoomspeed
21052           Set percent to zoom maximally each frame (enabled when optzoom is
21053           set to 2). Range is from 0 to 5, default value is 0.25.
21054
21055       interpol
21056           Specify type of interpolation.
21057
21058           Available values are:
21059
21060           no  no interpolation
21061
21062           linear
21063               linear only horizontal
21064
21065           bilinear
21066               linear in both directions (default)
21067
21068           bicubic
21069               cubic in both directions (slow)
21070
21071       tripod
21072           Enable virtual tripod mode if set to 1, which is equivalent to
21073           "relative=0:smoothing=0". Default value is 0.
21074
21075           Use also "tripod" option of vidstabdetect.
21076
21077       debug
21078           Increase log verbosity if set to 1. Also the detected global
21079           motions are written to the temporary file global_motions.trf.
21080           Default value is 0.
21081
21082       Examples
21083
21084       •   Use ffmpeg for a typical stabilization with default values:
21085
21086                   ffmpeg -i inp.mpeg -vf vidstabtransform,unsharp=5:5:0.8:3:3:0.4 inp_stabilized.mpeg
21087
21088           Note the use of the unsharp filter which is always recommended.
21089
21090       •   Zoom in a bit more and load transform data from a given file:
21091
21092                   vidstabtransform=zoom=5:input="mytransforms.trf"
21093
21094       •   Smoothen the video even more:
21095
21096                   vidstabtransform=smoothing=30
21097
21098   vflip
21099       Flip the input video vertically.
21100
21101       For example, to vertically flip a video with ffmpeg:
21102
21103               ffmpeg -i in.avi -vf "vflip" out.avi
21104
21105   vfrdet
21106       Detect variable frame rate video.
21107
21108       This filter tries to detect if the input is variable or constant frame
21109       rate.
21110
21111       At end it will output number of frames detected as having variable
21112       delta pts, and ones with constant delta pts.  If there was frames with
21113       variable delta, than it will also show min, max and average delta
21114       encountered.
21115
21116   vibrance
21117       Boost or alter saturation.
21118
21119       The filter accepts the following options:
21120
21121       intensity
21122           Set strength of boost if positive value or strength of alter if
21123           negative value.  Default is 0. Allowed range is from -2 to 2.
21124
21125       rbal
21126           Set the red balance. Default is 1. Allowed range is from -10 to 10.
21127
21128       gbal
21129           Set the green balance. Default is 1. Allowed range is from -10 to
21130           10.
21131
21132       bbal
21133           Set the blue balance. Default is 1. Allowed range is from -10 to
21134           10.
21135
21136       rlum
21137           Set the red luma coefficient.
21138
21139       glum
21140           Set the green luma coefficient.
21141
21142       blum
21143           Set the blue luma coefficient.
21144
21145       alternate
21146           If "intensity" is negative and this is set to 1, colors will
21147           change, otherwise colors will be less saturated, more towards gray.
21148
21149       Commands
21150
21151       This filter supports the all above options as commands.
21152
21153   vif
21154       Obtain the average VIF (Visual Information Fidelity) between two input
21155       videos.
21156
21157       This filter takes two input videos.
21158
21159       Both input videos must have the same resolution and pixel format for
21160       this filter to work correctly. Also it assumes that both inputs have
21161       the same number of frames, which are compared one by one.
21162
21163       The obtained average VIF score is printed through the logging system.
21164
21165       The filter stores the calculated VIF score of each frame.
21166
21167       In the below example the input file main.mpg being processed is
21168       compared with the reference file ref.mpg.
21169
21170               ffmpeg -i main.mpg -i ref.mpg -lavfi vif -f null -
21171
21172   vignette
21173       Make or reverse a natural vignetting effect.
21174
21175       The filter accepts the following options:
21176
21177       angle, a
21178           Set lens angle expression as a number of radians.
21179
21180           The value is clipped in the "[0,PI/2]" range.
21181
21182           Default value: "PI/5"
21183
21184       x0
21185       y0  Set center coordinates expressions. Respectively "w/2" and "h/2" by
21186           default.
21187
21188       mode
21189           Set forward/backward mode.
21190
21191           Available modes are:
21192
21193           forward
21194               The larger the distance from the central point, the darker the
21195               image becomes.
21196
21197           backward
21198               The larger the distance from the central point, the brighter
21199               the image becomes.  This can be used to reverse a vignette
21200               effect, though there is no automatic detection to extract the
21201               lens angle and other settings (yet). It can also be used to
21202               create a burning effect.
21203
21204           Default value is forward.
21205
21206       eval
21207           Set evaluation mode for the expressions (angle, x0, y0).
21208
21209           It accepts the following values:
21210
21211           init
21212               Evaluate expressions only once during the filter
21213               initialization.
21214
21215           frame
21216               Evaluate expressions for each incoming frame. This is way
21217               slower than the init mode since it requires all the scalers to
21218               be re-computed, but it allows advanced dynamic expressions.
21219
21220           Default value is init.
21221
21222       dither
21223           Set dithering to reduce the circular banding effects. Default is 1
21224           (enabled).
21225
21226       aspect
21227           Set vignette aspect. This setting allows one to adjust the shape of
21228           the vignette.  Setting this value to the SAR of the input will make
21229           a rectangular vignetting following the dimensions of the video.
21230
21231           Default is "1/1".
21232
21233       Expressions
21234
21235       The alpha, x0 and y0 expressions can contain the following parameters.
21236
21237       w
21238       h   input width and height
21239
21240       n   the number of input frame, starting from 0
21241
21242       pts the PTS (Presentation TimeStamp) time of the filtered video frame,
21243           expressed in TB units, NAN if undefined
21244
21245       r   frame rate of the input video, NAN if the input frame rate is
21246           unknown
21247
21248       t   the PTS (Presentation TimeStamp) of the filtered video frame,
21249           expressed in seconds, NAN if undefined
21250
21251       tb  time base of the input video
21252
21253       Examples
21254
21255       •   Apply simple strong vignetting effect:
21256
21257                   vignette=PI/4
21258
21259       •   Make a flickering vignetting:
21260
21261                   vignette='PI/4+random(1)*PI/50':eval=frame
21262
21263   vmafmotion
21264       Obtain the average VMAF motion score of a video.  It is one of the
21265       component metrics of VMAF.
21266
21267       The obtained average motion score is printed through the logging
21268       system.
21269
21270       The filter accepts the following options:
21271
21272       stats_file
21273           If specified, the filter will use the named file to save the motion
21274           score of each frame with respect to the previous frame.  When
21275           filename equals "-" the data is sent to standard output.
21276
21277       Example:
21278
21279               ffmpeg -i ref.mpg -vf vmafmotion -f null -
21280
21281   vstack
21282       Stack input videos vertically.
21283
21284       All streams must be of same pixel format and of same width.
21285
21286       Note that this filter is faster than using overlay and pad filter to
21287       create same output.
21288
21289       The filter accepts the following options:
21290
21291       inputs
21292           Set number of input streams. Default is 2.
21293
21294       shortest
21295           If set to 1, force the output to terminate when the shortest input
21296           terminates. Default value is 0.
21297
21298   w3fdif
21299       Deinterlace the input video ("w3fdif" stands for "Weston 3 Field
21300       Deinterlacing Filter").
21301
21302       Based on the process described by Martin Weston for BBC R&D, and
21303       implemented based on the de-interlace algorithm written by Jim
21304       Easterbrook for BBC R&D, the Weston 3 field deinterlacing filter uses
21305       filter coefficients calculated by BBC R&D.
21306
21307       This filter uses field-dominance information in frame to decide which
21308       of each pair of fields to place first in the output.  If it gets it
21309       wrong use setfield filter before "w3fdif" filter.
21310
21311       There are two sets of filter coefficients, so called "simple" and
21312       "complex". Which set of filter coefficients is used can be set by
21313       passing an optional parameter:
21314
21315       filter
21316           Set the interlacing filter coefficients. Accepts one of the
21317           following values:
21318
21319           simple
21320               Simple filter coefficient set.
21321
21322           complex
21323               More-complex filter coefficient set.
21324
21325           Default value is complex.
21326
21327       mode
21328           The interlacing mode to adopt. It accepts one of the following
21329           values:
21330
21331           frame
21332               Output one frame for each frame.
21333
21334           field
21335               Output one frame for each field.
21336
21337           The default value is "field".
21338
21339       parity
21340           The picture field parity assumed for the input interlaced video. It
21341           accepts one of the following values:
21342
21343           tff Assume the top field is first.
21344
21345           bff Assume the bottom field is first.
21346
21347           auto
21348               Enable automatic detection of field parity.
21349
21350           The default value is "auto".  If the interlacing is unknown or the
21351           decoder does not export this information, top field first will be
21352           assumed.
21353
21354       deint
21355           Specify which frames to deinterlace. Accepts one of the following
21356           values:
21357
21358           all Deinterlace all frames,
21359
21360           interlaced
21361               Only deinterlace frames marked as interlaced.
21362
21363           Default value is all.
21364
21365       Commands
21366
21367       This filter supports same commands as options.
21368
21369   waveform
21370       Video waveform monitor.
21371
21372       The waveform monitor plots color component intensity. By default
21373       luminance only. Each column of the waveform corresponds to a column of
21374       pixels in the source video.
21375
21376       It accepts the following options:
21377
21378       mode, m
21379           Can be either "row", or "column". Default is "column".  In row
21380           mode, the graph on the left side represents color component value 0
21381           and the right side represents value = 255. In column mode, the top
21382           side represents color component value = 0 and bottom side
21383           represents value = 255.
21384
21385       intensity, i
21386           Set intensity. Smaller values are useful to find out how many
21387           values of the same luminance are distributed across input
21388           rows/columns.  Default value is 0.04. Allowed range is [0, 1].
21389
21390       mirror, r
21391           Set mirroring mode. 0 means unmirrored, 1 means mirrored.  In
21392           mirrored mode, higher values will be represented on the left side
21393           for "row" mode and at the top for "column" mode. Default is 1
21394           (mirrored).
21395
21396       display, d
21397           Set display mode.  It accepts the following values:
21398
21399           overlay
21400               Presents information identical to that in the "parade", except
21401               that the graphs representing color components are superimposed
21402               directly over one another.
21403
21404               This display mode makes it easier to spot relative differences
21405               or similarities in overlapping areas of the color components
21406               that are supposed to be identical, such as neutral whites,
21407               grays, or blacks.
21408
21409           stack
21410               Display separate graph for the color components side by side in
21411               "row" mode or one below the other in "column" mode.
21412
21413           parade
21414               Display separate graph for the color components side by side in
21415               "column" mode or one below the other in "row" mode.
21416
21417               Using this display mode makes it easy to spot color casts in
21418               the highlights and shadows of an image, by comparing the
21419               contours of the top and the bottom graphs of each waveform.
21420               Since whites, grays, and blacks are characterized by exactly
21421               equal amounts of red, green, and blue, neutral areas of the
21422               picture should display three waveforms of roughly equal
21423               width/height. If not, the correction is easy to perform by
21424               making level adjustments the three waveforms.
21425
21426           Default is "stack".
21427
21428       components, c
21429           Set which color components to display. Default is 1, which means
21430           only luminance or red color component if input is in RGB
21431           colorspace. If is set for example to 7 it will display all 3 (if)
21432           available color components.
21433
21434       envelope, e
21435           none
21436               No envelope, this is default.
21437
21438           instant
21439               Instant envelope, minimum and maximum values presented in graph
21440               will be easily visible even with small "step" value.
21441
21442           peak
21443               Hold minimum and maximum values presented in graph across time.
21444               This way you can still spot out of range values without
21445               constantly looking at waveforms.
21446
21447           peak+instant
21448               Peak and instant envelope combined together.
21449
21450       filter, f
21451           lowpass
21452               No filtering, this is default.
21453
21454           flat
21455               Luma and chroma combined together.
21456
21457           aflat
21458               Similar as above, but shows difference between blue and red
21459               chroma.
21460
21461           xflat
21462               Similar as above, but use different colors.
21463
21464           yflat
21465               Similar as above, but again with different colors.
21466
21467           chroma
21468               Displays only chroma.
21469
21470           color
21471               Displays actual color value on waveform.
21472
21473           acolor
21474               Similar as above, but with luma showing frequency of chroma
21475               values.
21476
21477       graticule, g
21478           Set which graticule to display.
21479
21480           none
21481               Do not display graticule.
21482
21483           green
21484               Display green graticule showing legal broadcast ranges.
21485
21486           orange
21487               Display orange graticule showing legal broadcast ranges.
21488
21489           invert
21490               Display invert graticule showing legal broadcast ranges.
21491
21492       opacity, o
21493           Set graticule opacity.
21494
21495       flags, fl
21496           Set graticule flags.
21497
21498           numbers
21499               Draw numbers above lines. By default enabled.
21500
21501           dots
21502               Draw dots instead of lines.
21503
21504       scale, s
21505           Set scale used for displaying graticule.
21506
21507           digital
21508           millivolts
21509           ire
21510
21511           Default is digital.
21512
21513       bgopacity, b
21514           Set background opacity.
21515
21516       tint0, t0
21517       tint1, t1
21518           Set tint for output.  Only used with lowpass filter and when
21519           display is not overlay and input pixel formats are not RGB.
21520
21521       fitmode, fm
21522           Set sample aspect ratio of video output frames.  Can be used to
21523           configure waveform so it is not streched too much in one of
21524           directions.
21525
21526           none
21527               Set sample aspect ration to 1/1.
21528
21529           size
21530               Set sample aspect ratio to match input size of video
21531
21532           Default is none.
21533
21534   weave, doubleweave
21535       The "weave" takes a field-based video input and join each two
21536       sequential fields into single frame, producing a new double height clip
21537       with half the frame rate and half the frame count.
21538
21539       The "doubleweave" works same as "weave" but without halving frame rate
21540       and frame count.
21541
21542       It accepts the following option:
21543
21544       first_field
21545           Set first field. Available values are:
21546
21547           top, t
21548               Set the frame as top-field-first.
21549
21550           bottom, b
21551               Set the frame as bottom-field-first.
21552
21553       Examples
21554
21555       •   Interlace video using select and separatefields filter:
21556
21557                   separatefields,select=eq(mod(n,4),0)+eq(mod(n,4),3),weave
21558
21559   xbr
21560       Apply the xBR high-quality magnification filter which is designed for
21561       pixel art. It follows a set of edge-detection rules, see
21562       <https://forums.libretro.com/t/xbr-algorithm-tutorial/123>.
21563
21564       It accepts the following option:
21565
21566       n   Set the scaling dimension: 2 for "2xBR", 3 for "3xBR" and 4 for
21567           "4xBR".  Default is 3.
21568
21569   xcorrelate
21570       Apply normalized cross-correlation between first and second input video
21571       stream.
21572
21573       Second input video stream dimensions must be lower than first input
21574       video stream.
21575
21576       The filter accepts the following options:
21577
21578       planes
21579           Set which planes to process.
21580
21581       secondary
21582           Set which secondary video frames will be processed from second
21583           input video stream, can be first or all. Default is all.
21584
21585       The "xcorrelate" filter also supports the framesync options.
21586
21587   xfade
21588       Apply cross fade from one input video stream to another input video
21589       stream.  The cross fade is applied for specified duration.
21590
21591       Both inputs must be constant frame-rate and have the same resolution,
21592       pixel format, frame rate and timebase.
21593
21594       The filter accepts the following options:
21595
21596       transition
21597           Set one of available transition effects:
21598
21599           custom
21600           fade
21601           wipeleft
21602           wiperight
21603           wipeup
21604           wipedown
21605           slideleft
21606           slideright
21607           slideup
21608           slidedown
21609           circlecrop
21610           rectcrop
21611           distance
21612           fadeblack
21613           fadewhite
21614           radial
21615           smoothleft
21616           smoothright
21617           smoothup
21618           smoothdown
21619           circleopen
21620           circleclose
21621           vertopen
21622           vertclose
21623           horzopen
21624           horzclose
21625           dissolve
21626           pixelize
21627           diagtl
21628           diagtr
21629           diagbl
21630           diagbr
21631           hlslice
21632           hrslice
21633           vuslice
21634           vdslice
21635           hblur
21636           fadegrays
21637           wipetl
21638           wipetr
21639           wipebl
21640           wipebr
21641           squeezeh
21642           squeezev
21643           zoomin
21644           fadefast
21645           fadeslow
21646
21647           Default transition effect is fade.
21648
21649       duration
21650           Set cross fade duration in seconds.  Range is 0 to 60 seconds.
21651           Default duration is 1 second.
21652
21653       offset
21654           Set cross fade start relative to first input stream in seconds.
21655           Default offset is 0.
21656
21657       expr
21658           Set expression for custom transition effect.
21659
21660           The expressions can use the following variables and functions:
21661
21662           X
21663           Y   The coordinates of the current sample.
21664
21665           W
21666           H   The width and height of the image.
21667
21668           P   Progress of transition effect.
21669
21670           PLANE
21671               Currently processed plane.
21672
21673           A   Return value of first input at current location and plane.
21674
21675           B   Return value of second input at current location and plane.
21676
21677           a0(x, y)
21678           a1(x, y)
21679           a2(x, y)
21680           a3(x, y)
21681               Return the value of the pixel at location (x,y) of the
21682               first/second/third/fourth component of first input.
21683
21684           b0(x, y)
21685           b1(x, y)
21686           b2(x, y)
21687           b3(x, y)
21688               Return the value of the pixel at location (x,y) of the
21689               first/second/third/fourth component of second input.
21690
21691       Examples
21692
21693       •   Cross fade from one input video to another input video, with fade
21694           transition and duration of transition of 2 seconds starting at
21695           offset of 5 seconds:
21696
21697                   ffmpeg -i first.mp4 -i second.mp4 -filter_complex xfade=transition=fade:duration=2:offset=5 output.mp4
21698
21699   xmedian
21700       Pick median pixels from several input videos.
21701
21702       The filter accepts the following options:
21703
21704       inputs
21705           Set number of inputs.  Default is 3. Allowed range is from 3 to
21706           255.  If number of inputs is even number, than result will be mean
21707           value between two median values.
21708
21709       planes
21710           Set which planes to filter. Default value is 15, by which all
21711           planes are processed.
21712
21713       percentile
21714           Set median percentile. Default value is 0.5.  Default value of 0.5
21715           will pick always median values, while 0 will pick minimum values,
21716           and 1 maximum values.
21717
21718       Commands
21719
21720       This filter supports all above options as commands, excluding option
21721       "inputs".
21722
21723   xstack
21724       Stack video inputs into custom layout.
21725
21726       All streams must be of same pixel format.
21727
21728       The filter accepts the following options:
21729
21730       inputs
21731           Set number of input streams. Default is 2.
21732
21733       layout
21734           Specify layout of inputs.  This option requires the desired layout
21735           configuration to be explicitly set by the user.  This sets position
21736           of each video input in output. Each input is separated by '|'.  The
21737           first number represents the column, and the second number
21738           represents the row.  Numbers start at 0 and are separated by '_'.
21739           Optionally one can use wX and hX, where X is video input from which
21740           to take width or height.  Multiple values can be used when
21741           separated by '+'. In such case values are summed together.
21742
21743           Note that if inputs are of different sizes gaps may appear, as not
21744           all of the output video frame will be filled. Similarly, videos can
21745           overlap each other if their position doesn't leave enough space for
21746           the full frame of adjoining videos.
21747
21748           For 2 inputs, a default layout of "0_0|w0_0" (equivalent to
21749           "grid=2x1") is set. In all other cases, a layout or a grid must be
21750           set by the user. Either "grid" or "layout" can be specified at a
21751           time.  Specifying both will result in an error.
21752
21753       grid
21754           Specify a fixed size grid of inputs.  This option is used to create
21755           a fixed size grid of the input streams. Set the grid size in the
21756           form "COLUMNSxROWS". There must be "ROWS * COLUMNS" input streams
21757           and they will be arranged as a grid with "ROWS" rows and "COLUMNS"
21758           columns. When using this option, each input stream within a row
21759           must have the same height and all the rows must have the same
21760           width.
21761
21762           If "grid" is set, then "inputs" option is ignored and is implicitly
21763           set to "ROWS * COLUMNS".
21764
21765           For 2 inputs, a default grid of "2x1" (equivalent to
21766           "layout=0_0|w0_0") is set. In all other cases, a layout or a grid
21767           must be set by the user. Either "grid" or "layout" can be specified
21768           at a time.  Specifying both will result in an error.
21769
21770       shortest
21771           If set to 1, force the output to terminate when the shortest input
21772           terminates. Default value is 0.
21773
21774       fill
21775           If set to valid color, all unused pixels will be filled with that
21776           color.  By default fill is set to none, so it is disabled.
21777
21778       Examples
21779
21780       •   Display 4 inputs into 2x2 grid.
21781
21782           Layout:
21783
21784                   input1(0, 0)  | input3(w0, 0)
21785                   input2(0, h0) | input4(w0, h0)
21786
21787
21788
21789                   xstack=inputs=4:layout=0_0|0_h0|w0_0|w0_h0
21790
21791           Note that if inputs are of different sizes, gaps or overlaps may
21792           occur.
21793
21794       •   Display 4 inputs into 1x4 grid.
21795
21796           Layout:
21797
21798                   input1(0, 0)
21799                   input2(0, h0)
21800                   input3(0, h0+h1)
21801                   input4(0, h0+h1+h2)
21802
21803
21804
21805                   xstack=inputs=4:layout=0_0|0_h0|0_h0+h1|0_h0+h1+h2
21806
21807           Note that if inputs are of different widths, unused space will
21808           appear.
21809
21810       •   Display 9 inputs into 3x3 grid.
21811
21812           Layout:
21813
21814                   input1(0, 0)       | input4(w0, 0)      | input7(w0+w3, 0)
21815                   input2(0, h0)      | input5(w0, h0)     | input8(w0+w3, h0)
21816                   input3(0, h0+h1)   | input6(w0, h0+h1)  | input9(w0+w3, h0+h1)
21817
21818
21819
21820                   xstack=inputs=9:layout=0_0|0_h0|0_h0+h1|w0_0|w0_h0|w0_h0+h1|w0+w3_0|w0+w3_h0|w0+w3_h0+h1
21821
21822           Note that if inputs are of different sizes, gaps or overlaps may
21823           occur.
21824
21825       •   Display 16 inputs into 4x4 grid.
21826
21827           Layout:
21828
21829                   input1(0, 0)       | input5(w0, 0)       | input9 (w0+w4, 0)       | input13(w0+w4+w8, 0)
21830                   input2(0, h0)      | input6(w0, h0)      | input10(w0+w4, h0)      | input14(w0+w4+w8, h0)
21831                   input3(0, h0+h1)   | input7(w0, h0+h1)   | input11(w0+w4, h0+h1)   | input15(w0+w4+w8, h0+h1)
21832                   input4(0, h0+h1+h2)| input8(w0, h0+h1+h2)| input12(w0+w4, h0+h1+h2)| input16(w0+w4+w8, h0+h1+h2)
21833
21834
21835
21836                   xstack=inputs=16:layout=0_0|0_h0|0_h0+h1|0_h0+h1+h2|w0_0|w0_h0|w0_h0+h1|w0_h0+h1+h2|w0+w4_0|
21837                   w0+w4_h0|w0+w4_h0+h1|w0+w4_h0+h1+h2|w0+w4+w8_0|w0+w4+w8_h0|w0+w4+w8_h0+h1|w0+w4+w8_h0+h1+h2
21838
21839           Note that if inputs are of different sizes, gaps or overlaps may
21840           occur.
21841
21842   yadif
21843       Deinterlace the input video ("yadif" means "yet another deinterlacing
21844       filter").
21845
21846       It accepts the following parameters:
21847
21848       mode
21849           The interlacing mode to adopt. It accepts one of the following
21850           values:
21851
21852           0, send_frame
21853               Output one frame for each frame.
21854
21855           1, send_field
21856               Output one frame for each field.
21857
21858           2, send_frame_nospatial
21859               Like "send_frame", but it skips the spatial interlacing check.
21860
21861           3, send_field_nospatial
21862               Like "send_field", but it skips the spatial interlacing check.
21863
21864           The default value is "send_frame".
21865
21866       parity
21867           The picture field parity assumed for the input interlaced video. It
21868           accepts one of the following values:
21869
21870           0, tff
21871               Assume the top field is first.
21872
21873           1, bff
21874               Assume the bottom field is first.
21875
21876           -1, auto
21877               Enable automatic detection of field parity.
21878
21879           The default value is "auto".  If the interlacing is unknown or the
21880           decoder does not export this information, top field first will be
21881           assumed.
21882
21883       deint
21884           Specify which frames to deinterlace. Accepts one of the following
21885           values:
21886
21887           0, all
21888               Deinterlace all frames.
21889
21890           1, interlaced
21891               Only deinterlace frames marked as interlaced.
21892
21893           The default value is "all".
21894
21895   yadif_cuda
21896       Deinterlace the input video using the yadif algorithm, but implemented
21897       in CUDA so that it can work as part of a GPU accelerated pipeline with
21898       nvdec and/or nvenc.
21899
21900       It accepts the following parameters:
21901
21902       mode
21903           The interlacing mode to adopt. It accepts one of the following
21904           values:
21905
21906           0, send_frame
21907               Output one frame for each frame.
21908
21909           1, send_field
21910               Output one frame for each field.
21911
21912           2, send_frame_nospatial
21913               Like "send_frame", but it skips the spatial interlacing check.
21914
21915           3, send_field_nospatial
21916               Like "send_field", but it skips the spatial interlacing check.
21917
21918           The default value is "send_frame".
21919
21920       parity
21921           The picture field parity assumed for the input interlaced video. It
21922           accepts one of the following values:
21923
21924           0, tff
21925               Assume the top field is first.
21926
21927           1, bff
21928               Assume the bottom field is first.
21929
21930           -1, auto
21931               Enable automatic detection of field parity.
21932
21933           The default value is "auto".  If the interlacing is unknown or the
21934           decoder does not export this information, top field first will be
21935           assumed.
21936
21937       deint
21938           Specify which frames to deinterlace. Accepts one of the following
21939           values:
21940
21941           0, all
21942               Deinterlace all frames.
21943
21944           1, interlaced
21945               Only deinterlace frames marked as interlaced.
21946
21947           The default value is "all".
21948
21949   yaepblur
21950       Apply blur filter while preserving edges ("yaepblur" means "yet another
21951       edge preserving blur filter").  The algorithm is described in "J. S.
21952       Lee, Digital image enhancement and noise filtering by use of local
21953       statistics, IEEE Trans. Pattern Anal. Mach. Intell. PAMI-2, 1980."
21954
21955       It accepts the following parameters:
21956
21957       radius, r
21958           Set the window radius. Default value is 3.
21959
21960       planes, p
21961           Set which planes to filter. Default is only the first plane.
21962
21963       sigma, s
21964           Set blur strength. Default value is 128.
21965
21966       Commands
21967
21968       This filter supports same commands as options.
21969
21970   zoompan
21971       Apply Zoom & Pan effect.
21972
21973       This filter accepts the following options:
21974
21975       zoom, z
21976           Set the zoom expression. Range is 1-10. Default is 1.
21977
21978       x
21979       y   Set the x and y expression. Default is 0.
21980
21981       d   Set the duration expression in number of frames.  This sets for how
21982           many number of frames effect will last for single input image.
21983           Default is 90.
21984
21985       s   Set the output image size, default is 'hd720'.
21986
21987       fps Set the output frame rate, default is '25'.
21988
21989       Each expression can contain the following constants:
21990
21991       in_w, iw
21992           Input width.
21993
21994       in_h, ih
21995           Input height.
21996
21997       out_w, ow
21998           Output width.
21999
22000       out_h, oh
22001           Output height.
22002
22003       in  Input frame count.
22004
22005       on  Output frame count.
22006
22007       in_time, it
22008           The input timestamp expressed in seconds. It's NAN if the input
22009           timestamp is unknown.
22010
22011       out_time, time, ot
22012           The output timestamp expressed in seconds.
22013
22014       x
22015       y   Last calculated 'x' and 'y' position from 'x' and 'y' expression
22016           for current input frame.
22017
22018       px
22019       py  'x' and 'y' of last output frame of previous input frame or 0 when
22020           there was not yet such frame (first input frame).
22021
22022       zoom
22023           Last calculated zoom from 'z' expression for current input frame.
22024
22025       pzoom
22026           Last calculated zoom of last output frame of previous input frame.
22027
22028       duration
22029           Number of output frames for current input frame. Calculated from
22030           'd' expression for each input frame.
22031
22032       pduration
22033           number of output frames created for previous input frame
22034
22035       a   Rational number: input width / input height
22036
22037       sar sample aspect ratio
22038
22039       dar display aspect ratio
22040
22041       Examples
22042
22043       •   Zoom in up to 1.5x and pan at same time to some spot near center of
22044           picture:
22045
22046                   zoompan=z='min(zoom+0.0015,1.5)':d=700:x='if(gte(zoom,1.5),x,x+1/a)':y='if(gte(zoom,1.5),y,y+1)':s=640x360
22047
22048       •   Zoom in up to 1.5x and pan always at center of picture:
22049
22050                   zoompan=z='min(zoom+0.0015,1.5)':d=700:x='iw/2-(iw/zoom/2)':y='ih/2-(ih/zoom/2)'
22051
22052       •   Same as above but without pausing:
22053
22054                   zoompan=z='min(max(zoom,pzoom)+0.0015,1.5)':d=1:x='iw/2-(iw/zoom/2)':y='ih/2-(ih/zoom/2)'
22055
22056       •   Zoom in 2x into center of picture only for the first second of the
22057           input video:
22058
22059                   zoompan=z='if(between(in_time,0,1),2,1)':d=1:x='iw/2-(iw/zoom/2)':y='ih/2-(ih/zoom/2)'
22060
22061   zscale
22062       Scale (resize) the input video, using the z.lib library:
22063       <https://github.com/sekrit-twc/zimg>. To enable compilation of this
22064       filter, you need to configure FFmpeg with "--enable-libzimg".
22065
22066       The zscale filter forces the output display aspect ratio to be the same
22067       as the input, by changing the output sample aspect ratio.
22068
22069       If the input image format is different from the format requested by the
22070       next filter, the zscale filter will convert the input to the requested
22071       format.
22072
22073       Options
22074
22075       The filter accepts the following options.
22076
22077       width, w
22078       height, h
22079           Set the output video dimension expression. Default value is the
22080           input dimension.
22081
22082           If the width or w value is 0, the input width is used for the
22083           output. If the height or h value is 0, the input height is used for
22084           the output.
22085
22086           If one and only one of the values is -n with n >= 1, the zscale
22087           filter will use a value that maintains the aspect ratio of the
22088           input image, calculated from the other specified dimension. After
22089           that it will, however, make sure that the calculated dimension is
22090           divisible by n and adjust the value if necessary.
22091
22092           If both values are -n with n >= 1, the behavior will be identical
22093           to both values being set to 0 as previously detailed.
22094
22095           See below for the list of accepted constants for use in the
22096           dimension expression.
22097
22098       size, s
22099           Set the video size. For the syntax of this option, check the "Video
22100           size" section in the ffmpeg-utils manual.
22101
22102       dither, d
22103           Set the dither type.
22104
22105           Possible values are:
22106
22107           none
22108           ordered
22109           random
22110           error_diffusion
22111
22112           Default is none.
22113
22114       filter, f
22115           Set the resize filter type.
22116
22117           Possible values are:
22118
22119           point
22120           bilinear
22121           bicubic
22122           spline16
22123           spline36
22124           lanczos
22125
22126           Default is bilinear.
22127
22128       range, r
22129           Set the color range.
22130
22131           Possible values are:
22132
22133           input
22134           limited
22135           full
22136
22137           Default is same as input.
22138
22139       primaries, p
22140           Set the color primaries.
22141
22142           Possible values are:
22143
22144           input
22145           709
22146           unspecified
22147           170m
22148           240m
22149           2020
22150
22151           Default is same as input.
22152
22153       transfer, t
22154           Set the transfer characteristics.
22155
22156           Possible values are:
22157
22158           input
22159           709
22160           unspecified
22161           601
22162           linear
22163           2020_10
22164           2020_12
22165           smpte2084
22166           iec61966-2-1
22167           arib-std-b67
22168
22169           Default is same as input.
22170
22171       matrix, m
22172           Set the colorspace matrix.
22173
22174           Possible value are:
22175
22176           input
22177           709
22178           unspecified
22179           470bg
22180           170m
22181           2020_ncl
22182           2020_cl
22183
22184           Default is same as input.
22185
22186       rangein, rin
22187           Set the input color range.
22188
22189           Possible values are:
22190
22191           input
22192           limited
22193           full
22194
22195           Default is same as input.
22196
22197       primariesin, pin
22198           Set the input color primaries.
22199
22200           Possible values are:
22201
22202           input
22203           709
22204           unspecified
22205           170m
22206           240m
22207           2020
22208
22209           Default is same as input.
22210
22211       transferin, tin
22212           Set the input transfer characteristics.
22213
22214           Possible values are:
22215
22216           input
22217           709
22218           unspecified
22219           601
22220           linear
22221           2020_10
22222           2020_12
22223
22224           Default is same as input.
22225
22226       matrixin, min
22227           Set the input colorspace matrix.
22228
22229           Possible value are:
22230
22231           input
22232           709
22233           unspecified
22234           470bg
22235           170m
22236           2020_ncl
22237           2020_cl
22238       chromal, c
22239           Set the output chroma location.
22240
22241           Possible values are:
22242
22243           input
22244           left
22245           center
22246           topleft
22247           top
22248           bottomleft
22249           bottom
22250       chromalin, cin
22251           Set the input chroma location.
22252
22253           Possible values are:
22254
22255           input
22256           left
22257           center
22258           topleft
22259           top
22260           bottomleft
22261           bottom
22262       npl Set the nominal peak luminance.
22263
22264       param_a
22265           Parameter A for scaling filters. Parameter "b" for bicubic, and the
22266           number of filter taps for lanczos.
22267
22268       param_b
22269           Parameter B for scaling filters. Parameter "c" for bicubic.
22270
22271       The values of the w and h options are expressions containing the
22272       following constants:
22273
22274       in_w
22275       in_h
22276           The input width and height
22277
22278       iw
22279       ih  These are the same as in_w and in_h.
22280
22281       out_w
22282       out_h
22283           The output (scaled) width and height
22284
22285       ow
22286       oh  These are the same as out_w and out_h
22287
22288       a   The same as iw / ih
22289
22290       sar input sample aspect ratio
22291
22292       dar The input display aspect ratio. Calculated from "(iw / ih) * sar".
22293
22294       hsub
22295       vsub
22296           horizontal and vertical input chroma subsample values. For example
22297           for the pixel format "yuv422p" hsub is 2 and vsub is 1.
22298
22299       ohsub
22300       ovsub
22301           horizontal and vertical output chroma subsample values. For example
22302           for the pixel format "yuv422p" hsub is 2 and vsub is 1.
22303
22304       Commands
22305
22306       This filter supports the following commands:
22307
22308       width, w
22309       height, h
22310           Set the output video dimension expression.  The command accepts the
22311           same syntax of the corresponding option.
22312
22313           If the specified expression is not valid, it is kept at its current
22314           value.
22315

OPENCL VIDEO FILTERS

22317       Below is a description of the currently available OpenCL video filters.
22318
22319       To enable compilation of these filters you need to configure FFmpeg
22320       with "--enable-opencl".
22321
22322       Running OpenCL filters requires you to initialize a hardware device and
22323       to pass that device to all filters in any filter graph.
22324
22325       -init_hw_device opencl[=name][:device[,key=value...]]
22326           Initialise a new hardware device of type opencl called name, using
22327           the given device parameters.
22328
22329       -filter_hw_device name
22330           Pass the hardware device called name to all filters in any filter
22331           graph.
22332
22333       For more detailed information see
22334       <https://www.ffmpeg.org/ffmpeg.html#Advanced-Video-options>
22335
22336       •   Example of choosing the first device on the second platform and
22337           running avgblur_opencl filter with default parameters on it.
22338
22339                   -init_hw_device opencl=gpu:1.0 -filter_hw_device gpu -i INPUT -vf "hwupload, avgblur_opencl, hwdownload" OUTPUT
22340
22341       Since OpenCL filters are not able to access frame data in normal
22342       memory, all frame data needs to be uploaded(hwupload) to hardware
22343       surfaces connected to the appropriate device before being used and then
22344       downloaded(hwdownload) back to normal memory. Note that hwupload will
22345       upload to a surface with the same layout as the software frame, so it
22346       may be necessary to add a format filter immediately before to get the
22347       input into the right format and hwdownload does not support all formats
22348       on the output - it may be necessary to insert an additional format
22349       filter immediately following in the graph to get the output in a
22350       supported format.
22351
22352   avgblur_opencl
22353       Apply average blur filter.
22354
22355       The filter accepts the following options:
22356
22357       sizeX
22358           Set horizontal radius size.  Range is "[1, 1024]" and default value
22359           is 1.
22360
22361       planes
22362           Set which planes to filter. Default value is 0xf, by which all
22363           planes are processed.
22364
22365       sizeY
22366           Set vertical radius size. Range is "[1, 1024]" and default value is
22367           0. If zero, "sizeX" value will be used.
22368
22369       Example
22370
22371       •   Apply average blur filter with horizontal and vertical size of 3,
22372           setting each pixel of the output to the average value of the 7x7
22373           region centered on it in the input. For pixels on the edges of the
22374           image, the region does not extend beyond the image boundaries, and
22375           so out-of-range coordinates are not used in the calculations.
22376
22377                   -i INPUT -vf "hwupload, avgblur_opencl=3, hwdownload" OUTPUT
22378
22379   boxblur_opencl
22380       Apply a boxblur algorithm to the input video.
22381
22382       It accepts the following parameters:
22383
22384       luma_radius, lr
22385       luma_power, lp
22386       chroma_radius, cr
22387       chroma_power, cp
22388       alpha_radius, ar
22389       alpha_power, ap
22390
22391       A description of the accepted options follows.
22392
22393       luma_radius, lr
22394       chroma_radius, cr
22395       alpha_radius, ar
22396           Set an expression for the box radius in pixels used for blurring
22397           the corresponding input plane.
22398
22399           The radius value must be a non-negative number, and must not be
22400           greater than the value of the expression "min(w,h)/2" for the luma
22401           and alpha planes, and of "min(cw,ch)/2" for the chroma planes.
22402
22403           Default value for luma_radius is "2". If not specified,
22404           chroma_radius and alpha_radius default to the corresponding value
22405           set for luma_radius.
22406
22407           The expressions can contain the following constants:
22408
22409           w
22410           h   The input width and height in pixels.
22411
22412           cw
22413           ch  The input chroma image width and height in pixels.
22414
22415           hsub
22416           vsub
22417               The horizontal and vertical chroma subsample values. For
22418               example, for the pixel format "yuv422p", hsub is 2 and vsub is
22419               1.
22420
22421       luma_power, lp
22422       chroma_power, cp
22423       alpha_power, ap
22424           Specify how many times the boxblur filter is applied to the
22425           corresponding plane.
22426
22427           Default value for luma_power is 2. If not specified, chroma_power
22428           and alpha_power default to the corresponding value set for
22429           luma_power.
22430
22431           A value of 0 will disable the effect.
22432
22433       Examples
22434
22435       Apply boxblur filter, setting each pixel of the output to the average
22436       value of box-radiuses luma_radius, chroma_radius, alpha_radius for each
22437       plane respectively. The filter will apply luma_power, chroma_power,
22438       alpha_power times onto the corresponding plane. For pixels on the edges
22439       of the image, the radius does not extend beyond the image boundaries,
22440       and so out-of-range coordinates are not used in the calculations.
22441
22442       •   Apply a boxblur filter with the luma, chroma, and alpha radius set
22443           to 2 and luma, chroma, and alpha power set to 3. The filter will
22444           run 3 times with box-radius set to 2 for every plane of the image.
22445
22446                   -i INPUT -vf "hwupload, boxblur_opencl=luma_radius=2:luma_power=3, hwdownload" OUTPUT
22447                   -i INPUT -vf "hwupload, boxblur_opencl=2:3, hwdownload" OUTPUT
22448
22449       •   Apply a boxblur filter with luma radius set to 2, luma_power to 1,
22450           chroma_radius to 4, chroma_power to 5, alpha_radius to 3 and
22451           alpha_power to 7.
22452
22453           For the luma plane, a 2x2 box radius will be run once.
22454
22455           For the chroma plane, a 4x4 box radius will be run 5 times.
22456
22457           For the alpha plane, a 3x3 box radius will be run 7 times.
22458
22459                   -i INPUT -vf "hwupload, boxblur_opencl=2:1:4:5:3:7, hwdownload" OUTPUT
22460
22461   colorkey_opencl
22462       RGB colorspace color keying.
22463
22464       The filter accepts the following options:
22465
22466       color
22467           The color which will be replaced with transparency.
22468
22469       similarity
22470           Similarity percentage with the key color.
22471
22472           0.01 matches only the exact key color, while 1.0 matches
22473           everything.
22474
22475       blend
22476           Blend percentage.
22477
22478           0.0 makes pixels either fully transparent, or not transparent at
22479           all.
22480
22481           Higher values result in semi-transparent pixels, with a higher
22482           transparency the more similar the pixels color is to the key color.
22483
22484       Examples
22485
22486       •   Make every semi-green pixel in the input transparent with some
22487           slight blending:
22488
22489                   -i INPUT -vf "hwupload, colorkey_opencl=green:0.3:0.1, hwdownload" OUTPUT
22490
22491   convolution_opencl
22492       Apply convolution of 3x3, 5x5, 7x7 matrix.
22493
22494       The filter accepts the following options:
22495
22496       0m
22497       1m
22498       2m
22499       3m  Set matrix for each plane.  Matrix is sequence of 9, 25 or 49
22500           signed numbers.  Default value for each plane is "0 0 0 0 1 0 0 0
22501           0".
22502
22503       0rdiv
22504       1rdiv
22505       2rdiv
22506       3rdiv
22507           Set multiplier for calculated value for each plane.  If unset or 0,
22508           it will be sum of all matrix elements.  The option value must be a
22509           float number greater or equal to 0.0. Default value is 1.0.
22510
22511       0bias
22512       1bias
22513       2bias
22514       3bias
22515           Set bias for each plane. This value is added to the result of the
22516           multiplication.  Useful for making the overall image brighter or
22517           darker.  The option value must be a float number greater or equal
22518           to 0.0. Default value is 0.0.
22519
22520       Examples
22521
22522       •   Apply sharpen:
22523
22524                   -i INPUT -vf "hwupload, convolution_opencl=0 -1 0 -1 5 -1 0 -1 0:0 -1 0 -1 5 -1 0 -1 0:0 -1 0 -1 5 -1 0 -1 0:0 -1 0 -1 5 -1 0 -1 0, hwdownload" OUTPUT
22525
22526       •   Apply blur:
22527
22528                   -i INPUT -vf "hwupload, convolution_opencl=1 1 1 1 1 1 1 1 1:1 1 1 1 1 1 1 1 1:1 1 1 1 1 1 1 1 1:1 1 1 1 1 1 1 1 1:1/9:1/9:1/9:1/9, hwdownload" OUTPUT
22529
22530       •   Apply edge enhance:
22531
22532                   -i INPUT -vf "hwupload, convolution_opencl=0 0 0 -1 1 0 0 0 0:0 0 0 -1 1 0 0 0 0:0 0 0 -1 1 0 0 0 0:0 0 0 -1 1 0 0 0 0:5:1:1:1:0:128:128:128, hwdownload" OUTPUT
22533
22534       •   Apply edge detect:
22535
22536                   -i INPUT -vf "hwupload, convolution_opencl=0 1 0 1 -4 1 0 1 0:0 1 0 1 -4 1 0 1 0:0 1 0 1 -4 1 0 1 0:0 1 0 1 -4 1 0 1 0:5:5:5:1:0:128:128:128, hwdownload" OUTPUT
22537
22538       •   Apply laplacian edge detector which includes diagonals:
22539
22540                   -i INPUT -vf "hwupload, convolution_opencl=1 1 1 1 -8 1 1 1 1:1 1 1 1 -8 1 1 1 1:1 1 1 1 -8 1 1 1 1:1 1 1 1 -8 1 1 1 1:5:5:5:1:0:128:128:0, hwdownload" OUTPUT
22541
22542       •   Apply emboss:
22543
22544                   -i INPUT -vf "hwupload, convolution_opencl=-2 -1 0 -1 1 1 0 1 2:-2 -1 0 -1 1 1 0 1 2:-2 -1 0 -1 1 1 0 1 2:-2 -1 0 -1 1 1 0 1 2, hwdownload" OUTPUT
22545
22546   erosion_opencl
22547       Apply erosion effect to the video.
22548
22549       This filter replaces the pixel by the local(3x3) minimum.
22550
22551       It accepts the following options:
22552
22553       threshold0
22554       threshold1
22555       threshold2
22556       threshold3
22557           Limit the maximum change for each plane. Range is "[0, 65535]" and
22558           default value is 65535.  If 0, plane will remain unchanged.
22559
22560       coordinates
22561           Flag which specifies the pixel to refer to.  Range is "[0, 255]"
22562           and default value is 255, i.e. all eight pixels are used.
22563
22564           Flags to local 3x3 coordinates region centered on "x":
22565
22566               1 2 3
22567
22568               4 x 5
22569
22570               6 7 8
22571
22572       Example
22573
22574       •   Apply erosion filter with threshold0 set to 30, threshold1 set 40,
22575           threshold2 set to 50 and coordinates set to 231, setting each pixel
22576           of the output to the local minimum between pixels: 1, 2, 3, 6, 7, 8
22577           of the 3x3 region centered on it in the input. If the difference
22578           between input pixel and local minimum is more then threshold of the
22579           corresponding plane, output pixel will be set to input pixel -
22580           threshold of corresponding plane.
22581
22582                   -i INPUT -vf "hwupload, erosion_opencl=30:40:50:coordinates=231, hwdownload" OUTPUT
22583
22584   deshake_opencl
22585       Feature-point based video stabilization filter.
22586
22587       The filter accepts the following options:
22588
22589       tripod
22590           Simulates a tripod by preventing any camera movement whatsoever
22591           from the original frame. Defaults to 0.
22592
22593       debug
22594           Whether or not additional debug info should be displayed, both in
22595           the processed output and in the console.
22596
22597           Note that in order to see console debug output you will also need
22598           to pass "-v verbose" to ffmpeg.
22599
22600           Viewing point matches in the output video is only supported for RGB
22601           input.
22602
22603           Defaults to 0.
22604
22605       adaptive_crop
22606           Whether or not to do a tiny bit of cropping at the borders to cut
22607           down on the amount of mirrored pixels.
22608
22609           Defaults to 1.
22610
22611       refine_features
22612           Whether or not feature points should be refined at a sub-pixel
22613           level.
22614
22615           This can be turned off for a slight performance gain at the cost of
22616           precision.
22617
22618           Defaults to 1.
22619
22620       smooth_strength
22621           The strength of the smoothing applied to the camera path from 0.0
22622           to 1.0.
22623
22624           1.0 is the maximum smoothing strength while values less than that
22625           result in less smoothing.
22626
22627           0.0 causes the filter to adaptively choose a smoothing strength on
22628           a per-frame basis.
22629
22630           Defaults to 0.0.
22631
22632       smooth_window_multiplier
22633           Controls the size of the smoothing window (the number of frames
22634           buffered to determine motion information from).
22635
22636           The size of the smoothing window is determined by multiplying the
22637           framerate of the video by this number.
22638
22639           Acceptable values range from 0.1 to 10.0.
22640
22641           Larger values increase the amount of motion data available for
22642           determining how to smooth the camera path, potentially improving
22643           smoothness, but also increase latency and memory usage.
22644
22645           Defaults to 2.0.
22646
22647       Examples
22648
22649       •   Stabilize a video with a fixed, medium smoothing strength:
22650
22651                   -i INPUT -vf "hwupload, deshake_opencl=smooth_strength=0.5, hwdownload" OUTPUT
22652
22653       •   Stabilize a video with debugging (both in console and in rendered
22654           video):
22655
22656                   -i INPUT -filter_complex "[0:v]format=rgba, hwupload, deshake_opencl=debug=1, hwdownload, format=rgba, format=yuv420p" -v verbose OUTPUT
22657
22658   dilation_opencl
22659       Apply dilation effect to the video.
22660
22661       This filter replaces the pixel by the local(3x3) maximum.
22662
22663       It accepts the following options:
22664
22665       threshold0
22666       threshold1
22667       threshold2
22668       threshold3
22669           Limit the maximum change for each plane. Range is "[0, 65535]" and
22670           default value is 65535.  If 0, plane will remain unchanged.
22671
22672       coordinates
22673           Flag which specifies the pixel to refer to.  Range is "[0, 255]"
22674           and default value is 255, i.e. all eight pixels are used.
22675
22676           Flags to local 3x3 coordinates region centered on "x":
22677
22678               1 2 3
22679
22680               4 x 5
22681
22682               6 7 8
22683
22684       Example
22685
22686       •   Apply dilation filter with threshold0 set to 30, threshold1 set 40,
22687           threshold2 set to 50 and coordinates set to 231, setting each pixel
22688           of the output to the local maximum between pixels: 1, 2, 3, 6, 7, 8
22689           of the 3x3 region centered on it in the input. If the difference
22690           between input pixel and local maximum is more then threshold of the
22691           corresponding plane, output pixel will be set to input pixel +
22692           threshold of corresponding plane.
22693
22694                   -i INPUT -vf "hwupload, dilation_opencl=30:40:50:coordinates=231, hwdownload" OUTPUT
22695
22696   nlmeans_opencl
22697       Non-local Means denoise filter through OpenCL, this filter accepts same
22698       options as nlmeans.
22699
22700   overlay_opencl
22701       Overlay one video on top of another.
22702
22703       It takes two inputs and has one output. The first input is the "main"
22704       video on which the second input is overlaid.  This filter requires same
22705       memory layout for all the inputs. So, format conversion may be needed.
22706
22707       The filter accepts the following options:
22708
22709       x   Set the x coordinate of the overlaid video on the main video.
22710           Default value is 0.
22711
22712       y   Set the y coordinate of the overlaid video on the main video.
22713           Default value is 0.
22714
22715       Examples
22716
22717       •   Overlay an image LOGO at the top-left corner of the INPUT video.
22718           Both inputs are yuv420p format.
22719
22720                   -i INPUT -i LOGO -filter_complex "[0:v]hwupload[a], [1:v]format=yuv420p, hwupload[b], [a][b]overlay_opencl, hwdownload" OUTPUT
22721
22722       •   The inputs have same memory layout for color channels , the overlay
22723           has additional alpha plane, like INPUT is yuv420p, and the LOGO is
22724           yuva420p.
22725
22726                   -i INPUT -i LOGO -filter_complex "[0:v]hwupload[a], [1:v]format=yuva420p, hwupload[b], [a][b]overlay_opencl, hwdownload" OUTPUT
22727
22728   pad_opencl
22729       Add paddings to the input image, and place the original input at the
22730       provided x, y coordinates.
22731
22732       It accepts the following options:
22733
22734       width, w
22735       height, h
22736           Specify an expression for the size of the output image with the
22737           paddings added. If the value for width or height is 0, the
22738           corresponding input size is used for the output.
22739
22740           The width expression can reference the value set by the height
22741           expression, and vice versa.
22742
22743           The default value of width and height is 0.
22744
22745       x
22746       y   Specify the offsets to place the input image at within the padded
22747           area, with respect to the top/left border of the output image.
22748
22749           The x expression can reference the value set by the y expression,
22750           and vice versa.
22751
22752           The default value of x and y is 0.
22753
22754           If x or y evaluate to a negative number, they'll be changed so the
22755           input image is centered on the padded area.
22756
22757       color
22758           Specify the color of the padded area. For the syntax of this
22759           option, check the "Color" section in the ffmpeg-utils manual.
22760
22761       aspect
22762           Pad to an aspect instead to a resolution.
22763
22764       The value for the width, height, x, and y options are expressions
22765       containing the following constants:
22766
22767       in_w
22768       in_h
22769           The input video width and height.
22770
22771       iw
22772       ih  These are the same as in_w and in_h.
22773
22774       out_w
22775       out_h
22776           The output width and height (the size of the padded area), as
22777           specified by the width and height expressions.
22778
22779       ow
22780       oh  These are the same as out_w and out_h.
22781
22782       x
22783       y   The x and y offsets as specified by the x and y expressions, or NAN
22784           if not yet specified.
22785
22786       a   same as iw / ih
22787
22788       sar input sample aspect ratio
22789
22790       dar input display aspect ratio, it is the same as (iw / ih) * sar
22791
22792   prewitt_opencl
22793       Apply the Prewitt operator
22794       (<https://en.wikipedia.org/wiki/Prewitt_operator>) to input video
22795       stream.
22796
22797       The filter accepts the following option:
22798
22799       planes
22800           Set which planes to filter. Default value is 0xf, by which all
22801           planes are processed.
22802
22803       scale
22804           Set value which will be multiplied with filtered result.  Range is
22805           "[0.0, 65535]" and default value is 1.0.
22806
22807       delta
22808           Set value which will be added to filtered result.  Range is
22809           "[-65535, 65535]" and default value is 0.0.
22810
22811       Example
22812
22813       •   Apply the Prewitt operator with scale set to 2 and delta set to 10.
22814
22815                   -i INPUT -vf "hwupload, prewitt_opencl=scale=2:delta=10, hwdownload" OUTPUT
22816
22817   program_opencl
22818       Filter video using an OpenCL program.
22819
22820       source
22821           OpenCL program source file.
22822
22823       kernel
22824           Kernel name in program.
22825
22826       inputs
22827           Number of inputs to the filter.  Defaults to 1.
22828
22829       size, s
22830           Size of output frames.  Defaults to the same as the first input.
22831
22832       The "program_opencl" filter also supports the framesync options.
22833
22834       The program source file must contain a kernel function with the given
22835       name, which will be run once for each plane of the output.  Each run on
22836       a plane gets enqueued as a separate 2D global NDRange with one work-
22837       item for each pixel to be generated.  The global ID offset for each
22838       work-item is therefore the coordinates of a pixel in the destination
22839       image.
22840
22841       The kernel function needs to take the following arguments:
22842
22843       •   Destination image, __write_only image2d_t.
22844
22845           This image will become the output; the kernel should write all of
22846           it.
22847
22848       •   Frame index, unsigned int.
22849
22850           This is a counter starting from zero and increasing by one for each
22851           frame.
22852
22853       •   Source images, __read_only image2d_t.
22854
22855           These are the most recent images on each input.  The kernel may
22856           read from them to generate the output, but they can't be written
22857           to.
22858
22859       Example programs:
22860
22861       •   Copy the input to the output (output must be the same size as the
22862           input).
22863
22864                   __kernel void copy(__write_only image2d_t destination,
22865                                      unsigned int index,
22866                                      __read_only  image2d_t source)
22867                   {
22868                       const sampler_t sampler = CLK_NORMALIZED_COORDS_FALSE;
22869
22870                       int2 location = (int2)(get_global_id(0), get_global_id(1));
22871
22872                       float4 value = read_imagef(source, sampler, location);
22873
22874                       write_imagef(destination, location, value);
22875                   }
22876
22877       •   Apply a simple transformation, rotating the input by an amount
22878           increasing with the index counter.  Pixel values are linearly
22879           interpolated by the sampler, and the output need not have the same
22880           dimensions as the input.
22881
22882                   __kernel void rotate_image(__write_only image2d_t dst,
22883                                              unsigned int index,
22884                                              __read_only  image2d_t src)
22885                   {
22886                       const sampler_t sampler = (CLK_NORMALIZED_COORDS_FALSE |
22887                                                  CLK_FILTER_LINEAR);
22888
22889                       float angle = (float)index / 100.0f;
22890
22891                       float2 dst_dim = convert_float2(get_image_dim(dst));
22892                       float2 src_dim = convert_float2(get_image_dim(src));
22893
22894                       float2 dst_cen = dst_dim / 2.0f;
22895                       float2 src_cen = src_dim / 2.0f;
22896
22897                       int2   dst_loc = (int2)(get_global_id(0), get_global_id(1));
22898
22899                       float2 dst_pos = convert_float2(dst_loc) - dst_cen;
22900                       float2 src_pos = {
22901                           cos(angle) * dst_pos.x - sin(angle) * dst_pos.y,
22902                           sin(angle) * dst_pos.x + cos(angle) * dst_pos.y
22903                       };
22904                       src_pos = src_pos * src_dim / dst_dim;
22905
22906                       float2 src_loc = src_pos + src_cen;
22907
22908                       if (src_loc.x < 0.0f      || src_loc.y < 0.0f ||
22909                           src_loc.x > src_dim.x || src_loc.y > src_dim.y)
22910                           write_imagef(dst, dst_loc, 0.5f);
22911                       else
22912                           write_imagef(dst, dst_loc, read_imagef(src, sampler, src_loc));
22913                   }
22914
22915       •   Blend two inputs together, with the amount of each input used
22916           varying with the index counter.
22917
22918                   __kernel void blend_images(__write_only image2d_t dst,
22919                                              unsigned int index,
22920                                              __read_only  image2d_t src1,
22921                                              __read_only  image2d_t src2)
22922                   {
22923                       const sampler_t sampler = (CLK_NORMALIZED_COORDS_FALSE |
22924                                                  CLK_FILTER_LINEAR);
22925
22926                       float blend = (cos((float)index / 50.0f) + 1.0f) / 2.0f;
22927
22928                       int2  dst_loc = (int2)(get_global_id(0), get_global_id(1));
22929                       int2 src1_loc = dst_loc * get_image_dim(src1) / get_image_dim(dst);
22930                       int2 src2_loc = dst_loc * get_image_dim(src2) / get_image_dim(dst);
22931
22932                       float4 val1 = read_imagef(src1, sampler, src1_loc);
22933                       float4 val2 = read_imagef(src2, sampler, src2_loc);
22934
22935                       write_imagef(dst, dst_loc, val1 * blend + val2 * (1.0f - blend));
22936                   }
22937
22938   remap_opencl
22939       Remap pixels using 2nd: Xmap and 3rd: Ymap input video stream.
22940
22941       Destination pixel at position (X, Y) will be picked from source (x, y)
22942       position where x = Xmap(X, Y) and y = Ymap(X, Y). If mapping values are
22943       out of range, zero value for pixel will be used for destination pixel.
22944
22945       Xmap and Ymap input video streams must be of same dimensions. Output
22946       video stream will have Xmap/Ymap video stream dimensions.  Xmap and
22947       Ymap input video streams are 32bit float pixel format, single channel.
22948
22949       interp
22950           Specify interpolation used for remapping of pixels.  Allowed values
22951           are "near" and "linear".  Default value is "linear".
22952
22953       fill
22954           Specify the color of the unmapped pixels. For the syntax of this
22955           option, check the "Color" section in the ffmpeg-utils manual.
22956           Default color is "black".
22957
22958   roberts_opencl
22959       Apply the Roberts cross operator
22960       (<https://en.wikipedia.org/wiki/Roberts_cross>) to input video stream.
22961
22962       The filter accepts the following option:
22963
22964       planes
22965           Set which planes to filter. Default value is 0xf, by which all
22966           planes are processed.
22967
22968       scale
22969           Set value which will be multiplied with filtered result.  Range is
22970           "[0.0, 65535]" and default value is 1.0.
22971
22972       delta
22973           Set value which will be added to filtered result.  Range is
22974           "[-65535, 65535]" and default value is 0.0.
22975
22976       Example
22977
22978       •   Apply the Roberts cross operator with scale set to 2 and delta set
22979           to 10
22980
22981                   -i INPUT -vf "hwupload, roberts_opencl=scale=2:delta=10, hwdownload" OUTPUT
22982
22983   sobel_opencl
22984       Apply the Sobel operator
22985       (<https://en.wikipedia.org/wiki/Sobel_operator>) to input video stream.
22986
22987       The filter accepts the following option:
22988
22989       planes
22990           Set which planes to filter. Default value is 0xf, by which all
22991           planes are processed.
22992
22993       scale
22994           Set value which will be multiplied with filtered result.  Range is
22995           "[0.0, 65535]" and default value is 1.0.
22996
22997       delta
22998           Set value which will be added to filtered result.  Range is
22999           "[-65535, 65535]" and default value is 0.0.
23000
23001       Example
23002
23003       •   Apply sobel operator with scale set to 2 and delta set to 10
23004
23005                   -i INPUT -vf "hwupload, sobel_opencl=scale=2:delta=10, hwdownload" OUTPUT
23006
23007   tonemap_opencl
23008       Perform HDR(PQ/HLG) to SDR conversion with tone-mapping.
23009
23010       It accepts the following parameters:
23011
23012       tonemap
23013           Specify the tone-mapping operator to be used. Same as tonemap
23014           option in tonemap.
23015
23016       param
23017           Tune the tone mapping algorithm. same as param option in tonemap.
23018
23019       desat
23020           Apply desaturation for highlights that exceed this level of
23021           brightness. The higher the parameter, the more color information
23022           will be preserved. This setting helps prevent unnaturally blown-out
23023           colors for super-highlights, by (smoothly) turning into white
23024           instead. This makes images feel more natural, at the cost of
23025           reducing information about out-of-range colors.
23026
23027           The default value is 0.5, and the algorithm here is a little
23028           different from the cpu version tonemap currently. A setting of 0.0
23029           disables this option.
23030
23031       threshold
23032           The tonemapping algorithm parameters is fine-tuned per each scene.
23033           And a threshold is used to detect whether the scene has changed or
23034           not. If the distance between the current frame average brightness
23035           and the current running average exceeds a threshold value, we would
23036           re-calculate scene average and peak brightness.  The default value
23037           is 0.2.
23038
23039       format
23040           Specify the output pixel format.
23041
23042           Currently supported formats are:
23043
23044           p010
23045           nv12
23046       range, r
23047           Set the output color range.
23048
23049           Possible values are:
23050
23051           tv/mpeg
23052           pc/jpeg
23053
23054           Default is same as input.
23055
23056       primaries, p
23057           Set the output color primaries.
23058
23059           Possible values are:
23060
23061           bt709
23062           bt2020
23063
23064           Default is same as input.
23065
23066       transfer, t
23067           Set the output transfer characteristics.
23068
23069           Possible values are:
23070
23071           bt709
23072           bt2020
23073
23074           Default is bt709.
23075
23076       matrix, m
23077           Set the output colorspace matrix.
23078
23079           Possible value are:
23080
23081           bt709
23082           bt2020
23083
23084           Default is same as input.
23085
23086       Example
23087
23088       •   Convert HDR(PQ/HLG) video to bt2020-transfer-characteristic p010
23089           format using linear operator.
23090
23091                   -i INPUT -vf "format=p010,hwupload,tonemap_opencl=t=bt2020:tonemap=linear:format=p010,hwdownload,format=p010" OUTPUT
23092
23093   unsharp_opencl
23094       Sharpen or blur the input video.
23095
23096       It accepts the following parameters:
23097
23098       luma_msize_x, lx
23099           Set the luma matrix horizontal size.  Range is "[1, 23]" and
23100           default value is 5.
23101
23102       luma_msize_y, ly
23103           Set the luma matrix vertical size.  Range is "[1, 23]" and default
23104           value is 5.
23105
23106       luma_amount, la
23107           Set the luma effect strength.  Range is "[-10, 10]" and default
23108           value is 1.0.
23109
23110           Negative values will blur the input video, while positive values
23111           will sharpen it, a value of zero will disable the effect.
23112
23113       chroma_msize_x, cx
23114           Set the chroma matrix horizontal size.  Range is "[1, 23]" and
23115           default value is 5.
23116
23117       chroma_msize_y, cy
23118           Set the chroma matrix vertical size.  Range is "[1, 23]" and
23119           default value is 5.
23120
23121       chroma_amount, ca
23122           Set the chroma effect strength.  Range is "[-10, 10]" and default
23123           value is 0.0.
23124
23125           Negative values will blur the input video, while positive values
23126           will sharpen it, a value of zero will disable the effect.
23127
23128       All parameters are optional and default to the equivalent of the string
23129       '5:5:1.0:5:5:0.0'.
23130
23131       Examples
23132
23133       •   Apply strong luma sharpen effect:
23134
23135                   -i INPUT -vf "hwupload, unsharp_opencl=luma_msize_x=7:luma_msize_y=7:luma_amount=2.5, hwdownload" OUTPUT
23136
23137       •   Apply a strong blur of both luma and chroma parameters:
23138
23139                   -i INPUT -vf "hwupload, unsharp_opencl=7:7:-2:7:7:-2, hwdownload" OUTPUT
23140
23141   xfade_opencl
23142       Cross fade two videos with custom transition effect by using OpenCL.
23143
23144       It accepts the following options:
23145
23146       transition
23147           Set one of possible transition effects.
23148
23149           custom
23150               Select custom transition effect, the actual transition
23151               description will be picked from source and kernel options.
23152
23153           fade
23154           wipeleft
23155           wiperight
23156           wipeup
23157           wipedown
23158           slideleft
23159           slideright
23160           slideup
23161           slidedown
23162               Default transition is fade.
23163
23164       source
23165           OpenCL program source file for custom transition.
23166
23167       kernel
23168           Set name of kernel to use for custom transition from program source
23169           file.
23170
23171       duration
23172           Set duration of video transition.
23173
23174       offset
23175           Set time of start of transition relative to first video.
23176
23177       The program source file must contain a kernel function with the given
23178       name, which will be run once for each plane of the output.  Each run on
23179       a plane gets enqueued as a separate 2D global NDRange with one work-
23180       item for each pixel to be generated.  The global ID offset for each
23181       work-item is therefore the coordinates of a pixel in the destination
23182       image.
23183
23184       The kernel function needs to take the following arguments:
23185
23186       •   Destination image, __write_only image2d_t.
23187
23188           This image will become the output; the kernel should write all of
23189           it.
23190
23191       •   First Source image, __read_only image2d_t.  Second Source image,
23192           __read_only image2d_t.
23193
23194           These are the most recent images on each input.  The kernel may
23195           read from them to generate the output, but they can't be written
23196           to.
23197
23198       •   Transition progress, float. This value is always between 0 and 1
23199           inclusive.
23200
23201       Example programs:
23202
23203       •   Apply dots curtain transition effect:
23204
23205                   __kernel void blend_images(__write_only image2d_t dst,
23206                                              __read_only  image2d_t src1,
23207                                              __read_only  image2d_t src2,
23208                                              float progress)
23209                   {
23210                       const sampler_t sampler = (CLK_NORMALIZED_COORDS_FALSE |
23211                                                  CLK_FILTER_LINEAR);
23212                       int2  p = (int2)(get_global_id(0), get_global_id(1));
23213                       float2 rp = (float2)(get_global_id(0), get_global_id(1));
23214                       float2 dim = (float2)(get_image_dim(src1).x, get_image_dim(src1).y);
23215                       rp = rp / dim;
23216
23217                       float2 dots = (float2)(20.0, 20.0);
23218                       float2 center = (float2)(0,0);
23219                       float2 unused;
23220
23221                       float4 val1 = read_imagef(src1, sampler, p);
23222                       float4 val2 = read_imagef(src2, sampler, p);
23223                       bool next = distance(fract(rp * dots, &unused), (float2)(0.5, 0.5)) < (progress / distance(rp, center));
23224
23225                       write_imagef(dst, p, next ? val1 : val2);
23226                   }
23227

VAAPI VIDEO FILTERS

23229       VAAPI Video filters are usually used with VAAPI decoder and VAAPI
23230       encoder. Below is a description of VAAPI video filters.
23231
23232       To enable compilation of these filters you need to configure FFmpeg
23233       with "--enable-vaapi".
23234
23235       To use vaapi filters, you need to setup the vaapi device correctly. For
23236       more information, please read
23237       <https://trac.ffmpeg.org/wiki/Hardware/VAAPI>
23238
23239   overlay_vaapi
23240       Overlay one video on the top of another.
23241
23242       It takes two inputs and has one output. The first input is the "main"
23243       video on which the second input is overlaid.  This filter requires same
23244       memory layout for all the inputs. So, format conversion may be needed.
23245
23246       The filter accepts the following options:
23247
23248       x   Set the x coordinate of the overlaid video on the main video.
23249           Default value is 0.
23250
23251       y   Set the y coordinate of the overlaid video on the main video.
23252           Default value is 0.
23253
23254       w   Set the width of the overlaid video on the main video.  Default
23255           value is the width of input overlay video.
23256
23257       h   Set the height of the overlaid video on the main video.  Default
23258           value is the height of input overlay video.
23259
23260       alpha
23261           Set blocking detection thresholds. Allowed range is 0.0 to 1.0, it
23262           requires an input video with alpha channel.  Default value is 0.0.
23263
23264       Examples
23265
23266       •   Overlay an image LOGO at the top-left corner of the INPUT video.
23267           Both inputs for this filter are yuv420p format.
23268
23269                   -i INPUT -i LOGO -filter_complex "[0:v]hwupload[a], [1:v]format=yuv420p, hwupload[b], [a][b]overlay_vaapi" OUTPUT
23270
23271       •   Overlay an image LOGO at the offset (200, 100) from the top-left
23272           corner of the INPUT video.  The inputs have same memory layout for
23273           color channels, the overlay has additional alpha plane, like INPUT
23274           is yuv420p, and the LOGO is yuva420p.
23275
23276                   -i INPUT -i LOGO -filter_complex "[0:v]hwupload[a], [1:v]format=yuva420p, hwupload[b], [a][b]overlay_vaapi=x=200:y=100:w=400:h=300:alpha=1.0, hwdownload, format=nv12" OUTPUT
23277
23278   tonemap_vaapi
23279       Perform HDR(High Dynamic Range) to SDR(Standard Dynamic Range)
23280       conversion with tone-mapping.  It maps the dynamic range of HDR10
23281       content to the SDR content.  It currently only accepts HDR10 as input.
23282
23283       It accepts the following parameters:
23284
23285       format
23286           Specify the output pixel format.
23287
23288           Currently supported formats are:
23289
23290           p010
23291           nv12
23292
23293           Default is nv12.
23294
23295       primaries, p
23296           Set the output color primaries.
23297
23298           Default is same as input.
23299
23300       transfer, t
23301           Set the output transfer characteristics.
23302
23303           Default is bt709.
23304
23305       matrix, m
23306           Set the output colorspace matrix.
23307
23308           Default is same as input.
23309
23310       Example
23311
23312       •   Convert HDR(HDR10) video to bt2020-transfer-characteristic p010
23313           format
23314
23315                   tonemap_vaapi=format=p010:t=bt2020-10
23316

VIDEO SOURCES

23318       Below is a description of the currently available video sources.
23319
23320   buffer
23321       Buffer video frames, and make them available to the filter chain.
23322
23323       This source is mainly intended for a programmatic use, in particular
23324       through the interface defined in libavfilter/buffersrc.h.
23325
23326       It accepts the following parameters:
23327
23328       video_size
23329           Specify the size (width and height) of the buffered video frames.
23330           For the syntax of this option, check the "Video size" section in
23331           the ffmpeg-utils manual.
23332
23333       width
23334           The input video width.
23335
23336       height
23337           The input video height.
23338
23339       pix_fmt
23340           A string representing the pixel format of the buffered video
23341           frames.  It may be a number corresponding to a pixel format, or a
23342           pixel format name.
23343
23344       time_base
23345           Specify the timebase assumed by the timestamps of the buffered
23346           frames.
23347
23348       frame_rate
23349           Specify the frame rate expected for the video stream.
23350
23351       pixel_aspect, sar
23352           The sample (pixel) aspect ratio of the input video.
23353
23354       sws_param
23355           This option is deprecated and ignored. Prepend "sws_flags=flags;"
23356           to the filtergraph description to specify swscale flags for
23357           automatically inserted scalers. See Filtergraph syntax.
23358
23359       hw_frames_ctx
23360           When using a hardware pixel format, this should be a reference to
23361           an AVHWFramesContext describing input frames.
23362
23363       For example:
23364
23365               buffer=width=320:height=240:pix_fmt=yuv410p:time_base=1/24:sar=1
23366
23367       will instruct the source to accept video frames with size 320x240 and
23368       with format "yuv410p", assuming 1/24 as the timestamps timebase and
23369       square pixels (1:1 sample aspect ratio).  Since the pixel format with
23370       name "yuv410p" corresponds to the number 6 (check the enum
23371       AVPixelFormat definition in libavutil/pixfmt.h), this example
23372       corresponds to:
23373
23374               buffer=size=320x240:pixfmt=6:time_base=1/24:pixel_aspect=1/1
23375
23376       Alternatively, the options can be specified as a flat string, but this
23377       syntax is deprecated:
23378
23379       width:height:pix_fmt:time_base.num:time_base.den:pixel_aspect.num:pixel_aspect.den
23380
23381   cellauto
23382       Create a pattern generated by an elementary cellular automaton.
23383
23384       The initial state of the cellular automaton can be defined through the
23385       filename and pattern options. If such options are not specified an
23386       initial state is created randomly.
23387
23388       At each new frame a new row in the video is filled with the result of
23389       the cellular automaton next generation. The behavior when the whole
23390       frame is filled is defined by the scroll option.
23391
23392       This source accepts the following options:
23393
23394       filename, f
23395           Read the initial cellular automaton state, i.e. the starting row,
23396           from the specified file.  In the file, each non-whitespace
23397           character is considered an alive cell, a newline will terminate the
23398           row, and further characters in the file will be ignored.
23399
23400       pattern, p
23401           Read the initial cellular automaton state, i.e. the starting row,
23402           from the specified string.
23403
23404           Each non-whitespace character in the string is considered an alive
23405           cell, a newline will terminate the row, and further characters in
23406           the string will be ignored.
23407
23408       rate, r
23409           Set the video rate, that is the number of frames generated per
23410           second.  Default is 25.
23411
23412       random_fill_ratio, ratio
23413           Set the random fill ratio for the initial cellular automaton row.
23414           It is a floating point number value ranging from 0 to 1, defaults
23415           to 1/PHI.
23416
23417           This option is ignored when a file or a pattern is specified.
23418
23419       random_seed, seed
23420           Set the seed for filling randomly the initial row, must be an
23421           integer included between 0 and UINT32_MAX. If not specified, or if
23422           explicitly set to -1, the filter will try to use a good random seed
23423           on a best effort basis.
23424
23425       rule
23426           Set the cellular automaton rule, it is a number ranging from 0 to
23427           255.  Default value is 110.
23428
23429       size, s
23430           Set the size of the output video. For the syntax of this option,
23431           check the "Video size" section in the ffmpeg-utils manual.
23432
23433           If filename or pattern is specified, the size is set by default to
23434           the width of the specified initial state row, and the height is set
23435           to width * PHI.
23436
23437           If size is set, it must contain the width of the specified pattern
23438           string, and the specified pattern will be centered in the larger
23439           row.
23440
23441           If a filename or a pattern string is not specified, the size value
23442           defaults to "320x518" (used for a randomly generated initial
23443           state).
23444
23445       scroll
23446           If set to 1, scroll the output upward when all the rows in the
23447           output have been already filled. If set to 0, the new generated row
23448           will be written over the top row just after the bottom row is
23449           filled.  Defaults to 1.
23450
23451       start_full, full
23452           If set to 1, completely fill the output with generated rows before
23453           outputting the first frame.  This is the default behavior, for
23454           disabling set the value to 0.
23455
23456       stitch
23457           If set to 1, stitch the left and right row edges together.  This is
23458           the default behavior, for disabling set the value to 0.
23459
23460       Examples
23461
23462       •   Read the initial state from pattern, and specify an output of size
23463           200x400.
23464
23465                   cellauto=f=pattern:s=200x400
23466
23467       •   Generate a random initial row with a width of 200 cells, with a
23468           fill ratio of 2/3:
23469
23470                   cellauto=ratio=2/3:s=200x200
23471
23472       •   Create a pattern generated by rule 18 starting by a single alive
23473           cell centered on an initial row with width 100:
23474
23475                   cellauto=p=@s=100x400:full=0:rule=18
23476
23477       •   Specify a more elaborated initial pattern:
23478
23479                   cellauto=p='@@ @ @@':s=100x400:full=0:rule=18
23480
23481   coreimagesrc
23482       Video source generated on GPU using Apple's CoreImage API on OSX.
23483
23484       This video source is a specialized version of the coreimage video
23485       filter.  Use a core image generator at the beginning of the applied
23486       filterchain to generate the content.
23487
23488       The coreimagesrc video source accepts the following options:
23489
23490       list_generators
23491           List all available generators along with all their respective
23492           options as well as possible minimum and maximum values along with
23493           the default values.
23494
23495                   list_generators=true
23496
23497       size, s
23498           Specify the size of the sourced video. For the syntax of this
23499           option, check the "Video size" section in the ffmpeg-utils manual.
23500           The default value is "320x240".
23501
23502       rate, r
23503           Specify the frame rate of the sourced video, as the number of
23504           frames generated per second. It has to be a string in the format
23505           frame_rate_num/frame_rate_den, an integer number, a floating point
23506           number or a valid video frame rate abbreviation. The default value
23507           is "25".
23508
23509       sar Set the sample aspect ratio of the sourced video.
23510
23511       duration, d
23512           Set the duration of the sourced video. See the Time duration
23513           section in the ffmpeg-utils(1) manual for the accepted syntax.
23514
23515           If not specified, or the expressed duration is negative, the video
23516           is supposed to be generated forever.
23517
23518       Additionally, all options of the coreimage video filter are accepted.
23519       A complete filterchain can be used for further processing of the
23520       generated input without CPU-HOST transfer. See coreimage documentation
23521       and examples for details.
23522
23523       Examples
23524
23525       •   Use CIQRCodeGenerator to create a QR code for the FFmpeg homepage,
23526           given as complete and escaped command-line for Apple's standard
23527           bash shell:
23528
23529                   ffmpeg -f lavfi -i coreimagesrc=s=100x100:filter=CIQRCodeGenerator@inputMessage=https\\\\\://FFmpeg.org/@inputCorrectionLevel=H -frames:v 1 QRCode.png
23530
23531           This example is equivalent to the QRCode example of coreimage
23532           without the need for a nullsrc video source.
23533
23534   gradients
23535       Generate several gradients.
23536
23537       size, s
23538           Set frame size. For the syntax of this option, check the "Video
23539           size" section in the ffmpeg-utils manual. Default value is
23540           "640x480".
23541
23542       rate, r
23543           Set frame rate, expressed as number of frames per second. Default
23544           value is "25".
23545
23546       c0, c1, c2, c3, c4, c5, c6, c7
23547           Set 8 colors. Default values for colors is to pick random one.
23548
23549       x0, y0, y0, y1
23550           Set gradient line source and destination points. If negative or out
23551           of range, random ones are picked.
23552
23553       nb_colors, n
23554           Set number of colors to use at once. Allowed range is from 2 to 8.
23555           Default value is 2.
23556
23557       seed
23558           Set seed for picking gradient line points.
23559
23560       duration, d
23561           Set the duration of the sourced video. See the Time duration
23562           section in the ffmpeg-utils(1) manual for the accepted syntax.
23563
23564           If not specified, or the expressed duration is negative, the video
23565           is supposed to be generated forever.
23566
23567       speed
23568           Set speed of gradients rotation.
23569
23570       type, t
23571           Set type of gradients, can be "linear" or "radial" or "circular" or
23572           "spiral".
23573
23574   mandelbrot
23575       Generate a Mandelbrot set fractal, and progressively zoom towards the
23576       point specified with start_x and start_y.
23577
23578       This source accepts the following options:
23579
23580       end_pts
23581           Set the terminal pts value. Default value is 400.
23582
23583       end_scale
23584           Set the terminal scale value.  Must be a floating point value.
23585           Default value is 0.3.
23586
23587       inner
23588           Set the inner coloring mode, that is the algorithm used to draw the
23589           Mandelbrot fractal internal region.
23590
23591           It shall assume one of the following values:
23592
23593           black
23594               Set black mode.
23595
23596           convergence
23597               Show time until convergence.
23598
23599           mincol
23600               Set color based on point closest to the origin of the
23601               iterations.
23602
23603           period
23604               Set period mode.
23605
23606           Default value is mincol.
23607
23608       bailout
23609           Set the bailout value. Default value is 10.0.
23610
23611       maxiter
23612           Set the maximum of iterations performed by the rendering algorithm.
23613           Default value is 7189.
23614
23615       outer
23616           Set outer coloring mode.  It shall assume one of following values:
23617
23618           iteration_count
23619               Set iteration count mode.
23620
23621           normalized_iteration_count
23622               set normalized iteration count mode.
23623
23624           Default value is normalized_iteration_count.
23625
23626       rate, r
23627           Set frame rate, expressed as number of frames per second. Default
23628           value is "25".
23629
23630       size, s
23631           Set frame size. For the syntax of this option, check the "Video
23632           size" section in the ffmpeg-utils manual. Default value is
23633           "640x480".
23634
23635       start_scale
23636           Set the initial scale value. Default value is 3.0.
23637
23638       start_x
23639           Set the initial x position. Must be a floating point value between
23640           -100 and 100. Default value is
23641           -0.743643887037158704752191506114774.
23642
23643       start_y
23644           Set the initial y position. Must be a floating point value between
23645           -100 and 100. Default value is
23646           -0.131825904205311970493132056385139.
23647
23648   mptestsrc
23649       Generate various test patterns, as generated by the MPlayer test
23650       filter.
23651
23652       The size of the generated video is fixed, and is 256x256.  This source
23653       is useful in particular for testing encoding features.
23654
23655       This source accepts the following options:
23656
23657       rate, r
23658           Specify the frame rate of the sourced video, as the number of
23659           frames generated per second. It has to be a string in the format
23660           frame_rate_num/frame_rate_den, an integer number, a floating point
23661           number or a valid video frame rate abbreviation. The default value
23662           is "25".
23663
23664       duration, d
23665           Set the duration of the sourced video. See the Time duration
23666           section in the ffmpeg-utils(1) manual for the accepted syntax.
23667
23668           If not specified, or the expressed duration is negative, the video
23669           is supposed to be generated forever.
23670
23671       test, t
23672           Set the number or the name of the test to perform. Supported tests
23673           are:
23674
23675           dc_luma
23676           dc_chroma
23677           freq_luma
23678           freq_chroma
23679           amp_luma
23680           amp_chroma
23681           cbp
23682           mv
23683           ring1
23684           ring2
23685           all
23686           max_frames, m
23687               Set the maximum number of frames generated for each test,
23688               default value is 30.
23689
23690           Default value is "all", which will cycle through the list of all
23691           tests.
23692
23693       Some examples:
23694
23695               mptestsrc=t=dc_luma
23696
23697       will generate a "dc_luma" test pattern.
23698
23699   frei0r_src
23700       Provide a frei0r source.
23701
23702       To enable compilation of this filter you need to install the frei0r
23703       header and configure FFmpeg with "--enable-frei0r".
23704
23705       This source accepts the following parameters:
23706
23707       size
23708           The size of the video to generate. For the syntax of this option,
23709           check the "Video size" section in the ffmpeg-utils manual.
23710
23711       framerate
23712           The framerate of the generated video. It may be a string of the
23713           form num/den or a frame rate abbreviation.
23714
23715       filter_name
23716           The name to the frei0r source to load. For more information
23717           regarding frei0r and how to set the parameters, read the frei0r
23718           section in the video filters documentation.
23719
23720       filter_params
23721           A '|'-separated list of parameters to pass to the frei0r source.
23722
23723       For example, to generate a frei0r partik0l source with size 200x200 and
23724       frame rate 10 which is overlaid on the overlay filter main input:
23725
23726               frei0r_src=size=200x200:framerate=10:filter_name=partik0l:filter_params=1234 [overlay]; [in][overlay] overlay
23727
23728   life
23729       Generate a life pattern.
23730
23731       This source is based on a generalization of John Conway's life game.
23732
23733       The sourced input represents a life grid, each pixel represents a cell
23734       which can be in one of two possible states, alive or dead. Every cell
23735       interacts with its eight neighbours, which are the cells that are
23736       horizontally, vertically, or diagonally adjacent.
23737
23738       At each interaction the grid evolves according to the adopted rule,
23739       which specifies the number of neighbor alive cells which will make a
23740       cell stay alive or born. The rule option allows one to specify the rule
23741       to adopt.
23742
23743       This source accepts the following options:
23744
23745       filename, f
23746           Set the file from which to read the initial grid state. In the
23747           file, each non-whitespace character is considered an alive cell,
23748           and newline is used to delimit the end of each row.
23749
23750           If this option is not specified, the initial grid is generated
23751           randomly.
23752
23753       rate, r
23754           Set the video rate, that is the number of frames generated per
23755           second.  Default is 25.
23756
23757       random_fill_ratio, ratio
23758           Set the random fill ratio for the initial random grid. It is a
23759           floating point number value ranging from 0 to 1, defaults to 1/PHI.
23760           It is ignored when a file is specified.
23761
23762       random_seed, seed
23763           Set the seed for filling the initial random grid, must be an
23764           integer included between 0 and UINT32_MAX. If not specified, or if
23765           explicitly set to -1, the filter will try to use a good random seed
23766           on a best effort basis.
23767
23768       rule
23769           Set the life rule.
23770
23771           A rule can be specified with a code of the kind "SNS/BNB", where NS
23772           and NB are sequences of numbers in the range 0-8, NS specifies the
23773           number of alive neighbor cells which make a live cell stay alive,
23774           and NB the number of alive neighbor cells which make a dead cell to
23775           become alive (i.e. to "born").  "s" and "b" can be used in place of
23776           "S" and "B", respectively.
23777
23778           Alternatively a rule can be specified by an 18-bits integer. The 9
23779           high order bits are used to encode the next cell state if it is
23780           alive for each number of neighbor alive cells, the low order bits
23781           specify the rule for "borning" new cells. Higher order bits encode
23782           for an higher number of neighbor cells.  For example the number
23783           6153 = "(12<<9)+9" specifies a stay alive rule of 12 and a born
23784           rule of 9, which corresponds to "S23/B03".
23785
23786           Default value is "S23/B3", which is the original Conway's game of
23787           life rule, and will keep a cell alive if it has 2 or 3 neighbor
23788           alive cells, and will born a new cell if there are three alive
23789           cells around a dead cell.
23790
23791       size, s
23792           Set the size of the output video. For the syntax of this option,
23793           check the "Video size" section in the ffmpeg-utils manual.
23794
23795           If filename is specified, the size is set by default to the same
23796           size of the input file. If size is set, it must contain the size
23797           specified in the input file, and the initial grid defined in that
23798           file is centered in the larger resulting area.
23799
23800           If a filename is not specified, the size value defaults to
23801           "320x240" (used for a randomly generated initial grid).
23802
23803       stitch
23804           If set to 1, stitch the left and right grid edges together, and the
23805           top and bottom edges also. Defaults to 1.
23806
23807       mold
23808           Set cell mold speed. If set, a dead cell will go from death_color
23809           to mold_color with a step of mold. mold can have a value from 0 to
23810           255.
23811
23812       life_color
23813           Set the color of living (or new born) cells.
23814
23815       death_color
23816           Set the color of dead cells. If mold is set, this is the first
23817           color used to represent a dead cell.
23818
23819       mold_color
23820           Set mold color, for definitely dead and moldy cells.
23821
23822           For the syntax of these 3 color options, check the "Color" section
23823           in the ffmpeg-utils manual.
23824
23825       Examples
23826
23827       •   Read a grid from pattern, and center it on a grid of size 300x300
23828           pixels:
23829
23830                   life=f=pattern:s=300x300
23831
23832       •   Generate a random grid of size 200x200, with a fill ratio of 2/3:
23833
23834                   life=ratio=2/3:s=200x200
23835
23836       •   Specify a custom rule for evolving a randomly generated grid:
23837
23838                   life=rule=S14/B34
23839
23840       •   Full example with slow death effect (mold) using ffplay:
23841
23842                   ffplay -f lavfi life=s=300x200:mold=10:r=60:ratio=0.1:death_color=#C83232:life_color=#00ff00,scale=1200:800:flags=16
23843
23844   allrgb, allyuv, color, colorchart, colorspectrum, haldclutsrc, nullsrc,
23845       pal75bars, pal100bars, rgbtestsrc, smptebars, smptehdbars, testsrc,
23846       testsrc2, yuvtestsrc
23847       The "allrgb" source returns frames of size 4096x4096 of all rgb colors.
23848
23849       The "allyuv" source returns frames of size 4096x4096 of all yuv colors.
23850
23851       The "color" source provides an uniformly colored input.
23852
23853       The "colorchart" source provides a colors checker chart.
23854
23855       The "colorspectrum" source provides a color spectrum input.
23856
23857       The "haldclutsrc" source provides an identity Hald CLUT. See also
23858       haldclut filter.
23859
23860       The "nullsrc" source returns unprocessed video frames. It is mainly
23861       useful to be employed in analysis / debugging tools, or as the source
23862       for filters which ignore the input data.
23863
23864       The "pal75bars" source generates a color bars pattern, based on EBU PAL
23865       recommendations with 75% color levels.
23866
23867       The "pal100bars" source generates a color bars pattern, based on EBU
23868       PAL recommendations with 100% color levels.
23869
23870       The "rgbtestsrc" source generates an RGB test pattern useful for
23871       detecting RGB vs BGR issues. You should see a red, green and blue
23872       stripe from top to bottom.
23873
23874       The "smptebars" source generates a color bars pattern, based on the
23875       SMPTE Engineering Guideline EG 1-1990.
23876
23877       The "smptehdbars" source generates a color bars pattern, based on the
23878       SMPTE RP 219-2002.
23879
23880       The "testsrc" source generates a test video pattern, showing a color
23881       pattern, a scrolling gradient and a timestamp. This is mainly intended
23882       for testing purposes.
23883
23884       The "testsrc2" source is similar to testsrc, but supports more pixel
23885       formats instead of just "rgb24". This allows using it as an input for
23886       other tests without requiring a format conversion.
23887
23888       The "yuvtestsrc" source generates an YUV test pattern. You should see a
23889       y, cb and cr stripe from top to bottom.
23890
23891       The sources accept the following parameters:
23892
23893       level
23894           Specify the level of the Hald CLUT, only available in the
23895           "haldclutsrc" source. A level of "N" generates a picture of "N*N*N"
23896           by "N*N*N" pixels to be used as identity matrix for 3D lookup
23897           tables. Each component is coded on a "1/(N*N)" scale.
23898
23899       color, c
23900           Specify the color of the source, only available in the "color"
23901           source. For the syntax of this option, check the "Color" section in
23902           the ffmpeg-utils manual.
23903
23904       size, s
23905           Specify the size of the sourced video. For the syntax of this
23906           option, check the "Video size" section in the ffmpeg-utils manual.
23907           The default value is "320x240".
23908
23909           This option is not available with the "allrgb", "allyuv", and
23910           "haldclutsrc" filters.
23911
23912       rate, r
23913           Specify the frame rate of the sourced video, as the number of
23914           frames generated per second. It has to be a string in the format
23915           frame_rate_num/frame_rate_den, an integer number, a floating point
23916           number or a valid video frame rate abbreviation. The default value
23917           is "25".
23918
23919       duration, d
23920           Set the duration of the sourced video. See the Time duration
23921           section in the ffmpeg-utils(1) manual for the accepted syntax.
23922
23923           If not specified, or the expressed duration is negative, the video
23924           is supposed to be generated forever.
23925
23926           Since the frame rate is used as time base, all frames including the
23927           last one will have their full duration. If the specified duration
23928           is not a multiple of the frame duration, it will be rounded up.
23929
23930       sar Set the sample aspect ratio of the sourced video.
23931
23932       alpha
23933           Specify the alpha (opacity) of the background, only available in
23934           the "testsrc2" source. The value must be between 0 (fully
23935           transparent) and 255 (fully opaque, the default).
23936
23937       decimals, n
23938           Set the number of decimals to show in the timestamp, only available
23939           in the "testsrc" source.
23940
23941           The displayed timestamp value will correspond to the original
23942           timestamp value multiplied by the power of 10 of the specified
23943           value. Default value is 0.
23944
23945       type
23946           Set the type of the color spectrum, only available in the
23947           "colorspectrum" source. Can be one of the following:
23948
23949           black
23950           white
23951           all
23952       patch_size
23953           Set patch size of single color patch, only available in the
23954           "colorchart" source. Default is "64x64".
23955
23956       preset
23957           Set colorchecker colors preset, only available in the "colorchart"
23958           source.
23959
23960           Available values are:
23961
23962           reference
23963           skintones
23964
23965           Default value is "reference".
23966
23967       Examples
23968
23969       •   Generate a video with a duration of 5.3 seconds, with size 176x144
23970           and a frame rate of 10 frames per second:
23971
23972                   testsrc=duration=5.3:size=qcif:rate=10
23973
23974       •   The following graph description will generate a red source with an
23975           opacity of 0.2, with size "qcif" and a frame rate of 10 frames per
23976           second:
23977
23978                   color=c=red@0.2:s=qcif:r=10
23979
23980       •   If the input content is to be ignored, "nullsrc" can be used. The
23981           following command generates noise in the luminance plane by
23982           employing the "geq" filter:
23983
23984                   nullsrc=s=256x256, geq=random(1)*255:128:128
23985
23986       Commands
23987
23988       The "color" source supports the following commands:
23989
23990       c, color
23991           Set the color of the created image. Accepts the same syntax of the
23992           corresponding color option.
23993
23994   openclsrc
23995       Generate video using an OpenCL program.
23996
23997       source
23998           OpenCL program source file.
23999
24000       kernel
24001           Kernel name in program.
24002
24003       size, s
24004           Size of frames to generate.  This must be set.
24005
24006       format
24007           Pixel format to use for the generated frames.  This must be set.
24008
24009       rate, r
24010           Number of frames generated every second.  Default value is '25'.
24011
24012       For details of how the program loading works, see the program_opencl
24013       filter.
24014
24015       Example programs:
24016
24017       •   Generate a colour ramp by setting pixel values from the position of
24018           the pixel in the output image.  (Note that this will work with all
24019           pixel formats, but the generated output will not be the same.)
24020
24021                   __kernel void ramp(__write_only image2d_t dst,
24022                                      unsigned int index)
24023                   {
24024                       int2 loc = (int2)(get_global_id(0), get_global_id(1));
24025
24026                       float4 val;
24027                       val.xy = val.zw = convert_float2(loc) / convert_float2(get_image_dim(dst));
24028
24029                       write_imagef(dst, loc, val);
24030                   }
24031
24032       •   Generate a Sierpinski carpet pattern, panning by a single pixel
24033           each frame.
24034
24035                   __kernel void sierpinski_carpet(__write_only image2d_t dst,
24036                                                   unsigned int index)
24037                   {
24038                       int2 loc = (int2)(get_global_id(0), get_global_id(1));
24039
24040                       float4 value = 0.0f;
24041                       int x = loc.x + index;
24042                       int y = loc.y + index;
24043                       while (x > 0 || y > 0) {
24044                           if (x % 3 == 1 && y % 3 == 1) {
24045                               value = 1.0f;
24046                               break;
24047                           }
24048                           x /= 3;
24049                           y /= 3;
24050                       }
24051
24052                       write_imagef(dst, loc, value);
24053                   }
24054
24055   sierpinski
24056       Generate a Sierpinski carpet/triangle fractal, and randomly pan around.
24057
24058       This source accepts the following options:
24059
24060       size, s
24061           Set frame size. For the syntax of this option, check the "Video
24062           size" section in the ffmpeg-utils manual. Default value is
24063           "640x480".
24064
24065       rate, r
24066           Set frame rate, expressed as number of frames per second. Default
24067           value is "25".
24068
24069       seed
24070           Set seed which is used for random panning.
24071
24072       jump
24073           Set max jump for single pan destination. Allowed range is from 1 to
24074           10000.
24075
24076       type
24077           Set fractal type, can be default "carpet" or "triangle".
24078

VIDEO SINKS

24080       Below is a description of the currently available video sinks.
24081
24082   buffersink
24083       Buffer video frames, and make them available to the end of the filter
24084       graph.
24085
24086       This sink is mainly intended for programmatic use, in particular
24087       through the interface defined in libavfilter/buffersink.h or the
24088       options system.
24089
24090       It accepts a pointer to an AVBufferSinkContext structure, which defines
24091       the incoming buffers' formats, to be passed as the opaque parameter to
24092       "avfilter_init_filter" for initialization.
24093
24094   nullsink
24095       Null video sink: do absolutely nothing with the input video. It is
24096       mainly useful as a template and for use in analysis / debugging tools.
24097

MULTIMEDIA FILTERS

24099       Below is a description of the currently available multimedia filters.
24100
24101   abitscope
24102       Convert input audio to a video output, displaying the audio bit scope.
24103
24104       The filter accepts the following options:
24105
24106       rate, r
24107           Set frame rate, expressed as number of frames per second. Default
24108           value is "25".
24109
24110       size, s
24111           Specify the video size for the output. For the syntax of this
24112           option, check the "Video size" section in the ffmpeg-utils manual.
24113           Default value is "1024x256".
24114
24115       colors
24116           Specify list of colors separated by space or by '|' which will be
24117           used to draw channels. Unrecognized or missing colors will be
24118           replaced by white color.
24119
24120       mode, m
24121           Set output mode. Can be "bars" or "trace". Default is "bars".
24122
24123   adrawgraph
24124       Draw a graph using input audio metadata.
24125
24126       See drawgraph
24127
24128   agraphmonitor
24129       See graphmonitor.
24130
24131   ahistogram
24132       Convert input audio to a video output, displaying the volume histogram.
24133
24134       The filter accepts the following options:
24135
24136       dmode
24137           Specify how histogram is calculated.
24138
24139           It accepts the following values:
24140
24141           single
24142               Use single histogram for all channels.
24143
24144           separate
24145               Use separate histogram for each channel.
24146
24147           Default is "single".
24148
24149       rate, r
24150           Set frame rate, expressed as number of frames per second. Default
24151           value is "25".
24152
24153       size, s
24154           Specify the video size for the output. For the syntax of this
24155           option, check the "Video size" section in the ffmpeg-utils manual.
24156           Default value is "hd720".
24157
24158       scale
24159           Set display scale.
24160
24161           It accepts the following values:
24162
24163           log logarithmic
24164
24165           sqrt
24166               square root
24167
24168           cbrt
24169               cubic root
24170
24171           lin linear
24172
24173           rlog
24174               reverse logarithmic
24175
24176           Default is "log".
24177
24178       ascale
24179           Set amplitude scale.
24180
24181           It accepts the following values:
24182
24183           log logarithmic
24184
24185           lin linear
24186
24187           Default is "log".
24188
24189       acount
24190           Set how much frames to accumulate in histogram.  Default is 1.
24191           Setting this to -1 accumulates all frames.
24192
24193       rheight
24194           Set histogram ratio of window height.
24195
24196       slide
24197           Set sonogram sliding.
24198
24199           It accepts the following values:
24200
24201           replace
24202               replace old rows with new ones.
24203
24204           scroll
24205               scroll from top to bottom.
24206
24207           Default is "replace".
24208
24209       hmode
24210           Set histogram mode.
24211
24212           It accepts the following values:
24213
24214           abs Use absolute values of samples.
24215
24216           sign
24217               Use untouched values of samples.
24218
24219           Default is "abs".
24220
24221   aphasemeter
24222       Measures phase of input audio, which is exported as metadata
24223       "lavfi.aphasemeter.phase", representing mean phase of current audio
24224       frame. A video output can also be produced and is enabled by default.
24225       The audio is passed through as first output.
24226
24227       Audio will be rematrixed to stereo if it has a different channel
24228       layout. Phase value is in range "[-1, 1]" where "-1" means left and
24229       right channels are completely out of phase and 1 means channels are in
24230       phase.
24231
24232       The filter accepts the following options, all related to its video
24233       output:
24234
24235       rate, r
24236           Set the output frame rate. Default value is 25.
24237
24238       size, s
24239           Set the video size for the output. For the syntax of this option,
24240           check the "Video size" section in the ffmpeg-utils manual.  Default
24241           value is "800x400".
24242
24243       rc
24244       gc
24245       bc  Specify the red, green, blue contrast. Default values are 2, 7 and
24246           1.  Allowed range is "[0, 255]".
24247
24248       mpc Set color which will be used for drawing median phase. If color is
24249           "none" which is default, no median phase value will be drawn.
24250
24251       video
24252           Enable video output. Default is enabled.
24253
24254       phasing detection
24255
24256       The filter also detects out of phase and mono sequences in stereo
24257       streams.  It logs the sequence start, end and duration when it lasts
24258       longer or as long as the minimum set.
24259
24260       The filter accepts the following options for this detection:
24261
24262       phasing
24263           Enable mono and out of phase detection. Default is disabled.
24264
24265       tolerance, t
24266           Set phase tolerance for mono detection, in amplitude ratio. Default
24267           is 0.  Allowed range is "[0, 1]".
24268
24269       angle, a
24270           Set angle threshold for out of phase detection, in degree. Default
24271           is 170.  Allowed range is "[90, 180]".
24272
24273       duration, d
24274           Set mono or out of phase duration until notification, expressed in
24275           seconds. Default is 2.
24276
24277       Examples
24278
24279       •   Complete example with ffmpeg to detect 1 second of mono with 0.001
24280           phase tolerance:
24281
24282                   ffmpeg -i stereo.wav -af aphasemeter=video=0:phasing=1:duration=1:tolerance=0.001 -f null -
24283
24284   avectorscope
24285       Convert input audio to a video output, representing the audio vector
24286       scope.
24287
24288       The filter is used to measure the difference between channels of stereo
24289       audio stream. A monaural signal, consisting of identical left and right
24290       signal, results in straight vertical line. Any stereo separation is
24291       visible as a deviation from this line, creating a Lissajous figure.  If
24292       the straight (or deviation from it) but horizontal line appears this
24293       indicates that the left and right channels are out of phase.
24294
24295       The filter accepts the following options:
24296
24297       mode, m
24298           Set the vectorscope mode.
24299
24300           Available values are:
24301
24302           lissajous
24303               Lissajous rotated by 45 degrees.
24304
24305           lissajous_xy
24306               Same as above but not rotated.
24307
24308           polar
24309               Shape resembling half of circle.
24310
24311           Default value is lissajous.
24312
24313       size, s
24314           Set the video size for the output. For the syntax of this option,
24315           check the "Video size" section in the ffmpeg-utils manual.  Default
24316           value is "400x400".
24317
24318       rate, r
24319           Set the output frame rate. Default value is 25.
24320
24321       rc
24322       gc
24323       bc
24324       ac  Specify the red, green, blue and alpha contrast. Default values are
24325           40, 160, 80 and 255.  Allowed range is "[0, 255]".
24326
24327       rf
24328       gf
24329       bf
24330       af  Specify the red, green, blue and alpha fade. Default values are 15,
24331           10, 5 and 5.  Allowed range is "[0, 255]".
24332
24333       zoom
24334           Set the zoom factor. Default value is 1. Allowed range is "[0,
24335           10]".  Values lower than 1 will auto adjust zoom factor to maximal
24336           possible value.
24337
24338       draw
24339           Set the vectorscope drawing mode.
24340
24341           Available values are:
24342
24343           dot Draw dot for each sample.
24344
24345           line
24346               Draw line between previous and current sample.
24347
24348           Default value is dot.
24349
24350       scale
24351           Specify amplitude scale of audio samples.
24352
24353           Available values are:
24354
24355           lin Linear.
24356
24357           sqrt
24358               Square root.
24359
24360           cbrt
24361               Cubic root.
24362
24363           log Logarithmic.
24364
24365       swap
24366           Swap left channel axis with right channel axis.
24367
24368       mirror
24369           Mirror axis.
24370
24371           none
24372               No mirror.
24373
24374           x   Mirror only x axis.
24375
24376           y   Mirror only y axis.
24377
24378           xy  Mirror both axis.
24379
24380       Examples
24381
24382       •   Complete example using ffplay:
24383
24384                   ffplay -f lavfi 'amovie=input.mp3, asplit [a][out1];
24385                                [a] avectorscope=zoom=1.3:rc=2:gc=200:bc=10:rf=1:gf=8:bf=7 [out0]'
24386
24387       Commands
24388
24389       This filter supports the all above options as commands except options
24390       "size" and "rate".
24391
24392   bench, abench
24393       Benchmark part of a filtergraph.
24394
24395       The filter accepts the following options:
24396
24397       action
24398           Start or stop a timer.
24399
24400           Available values are:
24401
24402           start
24403               Get the current time, set it as frame metadata (using the key
24404               "lavfi.bench.start_time"), and forward the frame to the next
24405               filter.
24406
24407           stop
24408               Get the current time and fetch the "lavfi.bench.start_time"
24409               metadata from the input frame metadata to get the time
24410               difference. Time difference, average, maximum and minimum time
24411               (respectively "t", "avg", "max" and "min") are then printed.
24412               The timestamps are expressed in seconds.
24413
24414       Examples
24415
24416       •   Benchmark selectivecolor filter:
24417
24418                   bench=start,selectivecolor=reds=-.2 .12 -.49,bench=stop
24419
24420   concat
24421       Concatenate audio and video streams, joining them together one after
24422       the other.
24423
24424       The filter works on segments of synchronized video and audio streams.
24425       All segments must have the same number of streams of each type, and
24426       that will also be the number of streams at output.
24427
24428       The filter accepts the following options:
24429
24430       n   Set the number of segments. Default is 2.
24431
24432       v   Set the number of output video streams, that is also the number of
24433           video streams in each segment. Default is 1.
24434
24435       a   Set the number of output audio streams, that is also the number of
24436           audio streams in each segment. Default is 0.
24437
24438       unsafe
24439           Activate unsafe mode: do not fail if segments have a different
24440           format.
24441
24442       The filter has v+a outputs: first v video outputs, then a audio
24443       outputs.
24444
24445       There are nx(v+a) inputs: first the inputs for the first segment, in
24446       the same order as the outputs, then the inputs for the second segment,
24447       etc.
24448
24449       Related streams do not always have exactly the same duration, for
24450       various reasons including codec frame size or sloppy authoring. For
24451       that reason, related synchronized streams (e.g. a video and its audio
24452       track) should be concatenated at once. The concat filter will use the
24453       duration of the longest stream in each segment (except the last one),
24454       and if necessary pad shorter audio streams with silence.
24455
24456       For this filter to work correctly, all segments must start at timestamp
24457       0.
24458
24459       All corresponding streams must have the same parameters in all
24460       segments; the filtering system will automatically select a common pixel
24461       format for video streams, and a common sample format, sample rate and
24462       channel layout for audio streams, but other settings, such as
24463       resolution, must be converted explicitly by the user.
24464
24465       Different frame rates are acceptable but will result in variable frame
24466       rate at output; be sure to configure the output file to handle it.
24467
24468       Examples
24469
24470       •   Concatenate an opening, an episode and an ending, all in bilingual
24471           version (video in stream 0, audio in streams 1 and 2):
24472
24473                   ffmpeg -i opening.mkv -i episode.mkv -i ending.mkv -filter_complex \
24474                     '[0:0] [0:1] [0:2] [1:0] [1:1] [1:2] [2:0] [2:1] [2:2]
24475                      concat=n=3:v=1:a=2 [v] [a1] [a2]' \
24476                     -map '[v]' -map '[a1]' -map '[a2]' output.mkv
24477
24478       •   Concatenate two parts, handling audio and video separately, using
24479           the (a)movie sources, and adjusting the resolution:
24480
24481                   movie=part1.mp4, scale=512:288 [v1] ; amovie=part1.mp4 [a1] ;
24482                   movie=part2.mp4, scale=512:288 [v2] ; amovie=part2.mp4 [a2] ;
24483                   [v1] [v2] concat [outv] ; [a1] [a2] concat=v=0:a=1 [outa]
24484
24485           Note that a desync will happen at the stitch if the audio and video
24486           streams do not have exactly the same duration in the first file.
24487
24488       Commands
24489
24490       This filter supports the following commands:
24491
24492       next
24493           Close the current segment and step to the next one
24494
24495   ebur128
24496       EBU R128 scanner filter. This filter takes an audio stream and analyzes
24497       its loudness level. By default, it logs a message at a frequency of
24498       10Hz with the Momentary loudness (identified by "M"), Short-term
24499       loudness ("S"), Integrated loudness ("I") and Loudness Range ("LRA").
24500
24501       The filter can only analyze streams which have sample format is double-
24502       precision floating point. The input stream will be converted to this
24503       specification, if needed. Users may need to insert aformat and/or
24504       aresample filters after this filter to obtain the original parameters.
24505
24506       The filter also has a video output (see the video option) with a real
24507       time graph to observe the loudness evolution. The graphic contains the
24508       logged message mentioned above, so it is not printed anymore when this
24509       option is set, unless the verbose logging is set. The main graphing
24510       area contains the short-term loudness (3 seconds of analysis), and the
24511       gauge on the right is for the momentary loudness (400 milliseconds),
24512       but can optionally be configured to instead display short-term loudness
24513       (see gauge).
24514
24515       The green area marks a  +/- 1LU target range around the target loudness
24516       (-23LUFS by default, unless modified through target).
24517
24518       More information about the Loudness Recommendation EBU R128 on
24519       <http://tech.ebu.ch/loudness>.
24520
24521       The filter accepts the following options:
24522
24523       video
24524           Activate the video output. The audio stream is passed unchanged
24525           whether this option is set or no. The video stream will be the
24526           first output stream if activated. Default is 0.
24527
24528       size
24529           Set the video size. This option is for video only. For the syntax
24530           of this option, check the "Video size" section in the ffmpeg-utils
24531           manual.  Default and minimum resolution is "640x480".
24532
24533       meter
24534           Set the EBU scale meter. Default is 9. Common values are 9 and 18,
24535           respectively for EBU scale meter +9 and EBU scale meter +18. Any
24536           other integer value between this range is allowed.
24537
24538       metadata
24539           Set metadata injection. If set to 1, the audio input will be
24540           segmented into 100ms output frames, each of them containing various
24541           loudness information in metadata.  All the metadata keys are
24542           prefixed with "lavfi.r128.".
24543
24544           Default is 0.
24545
24546       framelog
24547           Force the frame logging level.
24548
24549           Available values are:
24550
24551           info
24552               information logging level
24553
24554           verbose
24555               verbose logging level
24556
24557           By default, the logging level is set to info. If the video or the
24558           metadata options are set, it switches to verbose.
24559
24560       peak
24561           Set peak mode(s).
24562
24563           Available modes can be cumulated (the option is a "flag" type).
24564           Possible values are:
24565
24566           none
24567               Disable any peak mode (default).
24568
24569           sample
24570               Enable sample-peak mode.
24571
24572               Simple peak mode looking for the higher sample value. It logs a
24573               message for sample-peak (identified by "SPK").
24574
24575           true
24576               Enable true-peak mode.
24577
24578               If enabled, the peak lookup is done on an over-sampled version
24579               of the input stream for better peak accuracy. It logs a message
24580               for true-peak.  (identified by "TPK") and true-peak per frame
24581               (identified by "FTPK").  This mode requires a build with
24582               "libswresample".
24583
24584       dualmono
24585           Treat mono input files as "dual mono". If a mono file is intended
24586           for playback on a stereo system, its EBU R128 measurement will be
24587           perceptually incorrect.  If set to "true", this option will
24588           compensate for this effect.  Multi-channel input files are not
24589           affected by this option.
24590
24591       panlaw
24592           Set a specific pan law to be used for the measurement of dual mono
24593           files.  This parameter is optional, and has a default value of
24594           -3.01dB.
24595
24596       target
24597           Set a specific target level (in LUFS) used as relative zero in the
24598           visualization.  This parameter is optional and has a default value
24599           of -23LUFS as specified by EBU R128. However, material published
24600           online may prefer a level of -16LUFS (e.g. for use with podcasts or
24601           video platforms).
24602
24603       gauge
24604           Set the value displayed by the gauge. Valid values are "momentary"
24605           and s "shortterm". By default the momentary value will be used, but
24606           in certain scenarios it may be more useful to observe the short
24607           term value instead (e.g.  live mixing).
24608
24609       scale
24610           Sets the display scale for the loudness. Valid parameters are
24611           "absolute" (in LUFS) or "relative" (LU) relative to the target.
24612           This only affects the video output, not the summary or continuous
24613           log output.
24614
24615       Examples
24616
24617       •   Real-time graph using ffplay, with a EBU scale meter +18:
24618
24619                   ffplay -f lavfi -i "amovie=input.mp3,ebur128=video=1:meter=18 [out0][out1]"
24620
24621       •   Run an analysis with ffmpeg:
24622
24623                   ffmpeg -nostats -i input.mp3 -filter_complex ebur128 -f null -
24624
24625   interleave, ainterleave
24626       Temporally interleave frames from several inputs.
24627
24628       "interleave" works with video inputs, "ainterleave" with audio.
24629
24630       These filters read frames from several inputs and send the oldest
24631       queued frame to the output.
24632
24633       Input streams must have well defined, monotonically increasing frame
24634       timestamp values.
24635
24636       In order to submit one frame to output, these filters need to enqueue
24637       at least one frame for each input, so they cannot work in case one
24638       input is not yet terminated and will not receive incoming frames.
24639
24640       For example consider the case when one input is a "select" filter which
24641       always drops input frames. The "interleave" filter will keep reading
24642       from that input, but it will never be able to send new frames to output
24643       until the input sends an end-of-stream signal.
24644
24645       Also, depending on inputs synchronization, the filters will drop frames
24646       in case one input receives more frames than the other ones, and the
24647       queue is already filled.
24648
24649       These filters accept the following options:
24650
24651       nb_inputs, n
24652           Set the number of different inputs, it is 2 by default.
24653
24654       duration
24655           How to determine the end-of-stream.
24656
24657           longest
24658               The duration of the longest input. (default)
24659
24660           shortest
24661               The duration of the shortest input.
24662
24663           first
24664               The duration of the first input.
24665
24666       Examples
24667
24668       •   Interleave frames belonging to different streams using ffmpeg:
24669
24670                   ffmpeg -i bambi.avi -i pr0n.mkv -filter_complex "[0:v][1:v] interleave" out.avi
24671
24672       •   Add flickering blur effect:
24673
24674                   select='if(gt(random(0), 0.2), 1, 2)':n=2 [tmp], boxblur=2:2, [tmp] interleave
24675
24676   latency, alatency
24677       Measure filtering latency.
24678
24679       Report previous filter filtering latency, delay in number of audio
24680       samples for audio filters or number of video frames for video filters.
24681
24682       On end of input stream, filter will report min and max measured latency
24683       for previous running filter in filtergraph.
24684
24685   metadata, ametadata
24686       Manipulate frame metadata.
24687
24688       This filter accepts the following options:
24689
24690       mode
24691           Set mode of operation of the filter.
24692
24693           Can be one of the following:
24694
24695           select
24696               If both "value" and "key" is set, select frames which have such
24697               metadata. If only "key" is set, select every frame that has
24698               such key in metadata.
24699
24700           add Add new metadata "key" and "value". If key is already available
24701               do nothing.
24702
24703           modify
24704               Modify value of already present key.
24705
24706           delete
24707               If "value" is set, delete only keys that have such value.
24708               Otherwise, delete key. If "key" is not set, delete all metadata
24709               values in the frame.
24710
24711           print
24712               Print key and its value if metadata was found. If "key" is not
24713               set print all metadata values available in frame.
24714
24715       key Set key used with all modes. Must be set for all modes except
24716           "print" and "delete".
24717
24718       value
24719           Set metadata value which will be used. This option is mandatory for
24720           "modify" and "add" mode.
24721
24722       function
24723           Which function to use when comparing metadata value and "value".
24724
24725           Can be one of following:
24726
24727           same_str
24728               Values are interpreted as strings, returns true if metadata
24729               value is same as "value".
24730
24731           starts_with
24732               Values are interpreted as strings, returns true if metadata
24733               value starts with the "value" option string.
24734
24735           less
24736               Values are interpreted as floats, returns true if metadata
24737               value is less than "value".
24738
24739           equal
24740               Values are interpreted as floats, returns true if "value" is
24741               equal with metadata value.
24742
24743           greater
24744               Values are interpreted as floats, returns true if metadata
24745               value is greater than "value".
24746
24747           expr
24748               Values are interpreted as floats, returns true if expression
24749               from option "expr" evaluates to true.
24750
24751           ends_with
24752               Values are interpreted as strings, returns true if metadata
24753               value ends with the "value" option string.
24754
24755       expr
24756           Set expression which is used when "function" is set to "expr".  The
24757           expression is evaluated through the eval API and can contain the
24758           following constants:
24759
24760           VALUE1, FRAMEVAL
24761               Float representation of "value" from metadata key.
24762
24763           VALUE2, USERVAL
24764               Float representation of "value" as supplied by user in "value"
24765               option.
24766
24767       file
24768           If specified in "print" mode, output is written to the named file.
24769           Instead of plain filename any writable url can be specified.
24770           Filename ``-'' is a shorthand for standard output. If "file" option
24771           is not set, output is written to the log with AV_LOG_INFO loglevel.
24772
24773       direct
24774           Reduces buffering in print mode when output is written to a URL set
24775           using file.
24776
24777       Examples
24778
24779       •   Print all metadata values for frames with key
24780           "lavfi.signalstats.YDIF" with values between 0 and 1.
24781
24782                   signalstats,metadata=print:key=lavfi.signalstats.YDIF:value=0:function=expr:expr='between(VALUE1,0,1)'
24783
24784       •   Print silencedetect output to file metadata.txt.
24785
24786                   silencedetect,ametadata=mode=print:file=metadata.txt
24787
24788       •   Direct all metadata to a pipe with file descriptor 4.
24789
24790                   metadata=mode=print:file='pipe\:4'
24791
24792   perms, aperms
24793       Set read/write permissions for the output frames.
24794
24795       These filters are mainly aimed at developers to test direct path in the
24796       following filter in the filtergraph.
24797
24798       The filters accept the following options:
24799
24800       mode
24801           Select the permissions mode.
24802
24803           It accepts the following values:
24804
24805           none
24806               Do nothing. This is the default.
24807
24808           ro  Set all the output frames read-only.
24809
24810           rw  Set all the output frames directly writable.
24811
24812           toggle
24813               Make the frame read-only if writable, and writable if read-
24814               only.
24815
24816           random
24817               Set each output frame read-only or writable randomly.
24818
24819       seed
24820           Set the seed for the random mode, must be an integer included
24821           between 0 and "UINT32_MAX". If not specified, or if explicitly set
24822           to "-1", the filter will try to use a good random seed on a best
24823           effort basis.
24824
24825       Note: in case of auto-inserted filter between the permission filter and
24826       the following one, the permission might not be received as expected in
24827       that following filter. Inserting a format or aformat filter before the
24828       perms/aperms filter can avoid this problem.
24829
24830   realtime, arealtime
24831       Slow down filtering to match real time approximately.
24832
24833       These filters will pause the filtering for a variable amount of time to
24834       match the output rate with the input timestamps.  They are similar to
24835       the re option to "ffmpeg".
24836
24837       They accept the following options:
24838
24839       limit
24840           Time limit for the pauses. Any pause longer than that will be
24841           considered a timestamp discontinuity and reset the timer. Default
24842           is 2 seconds.
24843
24844       speed
24845           Speed factor for processing. The value must be a float larger than
24846           zero.  Values larger than 1.0 will result in faster than realtime
24847           processing, smaller will slow processing down. The limit is
24848           automatically adapted accordingly. Default is 1.0.
24849
24850           A processing speed faster than what is possible without these
24851           filters cannot be achieved.
24852
24853       Commands
24854
24855       Both filters supports the all above options as commands.
24856
24857   segment, asegment
24858       Split single input stream into multiple streams.
24859
24860       This filter does opposite of concat filters.
24861
24862       "segment" works on video frames, "asegment" on audio samples.
24863
24864       This filter accepts the following options:
24865
24866       timestamps
24867           Timestamps of output segments separated by '|'. The first segment
24868           will run from the beginning of the input stream. The last segment
24869           will run until the end of the input stream
24870
24871       frames, samples
24872           Exact frame/sample count to split the segments.
24873
24874       In all cases, prefixing an each segment with '+' will make it relative
24875       to the previous segment.
24876
24877       Examples
24878
24879       •   Split input audio stream into three output audio streams, starting
24880           at start of input audio stream and storing that in 1st output audio
24881           stream, then following at 60th second and storing than in 2nd
24882           output audio stream, and last after 150th second of input audio
24883           stream store in 3rd output audio stream:
24884
24885                   asegment=timestamps="60|150"
24886
24887   select, aselect
24888       Select frames to pass in output.
24889
24890       This filter accepts the following options:
24891
24892       expr, e
24893           Set expression, which is evaluated for each input frame.
24894
24895           If the expression is evaluated to zero, the frame is discarded.
24896
24897           If the evaluation result is negative or NaN, the frame is sent to
24898           the first output; otherwise it is sent to the output with index
24899           "ceil(val)-1", assuming that the input index starts from 0.
24900
24901           For example a value of 1.2 corresponds to the output with index
24902           "ceil(1.2)-1 = 2-1 = 1", that is the second output.
24903
24904       outputs, n
24905           Set the number of outputs. The output to which to send the selected
24906           frame is based on the result of the evaluation. Default value is 1.
24907
24908       The expression can contain the following constants:
24909
24910       n   The (sequential) number of the filtered frame, starting from 0.
24911
24912       selected_n
24913           The (sequential) number of the selected frame, starting from 0.
24914
24915       prev_selected_n
24916           The sequential number of the last selected frame. It's NAN if
24917           undefined.
24918
24919       TB  The timebase of the input timestamps.
24920
24921       pts The PTS (Presentation TimeStamp) of the filtered frame, expressed
24922           in TB units. It's NAN if undefined.
24923
24924       t   The PTS of the filtered frame, expressed in seconds. It's NAN if
24925           undefined.
24926
24927       prev_pts
24928           The PTS of the previously filtered frame. It's NAN if undefined.
24929
24930       prev_selected_pts
24931           The PTS of the last previously filtered frame. It's NAN if
24932           undefined.
24933
24934       prev_selected_t
24935           The PTS of the last previously selected frame, expressed in
24936           seconds. It's NAN if undefined.
24937
24938       start_pts
24939           The first PTS in the stream which is not NAN. It remains NAN if not
24940           found.
24941
24942       start_t
24943           The first PTS, in seconds, in the stream which is not NAN. It
24944           remains NAN if not found.
24945
24946       pict_type (video only)
24947           The type of the filtered frame. It can assume one of the following
24948           values:
24949
24950           I
24951           P
24952           B
24953           S
24954           SI
24955           SP
24956           BI
24957       interlace_type (video only)
24958           The frame interlace type. It can assume one of the following
24959           values:
24960
24961           PROGRESSIVE
24962               The frame is progressive (not interlaced).
24963
24964           TOPFIRST
24965               The frame is top-field-first.
24966
24967           BOTTOMFIRST
24968               The frame is bottom-field-first.
24969
24970       consumed_sample_n (audio only)
24971           the number of selected samples before the current frame
24972
24973       samples_n (audio only)
24974           the number of samples in the current frame
24975
24976       sample_rate (audio only)
24977           the input sample rate
24978
24979       key This is 1 if the filtered frame is a key-frame, 0 otherwise.
24980
24981       pos the position in the file of the filtered frame, -1 if the
24982           information is not available (e.g. for synthetic video)
24983
24984       scene (video only)
24985           value between 0 and 1 to indicate a new scene; a low value reflects
24986           a low probability for the current frame to introduce a new scene,
24987           while a higher value means the current frame is more likely to be
24988           one (see the example below)
24989
24990       concatdec_select
24991           The concat demuxer can select only part of a concat input file by
24992           setting an inpoint and an outpoint, but the output packets may not
24993           be entirely contained in the selected interval. By using this
24994           variable, it is possible to skip frames generated by the concat
24995           demuxer which are not exactly contained in the selected interval.
24996
24997           This works by comparing the frame pts against the
24998           lavf.concat.start_time and the lavf.concat.duration packet metadata
24999           values which are also present in the decoded frames.
25000
25001           The concatdec_select variable is -1 if the frame pts is at least
25002           start_time and either the duration metadata is missing or the frame
25003           pts is less than start_time + duration, 0 otherwise, and NaN if the
25004           start_time metadata is missing.
25005
25006           That basically means that an input frame is selected if its pts is
25007           within the interval set by the concat demuxer.
25008
25009       The default value of the select expression is "1".
25010
25011       Examples
25012
25013       •   Select all frames in input:
25014
25015                   select
25016
25017           The example above is the same as:
25018
25019                   select=1
25020
25021       •   Skip all frames:
25022
25023                   select=0
25024
25025       •   Select only I-frames:
25026
25027                   select='eq(pict_type\,I)'
25028
25029       •   Select one frame every 100:
25030
25031                   select='not(mod(n\,100))'
25032
25033       •   Select only frames contained in the 10-20 time interval:
25034
25035                   select=between(t\,10\,20)
25036
25037       •   Select only I-frames contained in the 10-20 time interval:
25038
25039                   select=between(t\,10\,20)*eq(pict_type\,I)
25040
25041       •   Select frames with a minimum distance of 10 seconds:
25042
25043                   select='isnan(prev_selected_t)+gte(t-prev_selected_t\,10)'
25044
25045       •   Use aselect to select only audio frames with samples number > 100:
25046
25047                   aselect='gt(samples_n\,100)'
25048
25049       •   Create a mosaic of the first scenes:
25050
25051                   ffmpeg -i video.avi -vf select='gt(scene\,0.4)',scale=160:120,tile -frames:v 1 preview.png
25052
25053           Comparing scene against a value between 0.3 and 0.5 is generally a
25054           sane choice.
25055
25056       •   Send even and odd frames to separate outputs, and compose them:
25057
25058                   select=n=2:e='mod(n, 2)+1' [odd][even]; [odd] pad=h=2*ih [tmp]; [tmp][even] overlay=y=h
25059
25060       •   Select useful frames from an ffconcat file which is using inpoints
25061           and outpoints but where the source files are not intra frame only.
25062
25063                   ffmpeg -copyts -vsync 0 -segment_time_metadata 1 -i input.ffconcat -vf select=concatdec_select -af aselect=concatdec_select output.avi
25064
25065   sendcmd, asendcmd
25066       Send commands to filters in the filtergraph.
25067
25068       These filters read commands to be sent to other filters in the
25069       filtergraph.
25070
25071       "sendcmd" must be inserted between two video filters, "asendcmd" must
25072       be inserted between two audio filters, but apart from that they act the
25073       same way.
25074
25075       The specification of commands can be provided in the filter arguments
25076       with the commands option, or in a file specified by the filename
25077       option.
25078
25079       These filters accept the following options:
25080
25081       commands, c
25082           Set the commands to be read and sent to the other filters.
25083
25084       filename, f
25085           Set the filename of the commands to be read and sent to the other
25086           filters.
25087
25088       Commands syntax
25089
25090       A commands description consists of a sequence of interval
25091       specifications, comprising a list of commands to be executed when a
25092       particular event related to that interval occurs. The occurring event
25093       is typically the current frame time entering or leaving a given time
25094       interval.
25095
25096       An interval is specified by the following syntax:
25097
25098               <START>[-<END>] <COMMANDS>;
25099
25100       The time interval is specified by the START and END times.  END is
25101       optional and defaults to the maximum time.
25102
25103       The current frame time is considered within the specified interval if
25104       it is included in the interval [START, END), that is when the time is
25105       greater or equal to START and is lesser than END.
25106
25107       COMMANDS consists of a sequence of one or more command specifications,
25108       separated by ",", relating to that interval.  The syntax of a command
25109       specification is given by:
25110
25111               [<FLAGS>] <TARGET> <COMMAND> <ARG>
25112
25113       FLAGS is optional and specifies the type of events relating to the time
25114       interval which enable sending the specified command, and must be a non-
25115       null sequence of identifier flags separated by "+" or "|" and enclosed
25116       between "[" and "]".
25117
25118       The following flags are recognized:
25119
25120       enter
25121           The command is sent when the current frame timestamp enters the
25122           specified interval. In other words, the command is sent when the
25123           previous frame timestamp was not in the given interval, and the
25124           current is.
25125
25126       leave
25127           The command is sent when the current frame timestamp leaves the
25128           specified interval. In other words, the command is sent when the
25129           previous frame timestamp was in the given interval, and the current
25130           is not.
25131
25132       expr
25133           The command ARG is interpreted as expression and result of
25134           expression is passed as ARG.
25135
25136           The expression is evaluated through the eval API and can contain
25137           the following constants:
25138
25139           POS Original position in the file of the frame, or undefined if
25140               undefined for the current frame.
25141
25142           PTS The presentation timestamp in input.
25143
25144           N   The count of the input frame for video or audio, starting from
25145               0.
25146
25147           T   The time in seconds of the current frame.
25148
25149           TS  The start time in seconds of the current command interval.
25150
25151           TE  The end time in seconds of the current command interval.
25152
25153           TI  The interpolated time of the current command interval, TI = (T
25154               - TS) / (TE - TS).
25155
25156           W   The video frame width.
25157
25158           H   The video frame height.
25159
25160       If FLAGS is not specified, a default value of "[enter]" is assumed.
25161
25162       TARGET specifies the target of the command, usually the name of the
25163       filter class or a specific filter instance name.
25164
25165       COMMAND specifies the name of the command for the target filter.
25166
25167       ARG is optional and specifies the optional list of argument for the
25168       given COMMAND.
25169
25170       Between one interval specification and another, whitespaces, or
25171       sequences of characters starting with "#" until the end of line, are
25172       ignored and can be used to annotate comments.
25173
25174       A simplified BNF description of the commands specification syntax
25175       follows:
25176
25177               <COMMAND_FLAG>  ::= "enter" | "leave"
25178               <COMMAND_FLAGS> ::= <COMMAND_FLAG> [(+|"|")<COMMAND_FLAG>]
25179               <COMMAND>       ::= ["[" <COMMAND_FLAGS> "]"] <TARGET> <COMMAND> [<ARG>]
25180               <COMMANDS>      ::= <COMMAND> [,<COMMANDS>]
25181               <INTERVAL>      ::= <START>[-<END>] <COMMANDS>
25182               <INTERVALS>     ::= <INTERVAL>[;<INTERVALS>]
25183
25184       Examples
25185
25186       •   Specify audio tempo change at second 4:
25187
25188                   asendcmd=c='4.0 atempo tempo 1.5',atempo
25189
25190       •   Target a specific filter instance:
25191
25192                   asendcmd=c='4.0 atempo@my tempo 1.5',atempo@my
25193
25194       •   Specify a list of drawtext and hue commands in a file.
25195
25196                   # show text in the interval 5-10
25197                   5.0-10.0 [enter] drawtext reinit 'fontfile=FreeSerif.ttf:text=hello world',
25198                            [leave] drawtext reinit 'fontfile=FreeSerif.ttf:text=';
25199
25200                   # desaturate the image in the interval 15-20
25201                   15.0-20.0 [enter] hue s 0,
25202                             [enter] drawtext reinit 'fontfile=FreeSerif.ttf:text=nocolor',
25203                             [leave] hue s 1,
25204                             [leave] drawtext reinit 'fontfile=FreeSerif.ttf:text=color';
25205
25206                   # apply an exponential saturation fade-out effect, starting from time 25
25207                   25 [enter] hue s exp(25-t)
25208
25209           A filtergraph allowing to read and process the above command list
25210           stored in a file test.cmd, can be specified with:
25211
25212                   sendcmd=f=test.cmd,drawtext=fontfile=FreeSerif.ttf:text='',hue
25213
25214   setpts, asetpts
25215       Change the PTS (presentation timestamp) of the input frames.
25216
25217       "setpts" works on video frames, "asetpts" on audio frames.
25218
25219       This filter accepts the following options:
25220
25221       expr
25222           The expression which is evaluated for each frame to construct its
25223           timestamp.
25224
25225       The expression is evaluated through the eval API and can contain the
25226       following constants:
25227
25228       FRAME_RATE, FR
25229           frame rate, only defined for constant frame-rate video
25230
25231       PTS The presentation timestamp in input
25232
25233       N   The count of the input frame for video or the number of consumed
25234           samples, not including the current frame for audio, starting from
25235           0.
25236
25237       NB_CONSUMED_SAMPLES
25238           The number of consumed samples, not including the current frame
25239           (only audio)
25240
25241       NB_SAMPLES, S
25242           The number of samples in the current frame (only audio)
25243
25244       SAMPLE_RATE, SR
25245           The audio sample rate.
25246
25247       STARTPTS
25248           The PTS of the first frame.
25249
25250       STARTT
25251           the time in seconds of the first frame
25252
25253       INTERLACED
25254           State whether the current frame is interlaced.
25255
25256       T   the time in seconds of the current frame
25257
25258       POS original position in the file of the frame, or undefined if
25259           undefined for the current frame
25260
25261       PREV_INPTS
25262           The previous input PTS.
25263
25264       PREV_INT
25265           previous input time in seconds
25266
25267       PREV_OUTPTS
25268           The previous output PTS.
25269
25270       PREV_OUTT
25271           previous output time in seconds
25272
25273       RTCTIME
25274           The wallclock (RTC) time in microseconds. This is deprecated, use
25275           time(0) instead.
25276
25277       RTCSTART
25278           The wallclock (RTC) time at the start of the movie in microseconds.
25279
25280       TB  The timebase of the input timestamps.
25281
25282       Examples
25283
25284       •   Start counting PTS from zero
25285
25286                   setpts=PTS-STARTPTS
25287
25288       •   Apply fast motion effect:
25289
25290                   setpts=0.5*PTS
25291
25292       •   Apply slow motion effect:
25293
25294                   setpts=2.0*PTS
25295
25296       •   Set fixed rate of 25 frames per second:
25297
25298                   setpts=N/(25*TB)
25299
25300       •   Set fixed rate 25 fps with some jitter:
25301
25302                   setpts='1/(25*TB) * (N + 0.05 * sin(N*2*PI/25))'
25303
25304       •   Apply an offset of 10 seconds to the input PTS:
25305
25306                   setpts=PTS+10/TB
25307
25308       •   Generate timestamps from a "live source" and rebase onto the
25309           current timebase:
25310
25311                   setpts='(RTCTIME - RTCSTART) / (TB * 1000000)'
25312
25313       •   Generate timestamps by counting samples:
25314
25315                   asetpts=N/SR/TB
25316
25317   setrange
25318       Force color range for the output video frame.
25319
25320       The "setrange" filter marks the color range property for the output
25321       frames. It does not change the input frame, but only sets the
25322       corresponding property, which affects how the frame is treated by
25323       following filters.
25324
25325       The filter accepts the following options:
25326
25327       range
25328           Available values are:
25329
25330           auto
25331               Keep the same color range property.
25332
25333           unspecified, unknown
25334               Set the color range as unspecified.
25335
25336           limited, tv, mpeg
25337               Set the color range as limited.
25338
25339           full, pc, jpeg
25340               Set the color range as full.
25341
25342   settb, asettb
25343       Set the timebase to use for the output frames timestamps.  It is mainly
25344       useful for testing timebase configuration.
25345
25346       It accepts the following parameters:
25347
25348       expr, tb
25349           The expression which is evaluated into the output timebase.
25350
25351       The value for tb is an arithmetic expression representing a rational.
25352       The expression can contain the constants "AVTB" (the default timebase),
25353       "intb" (the input timebase) and "sr" (the sample rate, audio only).
25354       Default value is "intb".
25355
25356       Examples
25357
25358       •   Set the timebase to 1/25:
25359
25360                   settb=expr=1/25
25361
25362       •   Set the timebase to 1/10:
25363
25364                   settb=expr=0.1
25365
25366       •   Set the timebase to 1001/1000:
25367
25368                   settb=1+0.001
25369
25370       •   Set the timebase to 2*intb:
25371
25372                   settb=2*intb
25373
25374       •   Set the default timebase value:
25375
25376                   settb=AVTB
25377
25378   showcqt
25379       Convert input audio to a video output representing frequency spectrum
25380       logarithmically using Brown-Puckette constant Q transform algorithm
25381       with direct frequency domain coefficient calculation (but the transform
25382       itself is not really constant Q, instead the Q factor is actually
25383       variable/clamped), with musical tone scale, from E0 to D#10.
25384
25385       The filter accepts the following options:
25386
25387       size, s
25388           Specify the video size for the output. It must be even. For the
25389           syntax of this option, check the "Video size" section in the
25390           ffmpeg-utils manual.  Default value is "1920x1080".
25391
25392       fps, rate, r
25393           Set the output frame rate. Default value is 25.
25394
25395       bar_h
25396           Set the bargraph height. It must be even. Default value is "-1"
25397           which computes the bargraph height automatically.
25398
25399       axis_h
25400           Set the axis height. It must be even. Default value is "-1" which
25401           computes the axis height automatically.
25402
25403       sono_h
25404           Set the sonogram height. It must be even. Default value is "-1"
25405           which computes the sonogram height automatically.
25406
25407       fullhd
25408           Set the fullhd resolution. This option is deprecated, use size, s
25409           instead. Default value is 1.
25410
25411       sono_v, volume
25412           Specify the sonogram volume expression. It can contain variables:
25413
25414           bar_v
25415               the bar_v evaluated expression
25416
25417           frequency, freq, f
25418               the frequency where it is evaluated
25419
25420           timeclamp, tc
25421               the value of timeclamp option
25422
25423           and functions:
25424
25425           a_weighting(f)
25426               A-weighting of equal loudness
25427
25428           b_weighting(f)
25429               B-weighting of equal loudness
25430
25431           c_weighting(f)
25432               C-weighting of equal loudness.
25433
25434           Default value is 16.
25435
25436       bar_v, volume2
25437           Specify the bargraph volume expression. It can contain variables:
25438
25439           sono_v
25440               the sono_v evaluated expression
25441
25442           frequency, freq, f
25443               the frequency where it is evaluated
25444
25445           timeclamp, tc
25446               the value of timeclamp option
25447
25448           and functions:
25449
25450           a_weighting(f)
25451               A-weighting of equal loudness
25452
25453           b_weighting(f)
25454               B-weighting of equal loudness
25455
25456           c_weighting(f)
25457               C-weighting of equal loudness.
25458
25459           Default value is "sono_v".
25460
25461       sono_g, gamma
25462           Specify the sonogram gamma. Lower gamma makes the spectrum more
25463           contrast, higher gamma makes the spectrum having more range.
25464           Default value is 3.  Acceptable range is "[1, 7]".
25465
25466       bar_g, gamma2
25467           Specify the bargraph gamma. Default value is 1. Acceptable range is
25468           "[1, 7]".
25469
25470       bar_t
25471           Specify the bargraph transparency level. Lower value makes the
25472           bargraph sharper.  Default value is 1. Acceptable range is "[0,
25473           1]".
25474
25475       timeclamp, tc
25476           Specify the transform timeclamp. At low frequency, there is trade-
25477           off between accuracy in time domain and frequency domain. If
25478           timeclamp is lower, event in time domain is represented more
25479           accurately (such as fast bass drum), otherwise event in frequency
25480           domain is represented more accurately (such as bass guitar).
25481           Acceptable range is "[0.002, 1]". Default value is 0.17.
25482
25483       attack
25484           Set attack time in seconds. The default is 0 (disabled). Otherwise,
25485           it limits future samples by applying asymmetric windowing in time
25486           domain, useful when low latency is required. Accepted range is "[0,
25487           1]".
25488
25489       basefreq
25490           Specify the transform base frequency. Default value is
25491           20.01523126408007475, which is frequency 50 cents below E0.
25492           Acceptable range is "[10, 100000]".
25493
25494       endfreq
25495           Specify the transform end frequency. Default value is
25496           20495.59681441799654, which is frequency 50 cents above D#10.
25497           Acceptable range is "[10, 100000]".
25498
25499       coeffclamp
25500           This option is deprecated and ignored.
25501
25502       tlength
25503           Specify the transform length in time domain. Use this option to
25504           control accuracy trade-off between time domain and frequency domain
25505           at every frequency sample.  It can contain variables:
25506
25507           frequency, freq, f
25508               the frequency where it is evaluated
25509
25510           timeclamp, tc
25511               the value of timeclamp option.
25512
25513           Default value is "384*tc/(384+tc*f)".
25514
25515       count
25516           Specify the transform count for every video frame. Default value is
25517           6.  Acceptable range is "[1, 30]".
25518
25519       fcount
25520           Specify the transform count for every single pixel. Default value
25521           is 0, which makes it computed automatically. Acceptable range is
25522           "[0, 10]".
25523
25524       fontfile
25525           Specify font file for use with freetype to draw the axis. If not
25526           specified, use embedded font. Note that drawing with font file or
25527           embedded font is not implemented with custom basefreq and endfreq,
25528           use axisfile option instead.
25529
25530       font
25531           Specify fontconfig pattern. This has lower priority than fontfile.
25532           The ":" in the pattern may be replaced by "|" to avoid unnecessary
25533           escaping.
25534
25535       fontcolor
25536           Specify font color expression. This is arithmetic expression that
25537           should return integer value 0xRRGGBB. It can contain variables:
25538
25539           frequency, freq, f
25540               the frequency where it is evaluated
25541
25542           timeclamp, tc
25543               the value of timeclamp option
25544
25545           and functions:
25546
25547           midi(f)
25548               midi number of frequency f, some midi numbers: E0(16), C1(24),
25549               C2(36), A4(69)
25550
25551           r(x), g(x), b(x)
25552               red, green, and blue value of intensity x.
25553
25554           Default value is "st(0, (midi(f)-59.5)/12); st(1,
25555           if(between(ld(0),0,1), 0.5-0.5*cos(2*PI*ld(0)), 0)); r(1-ld(1)) +
25556           b(ld(1))".
25557
25558       axisfile
25559           Specify image file to draw the axis. This option override fontfile
25560           and fontcolor option.
25561
25562       axis, text
25563           Enable/disable drawing text to the axis. If it is set to 0, drawing
25564           to the axis is disabled, ignoring fontfile and axisfile option.
25565           Default value is 1.
25566
25567       csp Set colorspace. The accepted values are:
25568
25569           unspecified
25570               Unspecified (default)
25571
25572           bt709
25573               BT.709
25574
25575           fcc FCC
25576
25577           bt470bg
25578               BT.470BG or BT.601-6 625
25579
25580           smpte170m
25581               SMPTE-170M or BT.601-6 525
25582
25583           smpte240m
25584               SMPTE-240M
25585
25586           bt2020ncl
25587               BT.2020 with non-constant luminance
25588
25589       cscheme
25590           Set spectrogram color scheme. This is list of floating point values
25591           with format "left_r|left_g|left_b|right_r|right_g|right_b".  The
25592           default is "1|0.5|0|0|0.5|1".
25593
25594       Examples
25595
25596       •   Playing audio while showing the spectrum:
25597
25598                   ffplay -f lavfi 'amovie=a.mp3, asplit [a][out1]; [a] showcqt [out0]'
25599
25600       •   Same as above, but with frame rate 30 fps:
25601
25602                   ffplay -f lavfi 'amovie=a.mp3, asplit [a][out1]; [a] showcqt=fps=30:count=5 [out0]'
25603
25604       •   Playing at 1280x720:
25605
25606                   ffplay -f lavfi 'amovie=a.mp3, asplit [a][out1]; [a] showcqt=s=1280x720:count=4 [out0]'
25607
25608       •   Disable sonogram display:
25609
25610                   sono_h=0
25611
25612       •   A1 and its harmonics: A1, A2, (near)E3, A3:
25613
25614                   ffplay -f lavfi 'aevalsrc=0.1*sin(2*PI*55*t)+0.1*sin(4*PI*55*t)+0.1*sin(6*PI*55*t)+0.1*sin(8*PI*55*t),
25615                                    asplit[a][out1]; [a] showcqt [out0]'
25616
25617       •   Same as above, but with more accuracy in frequency domain:
25618
25619                   ffplay -f lavfi 'aevalsrc=0.1*sin(2*PI*55*t)+0.1*sin(4*PI*55*t)+0.1*sin(6*PI*55*t)+0.1*sin(8*PI*55*t),
25620                                    asplit[a][out1]; [a] showcqt=timeclamp=0.5 [out0]'
25621
25622       •   Custom volume:
25623
25624                   bar_v=10:sono_v=bar_v*a_weighting(f)
25625
25626       •   Custom gamma, now spectrum is linear to the amplitude.
25627
25628                   bar_g=2:sono_g=2
25629
25630       •   Custom tlength equation:
25631
25632                   tc=0.33:tlength='st(0,0.17); 384*tc / (384 / ld(0) + tc*f /(1-ld(0))) + 384*tc / (tc*f / ld(0) + 384 /(1-ld(0)))'
25633
25634       •   Custom fontcolor and fontfile, C-note is colored green, others are
25635           colored blue:
25636
25637                   fontcolor='if(mod(floor(midi(f)+0.5),12), 0x0000FF, g(1))':fontfile=myfont.ttf
25638
25639       •   Custom font using fontconfig:
25640
25641                   font='Courier New,Monospace,mono|bold'
25642
25643       •   Custom frequency range with custom axis using image file:
25644
25645                   axisfile=myaxis.png:basefreq=40:endfreq=10000
25646
25647   showfreqs
25648       Convert input audio to video output representing the audio power
25649       spectrum.  Audio amplitude is on Y-axis while frequency is on X-axis.
25650
25651       The filter accepts the following options:
25652
25653       size, s
25654           Specify size of video. For the syntax of this option, check the
25655           "Video size" section in the ffmpeg-utils manual.  Default is
25656           "1024x512".
25657
25658       rate, r
25659           Set video rate. Default is 25.
25660
25661       mode
25662           Set display mode.  This set how each frequency bin will be
25663           represented.
25664
25665           It accepts the following values:
25666
25667           line
25668           bar
25669           dot
25670
25671           Default is "bar".
25672
25673       ascale
25674           Set amplitude scale.
25675
25676           It accepts the following values:
25677
25678           lin Linear scale.
25679
25680           sqrt
25681               Square root scale.
25682
25683           cbrt
25684               Cubic root scale.
25685
25686           log Logarithmic scale.
25687
25688           Default is "log".
25689
25690       fscale
25691           Set frequency scale.
25692
25693           It accepts the following values:
25694
25695           lin Linear scale.
25696
25697           log Logarithmic scale.
25698
25699           rlog
25700               Reverse logarithmic scale.
25701
25702           Default is "lin".
25703
25704       win_size
25705           Set window size. Allowed range is from 16 to 65536.
25706
25707           Default is 2048
25708
25709       win_func
25710           Set windowing function.
25711
25712           It accepts the following values:
25713
25714           rect
25715           bartlett
25716           hanning
25717           hamming
25718           blackman
25719           welch
25720           flattop
25721           bharris
25722           bnuttall
25723           bhann
25724           sine
25725           nuttall
25726           lanczos
25727           gauss
25728           tukey
25729           dolph
25730           cauchy
25731           parzen
25732           poisson
25733           bohman
25734
25735           Default is "hanning".
25736
25737       overlap
25738           Set window overlap. In range "[0, 1]". Default is 1, which means
25739           optimal overlap for selected window function will be picked.
25740
25741       averaging
25742           Set time averaging. Setting this to 0 will display current maximal
25743           peaks.  Default is 1, which means time averaging is disabled.
25744
25745       colors
25746           Specify list of colors separated by space or by '|' which will be
25747           used to draw channel frequencies. Unrecognized or missing colors
25748           will be replaced by white color.
25749
25750       cmode
25751           Set channel display mode.
25752
25753           It accepts the following values:
25754
25755           combined
25756           separate
25757
25758           Default is "combined".
25759
25760       minamp
25761           Set minimum amplitude used in "log" amplitude scaler.
25762
25763       data
25764           Set data display mode.
25765
25766           It accepts the following values:
25767
25768           magnitude
25769           phase
25770           delay
25771
25772           Default is "magnitude".
25773
25774       channels
25775           Set channels to use when processing audio. By default all are
25776           processed.
25777
25778   showspatial
25779       Convert stereo input audio to a video output, representing the spatial
25780       relationship between two channels.
25781
25782       The filter accepts the following options:
25783
25784       size, s
25785           Specify the video size for the output. For the syntax of this
25786           option, check the "Video size" section in the ffmpeg-utils manual.
25787           Default value is "512x512".
25788
25789       win_size
25790           Set window size. Allowed range is from 1024 to 65536. Default size
25791           is 4096.
25792
25793       win_func
25794           Set window function.
25795
25796           It accepts the following values:
25797
25798           rect
25799           bartlett
25800           hann
25801           hanning
25802           hamming
25803           blackman
25804           welch
25805           flattop
25806           bharris
25807           bnuttall
25808           bhann
25809           sine
25810           nuttall
25811           lanczos
25812           gauss
25813           tukey
25814           dolph
25815           cauchy
25816           parzen
25817           poisson
25818           bohman
25819
25820           Default value is "hann".
25821
25822       overlap
25823           Set ratio of overlap window. Default value is 0.5.  When value is 1
25824           overlap is set to recommended size for specific window function
25825           currently used.
25826
25827   showspectrum
25828       Convert input audio to a video output, representing the audio frequency
25829       spectrum.
25830
25831       The filter accepts the following options:
25832
25833       size, s
25834           Specify the video size for the output. For the syntax of this
25835           option, check the "Video size" section in the ffmpeg-utils manual.
25836           Default value is "640x512".
25837
25838       slide
25839           Specify how the spectrum should slide along the window.
25840
25841           It accepts the following values:
25842
25843           replace
25844               the samples start again on the left when they reach the right
25845
25846           scroll
25847               the samples scroll from right to left
25848
25849           fullframe
25850               frames are only produced when the samples reach the right
25851
25852           rscroll
25853               the samples scroll from left to right
25854
25855           lreplace
25856               the samples start again on the right when they reach the left
25857
25858           Default value is "replace".
25859
25860       mode
25861           Specify display mode.
25862
25863           It accepts the following values:
25864
25865           combined
25866               all channels are displayed in the same row
25867
25868           separate
25869               all channels are displayed in separate rows
25870
25871           Default value is combined.
25872
25873       color
25874           Specify display color mode.
25875
25876           It accepts the following values:
25877
25878           channel
25879               each channel is displayed in a separate color
25880
25881           intensity
25882               each channel is displayed using the same color scheme
25883
25884           rainbow
25885               each channel is displayed using the rainbow color scheme
25886
25887           moreland
25888               each channel is displayed using the moreland color scheme
25889
25890           nebulae
25891               each channel is displayed using the nebulae color scheme
25892
25893           fire
25894               each channel is displayed using the fire color scheme
25895
25896           fiery
25897               each channel is displayed using the fiery color scheme
25898
25899           fruit
25900               each channel is displayed using the fruit color scheme
25901
25902           cool
25903               each channel is displayed using the cool color scheme
25904
25905           magma
25906               each channel is displayed using the magma color scheme
25907
25908           green
25909               each channel is displayed using the green color scheme
25910
25911           viridis
25912               each channel is displayed using the viridis color scheme
25913
25914           plasma
25915               each channel is displayed using the plasma color scheme
25916
25917           cividis
25918               each channel is displayed using the cividis color scheme
25919
25920           terrain
25921               each channel is displayed using the terrain color scheme
25922
25923           Default value is channel.
25924
25925       scale
25926           Specify scale used for calculating intensity color values.
25927
25928           It accepts the following values:
25929
25930           lin linear
25931
25932           sqrt
25933               square root, default
25934
25935           cbrt
25936               cubic root
25937
25938           log logarithmic
25939
25940           4thrt
25941               4th root
25942
25943           5thrt
25944               5th root
25945
25946           Default value is sqrt.
25947
25948       fscale
25949           Specify frequency scale.
25950
25951           It accepts the following values:
25952
25953           lin linear
25954
25955           log logarithmic
25956
25957           Default value is lin.
25958
25959       saturation
25960           Set saturation modifier for displayed colors. Negative values
25961           provide alternative color scheme. 0 is no saturation at all.
25962           Saturation must be in [-10.0, 10.0] range.  Default value is 1.
25963
25964       win_func
25965           Set window function.
25966
25967           It accepts the following values:
25968
25969           rect
25970           bartlett
25971           hann
25972           hanning
25973           hamming
25974           blackman
25975           welch
25976           flattop
25977           bharris
25978           bnuttall
25979           bhann
25980           sine
25981           nuttall
25982           lanczos
25983           gauss
25984           tukey
25985           dolph
25986           cauchy
25987           parzen
25988           poisson
25989           bohman
25990
25991           Default value is "hann".
25992
25993       orientation
25994           Set orientation of time vs frequency axis. Can be "vertical" or
25995           "horizontal". Default is "vertical".
25996
25997       overlap
25998           Set ratio of overlap window. Default value is 0.  When value is 1
25999           overlap is set to recommended size for specific window function
26000           currently used.
26001
26002       gain
26003           Set scale gain for calculating intensity color values.  Default
26004           value is 1.
26005
26006       data
26007           Set which data to display. Can be "magnitude", default or "phase",
26008           or unwrapped phase: "uphase".
26009
26010       rotation
26011           Set color rotation, must be in [-1.0, 1.0] range.  Default value is
26012           0.
26013
26014       start
26015           Set start frequency from which to display spectrogram. Default is
26016           0.
26017
26018       stop
26019           Set stop frequency to which to display spectrogram. Default is 0.
26020
26021       fps Set upper frame rate limit. Default is "auto", unlimited.
26022
26023       legend
26024           Draw time and frequency axes and legends. Default is disabled.
26025
26026       drange
26027           Set dynamic range used to calculate intensity color values. Default
26028           is 120 dBFS.  Allowed range is from 10 to 200.
26029
26030       limit
26031           Set upper limit of input audio samples volume in dBFS. Default is 0
26032           dBFS.  Allowed range is from -100 to 100.
26033
26034       opacity
26035           Set opacity strength when using pixel format output with alpha
26036           component.
26037
26038       The usage is very similar to the showwaves filter; see the examples in
26039       that section.
26040
26041       Examples
26042
26043       •   Large window with logarithmic color scaling:
26044
26045                   showspectrum=s=1280x480:scale=log
26046
26047       •   Complete example for a colored and sliding spectrum per channel
26048           using ffplay:
26049
26050                   ffplay -f lavfi 'amovie=input.mp3, asplit [a][out1];
26051                                [a] showspectrum=mode=separate:color=intensity:slide=1:scale=cbrt [out0]'
26052
26053   showspectrumpic
26054       Convert input audio to a single video frame, representing the audio
26055       frequency spectrum.
26056
26057       The filter accepts the following options:
26058
26059       size, s
26060           Specify the video size for the output. For the syntax of this
26061           option, check the "Video size" section in the ffmpeg-utils manual.
26062           Default value is "4096x2048".
26063
26064       mode
26065           Specify display mode.
26066
26067           It accepts the following values:
26068
26069           combined
26070               all channels are displayed in the same row
26071
26072           separate
26073               all channels are displayed in separate rows
26074
26075           Default value is combined.
26076
26077       color
26078           Specify display color mode.
26079
26080           It accepts the following values:
26081
26082           channel
26083               each channel is displayed in a separate color
26084
26085           intensity
26086               each channel is displayed using the same color scheme
26087
26088           rainbow
26089               each channel is displayed using the rainbow color scheme
26090
26091           moreland
26092               each channel is displayed using the moreland color scheme
26093
26094           nebulae
26095               each channel is displayed using the nebulae color scheme
26096
26097           fire
26098               each channel is displayed using the fire color scheme
26099
26100           fiery
26101               each channel is displayed using the fiery color scheme
26102
26103           fruit
26104               each channel is displayed using the fruit color scheme
26105
26106           cool
26107               each channel is displayed using the cool color scheme
26108
26109           magma
26110               each channel is displayed using the magma color scheme
26111
26112           green
26113               each channel is displayed using the green color scheme
26114
26115           viridis
26116               each channel is displayed using the viridis color scheme
26117
26118           plasma
26119               each channel is displayed using the plasma color scheme
26120
26121           cividis
26122               each channel is displayed using the cividis color scheme
26123
26124           terrain
26125               each channel is displayed using the terrain color scheme
26126
26127           Default value is intensity.
26128
26129       scale
26130           Specify scale used for calculating intensity color values.
26131
26132           It accepts the following values:
26133
26134           lin linear
26135
26136           sqrt
26137               square root, default
26138
26139           cbrt
26140               cubic root
26141
26142           log logarithmic
26143
26144           4thrt
26145               4th root
26146
26147           5thrt
26148               5th root
26149
26150           Default value is log.
26151
26152       fscale
26153           Specify frequency scale.
26154
26155           It accepts the following values:
26156
26157           lin linear
26158
26159           log logarithmic
26160
26161           Default value is lin.
26162
26163       saturation
26164           Set saturation modifier for displayed colors. Negative values
26165           provide alternative color scheme. 0 is no saturation at all.
26166           Saturation must be in [-10.0, 10.0] range.  Default value is 1.
26167
26168       win_func
26169           Set window function.
26170
26171           It accepts the following values:
26172
26173           rect
26174           bartlett
26175           hann
26176           hanning
26177           hamming
26178           blackman
26179           welch
26180           flattop
26181           bharris
26182           bnuttall
26183           bhann
26184           sine
26185           nuttall
26186           lanczos
26187           gauss
26188           tukey
26189           dolph
26190           cauchy
26191           parzen
26192           poisson
26193           bohman
26194
26195           Default value is "hann".
26196
26197       orientation
26198           Set orientation of time vs frequency axis. Can be "vertical" or
26199           "horizontal". Default is "vertical".
26200
26201       gain
26202           Set scale gain for calculating intensity color values.  Default
26203           value is 1.
26204
26205       legend
26206           Draw time and frequency axes and legends. Default is enabled.
26207
26208       rotation
26209           Set color rotation, must be in [-1.0, 1.0] range.  Default value is
26210           0.
26211
26212       start
26213           Set start frequency from which to display spectrogram. Default is
26214           0.
26215
26216       stop
26217           Set stop frequency to which to display spectrogram. Default is 0.
26218
26219       drange
26220           Set dynamic range used to calculate intensity color values. Default
26221           is 120 dBFS.  Allowed range is from 10 to 200.
26222
26223       limit
26224           Set upper limit of input audio samples volume in dBFS. Default is 0
26225           dBFS.  Allowed range is from -100 to 100.
26226
26227       opacity
26228           Set opacity strength when using pixel format output with alpha
26229           component.
26230
26231       Examples
26232
26233       •   Extract an audio spectrogram of a whole audio track in a 1024x1024
26234           picture using ffmpeg:
26235
26236                   ffmpeg -i audio.flac -lavfi showspectrumpic=s=1024x1024 spectrogram.png
26237
26238   showvolume
26239       Convert input audio volume to a video output.
26240
26241       The filter accepts the following options:
26242
26243       rate, r
26244           Set video rate.
26245
26246       b   Set border width, allowed range is [0, 5]. Default is 1.
26247
26248       w   Set channel width, allowed range is [80, 8192]. Default is 400.
26249
26250       h   Set channel height, allowed range is [1, 900]. Default is 20.
26251
26252       f   Set fade, allowed range is [0, 1]. Default is 0.95.
26253
26254       c   Set volume color expression.
26255
26256           The expression can use the following variables:
26257
26258           VOLUME
26259               Current max volume of channel in dB.
26260
26261           PEAK
26262               Current peak.
26263
26264           CHANNEL
26265               Current channel number, starting from 0.
26266
26267       t   If set, displays channel names. Default is enabled.
26268
26269       v   If set, displays volume values. Default is enabled.
26270
26271       o   Set orientation, can be horizontal: "h" or vertical: "v", default
26272           is "h".
26273
26274       s   Set step size, allowed range is [0, 5]. Default is 0, which means
26275           step is disabled.
26276
26277       p   Set background opacity, allowed range is [0, 1]. Default is 0.
26278
26279       m   Set metering mode, can be peak: "p" or rms: "r", default is "p".
26280
26281       ds  Set display scale, can be linear: "lin" or log: "log", default is
26282           "lin".
26283
26284       dm  In second.  If set to > 0., display a line for the max level in the
26285           previous seconds.  default is disabled: 0.
26286
26287       dmc The color of the max line. Use when "dm" option is set to > 0.
26288           default is: "orange"
26289
26290   showwaves
26291       Convert input audio to a video output, representing the samples waves.
26292
26293       The filter accepts the following options:
26294
26295       size, s
26296           Specify the video size for the output. For the syntax of this
26297           option, check the "Video size" section in the ffmpeg-utils manual.
26298           Default value is "600x240".
26299
26300       mode
26301           Set display mode.
26302
26303           Available values are:
26304
26305           point
26306               Draw a point for each sample.
26307
26308           line
26309               Draw a vertical line for each sample.
26310
26311           p2p Draw a point for each sample and a line between them.
26312
26313           cline
26314               Draw a centered vertical line for each sample.
26315
26316           Default value is "point".
26317
26318       n   Set the number of samples which are printed on the same column. A
26319           larger value will decrease the frame rate. Must be a positive
26320           integer. This option can be set only if the value for rate is not
26321           explicitly specified.
26322
26323       rate, r
26324           Set the (approximate) output frame rate. This is done by setting
26325           the option n. Default value is "25".
26326
26327       split_channels
26328           Set if channels should be drawn separately or overlap. Default
26329           value is 0.
26330
26331       colors
26332           Set colors separated by '|' which are going to be used for drawing
26333           of each channel.
26334
26335       scale
26336           Set amplitude scale.
26337
26338           Available values are:
26339
26340           lin Linear.
26341
26342           log Logarithmic.
26343
26344           sqrt
26345               Square root.
26346
26347           cbrt
26348               Cubic root.
26349
26350           Default is linear.
26351
26352       draw
26353           Set the draw mode. This is mostly useful to set for high n.
26354
26355           Available values are:
26356
26357           scale
26358               Scale pixel values for each drawn sample.
26359
26360           full
26361               Draw every sample directly.
26362
26363           Default value is "scale".
26364
26365       Examples
26366
26367       •   Output the input file audio and the corresponding video
26368           representation at the same time:
26369
26370                   amovie=a.mp3,asplit[out0],showwaves[out1]
26371
26372       •   Create a synthetic signal and show it with showwaves, forcing a
26373           frame rate of 30 frames per second:
26374
26375                   aevalsrc=sin(1*2*PI*t)*sin(880*2*PI*t):cos(2*PI*200*t),asplit[out0],showwaves=r=30[out1]
26376
26377   showwavespic
26378       Convert input audio to a single video frame, representing the samples
26379       waves.
26380
26381       The filter accepts the following options:
26382
26383       size, s
26384           Specify the video size for the output. For the syntax of this
26385           option, check the "Video size" section in the ffmpeg-utils manual.
26386           Default value is "600x240".
26387
26388       split_channels
26389           Set if channels should be drawn separately or overlap. Default
26390           value is 0.
26391
26392       colors
26393           Set colors separated by '|' which are going to be used for drawing
26394           of each channel.
26395
26396       scale
26397           Set amplitude scale.
26398
26399           Available values are:
26400
26401           lin Linear.
26402
26403           log Logarithmic.
26404
26405           sqrt
26406               Square root.
26407
26408           cbrt
26409               Cubic root.
26410
26411           Default is linear.
26412
26413       draw
26414           Set the draw mode.
26415
26416           Available values are:
26417
26418           scale
26419               Scale pixel values for each drawn sample.
26420
26421           full
26422               Draw every sample directly.
26423
26424           Default value is "scale".
26425
26426       filter
26427           Set the filter mode.
26428
26429           Available values are:
26430
26431           average
26432               Use average samples values for each drawn sample.
26433
26434           peak
26435               Use peak samples values for each drawn sample.
26436
26437           Default value is "average".
26438
26439       Examples
26440
26441       •   Extract a channel split representation of the wave form of a whole
26442           audio track in a 1024x800 picture using ffmpeg:
26443
26444                   ffmpeg -i audio.flac -lavfi showwavespic=split_channels=1:s=1024x800 waveform.png
26445
26446   sidedata, asidedata
26447       Delete frame side data, or select frames based on it.
26448
26449       This filter accepts the following options:
26450
26451       mode
26452           Set mode of operation of the filter.
26453
26454           Can be one of the following:
26455
26456           select
26457               Select every frame with side data of "type".
26458
26459           delete
26460               Delete side data of "type". If "type" is not set, delete all
26461               side data in the frame.
26462
26463       type
26464           Set side data type used with all modes. Must be set for "select"
26465           mode. For the list of frame side data types, refer to the
26466           "AVFrameSideDataType" enum in libavutil/frame.h. For example, to
26467           choose "AV_FRAME_DATA_PANSCAN" side data, you must specify
26468           "PANSCAN".
26469
26470   spectrumsynth
26471       Synthesize audio from 2 input video spectrums, first input stream
26472       represents magnitude across time and second represents phase across
26473       time.  The filter will transform from frequency domain as displayed in
26474       videos back to time domain as presented in audio output.
26475
26476       This filter is primarily created for reversing processed showspectrum
26477       filter outputs, but can synthesize sound from other spectrograms too.
26478       But in such case results are going to be poor if the phase data is not
26479       available, because in such cases phase data need to be recreated,
26480       usually it's just recreated from random noise.  For best results use
26481       gray only output ("channel" color mode in showspectrum filter) and
26482       "log" scale for magnitude video and "lin" scale for phase video. To
26483       produce phase, for 2nd video, use "data" option. Inputs videos should
26484       generally use "fullframe" slide mode as that saves resources needed for
26485       decoding video.
26486
26487       The filter accepts the following options:
26488
26489       sample_rate
26490           Specify sample rate of output audio, the sample rate of audio from
26491           which spectrum was generated may differ.
26492
26493       channels
26494           Set number of channels represented in input video spectrums.
26495
26496       scale
26497           Set scale which was used when generating magnitude input spectrum.
26498           Can be "lin" or "log". Default is "log".
26499
26500       slide
26501           Set slide which was used when generating inputs spectrums.  Can be
26502           "replace", "scroll", "fullframe" or "rscroll".  Default is
26503           "fullframe".
26504
26505       win_func
26506           Set window function used for resynthesis.
26507
26508       overlap
26509           Set window overlap. In range "[0, 1]". Default is 1, which means
26510           optimal overlap for selected window function will be picked.
26511
26512       orientation
26513           Set orientation of input videos. Can be "vertical" or "horizontal".
26514           Default is "vertical".
26515
26516       Examples
26517
26518       •   First create magnitude and phase videos from audio, assuming audio
26519           is stereo with 44100 sample rate, then resynthesize videos back to
26520           audio with spectrumsynth:
26521
26522                   ffmpeg -i input.flac -lavfi showspectrum=mode=separate:scale=log:overlap=0.875:color=channel:slide=fullframe:data=magnitude -an -c:v rawvideo magnitude.nut
26523                   ffmpeg -i input.flac -lavfi showspectrum=mode=separate:scale=lin:overlap=0.875:color=channel:slide=fullframe:data=phase -an -c:v rawvideo phase.nut
26524                   ffmpeg -i magnitude.nut -i phase.nut -lavfi spectrumsynth=channels=2:sample_rate=44100:win_func=hann:overlap=0.875:slide=fullframe output.flac
26525
26526   split, asplit
26527       Split input into several identical outputs.
26528
26529       "asplit" works with audio input, "split" with video.
26530
26531       The filter accepts a single parameter which specifies the number of
26532       outputs. If unspecified, it defaults to 2.
26533
26534       Examples
26535
26536       •   Create two separate outputs from the same input:
26537
26538                   [in] split [out0][out1]
26539
26540       •   To create 3 or more outputs, you need to specify the number of
26541           outputs, like in:
26542
26543                   [in] asplit=3 [out0][out1][out2]
26544
26545       •   Create two separate outputs from the same input, one cropped and
26546           one padded:
26547
26548                   [in] split [splitout1][splitout2];
26549                   [splitout1] crop=100:100:0:0    [cropout];
26550                   [splitout2] pad=200:200:100:100 [padout];
26551
26552       •   Create 5 copies of the input audio with ffmpeg:
26553
26554                   ffmpeg -i INPUT -filter_complex asplit=5 OUTPUT
26555
26556   zmq, azmq
26557       Receive commands sent through a libzmq client, and forward them to
26558       filters in the filtergraph.
26559
26560       "zmq" and "azmq" work as a pass-through filters. "zmq" must be inserted
26561       between two video filters, "azmq" between two audio filters. Both are
26562       capable to send messages to any filter type.
26563
26564       To enable these filters you need to install the libzmq library and
26565       headers and configure FFmpeg with "--enable-libzmq".
26566
26567       For more information about libzmq see: <http://www.zeromq.org/>
26568
26569       The "zmq" and "azmq" filters work as a libzmq server, which receives
26570       messages sent through a network interface defined by the bind_address
26571       (or the abbreviation "b") option.  Default value of this option is
26572       tcp://localhost:5555. You may want to alter this value to your needs,
26573       but do not forget to escape any ':' signs (see filtergraph escaping).
26574
26575       The received message must be in the form:
26576
26577               <TARGET> <COMMAND> [<ARG>]
26578
26579       TARGET specifies the target of the command, usually the name of the
26580       filter class or a specific filter instance name. The default filter
26581       instance name uses the pattern Parsed_<filter_name>_<index>, but you
26582       can override this by using the filter_name@id syntax (see Filtergraph
26583       syntax).
26584
26585       COMMAND specifies the name of the command for the target filter.
26586
26587       ARG is optional and specifies the optional argument list for the given
26588       COMMAND.
26589
26590       Upon reception, the message is processed and the corresponding command
26591       is injected into the filtergraph. Depending on the result, the filter
26592       will send a reply to the client, adopting the format:
26593
26594               <ERROR_CODE> <ERROR_REASON>
26595               <MESSAGE>
26596
26597       MESSAGE is optional.
26598
26599       Examples
26600
26601       Look at tools/zmqsend for an example of a zmq client which can be used
26602       to send commands processed by these filters.
26603
26604       Consider the following filtergraph generated by ffplay.  In this
26605       example the last overlay filter has an instance name. All other filters
26606       will have default instance names.
26607
26608               ffplay -dumpgraph 1 -f lavfi "
26609               color=s=100x100:c=red  [l];
26610               color=s=100x100:c=blue [r];
26611               nullsrc=s=200x100, zmq [bg];
26612               [bg][l]   overlay     [bg+l];
26613               [bg+l][r] overlay@my=x=100 "
26614
26615       To change the color of the left side of the video, the following
26616       command can be used:
26617
26618               echo Parsed_color_0 c yellow | tools/zmqsend
26619
26620       To change the right side:
26621
26622               echo Parsed_color_1 c pink | tools/zmqsend
26623
26624       To change the position of the right side:
26625
26626               echo overlay@my x 150 | tools/zmqsend
26627

MULTIMEDIA SOURCES

26629       Below is a description of the currently available multimedia sources.
26630
26631   amovie
26632       This is the same as movie source, except it selects an audio stream by
26633       default.
26634
26635   avsynctest
26636       Generate an Audio/Video Sync Test.
26637
26638       Generated stream periodically shows flash video frame and emits beep in
26639       audio.  Useful to inspect A/V sync issues.
26640
26641       It accepts the following options:
26642
26643       size, s
26644           Set output video size. Default value is "hd720".
26645
26646       framerate, fr
26647           Set output video frame rate. Default value is 30.
26648
26649       samplerate, sr
26650           Set output audio sample rate. Default value is 44100.
26651
26652       amplitude, a
26653           Set output audio beep amplitude. Default value is 0.7.
26654
26655       period, p
26656           Set output audio beep period in seconds. Default value is 3.
26657
26658       delay, dl
26659           Set output video flash delay in number of frames. Default value is
26660           0.
26661
26662       cycle, c
26663           Enable cycling of video delays, by default is disabled.
26664
26665       duration, d
26666           Set stream output duration. By default duration is unlimited.
26667
26668       fg, bg, ag
26669           Set foreground/background/additional color.
26670
26671   movie
26672       Read audio and/or video stream(s) from a movie container.
26673
26674       It accepts the following parameters:
26675
26676       filename
26677           The name of the resource to read (not necessarily a file; it can
26678           also be a device or a stream accessed through some protocol).
26679
26680       format_name, f
26681           Specifies the format assumed for the movie to read, and can be
26682           either the name of a container or an input device. If not
26683           specified, the format is guessed from movie_name or by probing.
26684
26685       seek_point, sp
26686           Specifies the seek point in seconds. The frames will be output
26687           starting from this seek point. The parameter is evaluated with
26688           "av_strtod", so the numerical value may be suffixed by an IS
26689           postfix. The default value is "0".
26690
26691       streams, s
26692           Specifies the streams to read. Several streams can be specified,
26693           separated by "+". The source will then have as many outputs, in the
26694           same order. The syntax is explained in the "Stream specifiers"
26695           section in the ffmpeg manual. Two special names, "dv" and "da"
26696           specify respectively the default (best suited) video and audio
26697           stream. Default is "dv", or "da" if the filter is called as
26698           "amovie".
26699
26700       stream_index, si
26701           Specifies the index of the video stream to read. If the value is
26702           -1, the most suitable video stream will be automatically selected.
26703           The default value is "-1". Deprecated. If the filter is called
26704           "amovie", it will select audio instead of video.
26705
26706       loop
26707           Specifies how many times to read the stream in sequence.  If the
26708           value is 0, the stream will be looped infinitely.  Default value is
26709           "1".
26710
26711           Note that when the movie is looped the source timestamps are not
26712           changed, so it will generate non monotonically increasing
26713           timestamps.
26714
26715       discontinuity
26716           Specifies the time difference between frames above which the point
26717           is considered a timestamp discontinuity which is removed by
26718           adjusting the later timestamps.
26719
26720       dec_threads
26721           Specifies the number of threads for decoding
26722
26723       format_opts
26724           Specify format options for the opened file. Format options can be
26725           specified as a list of key=value pairs separated by ':'. The
26726           following example shows how to add protocol_whitelist and
26727           protocol_blacklist options:
26728
26729                   ffplay -f lavfi
26730                   "movie=filename='1.sdp':format_opts='protocol_whitelist=file,rtp,udp\:protocol_blacklist=http'"
26731
26732       It allows overlaying a second video on top of the main input of a
26733       filtergraph, as shown in this graph:
26734
26735               input -----------> deltapts0 --> overlay --> output
26736                                                   ^
26737                                                   |
26738               movie --> scale--> deltapts1 -------+
26739
26740       Examples
26741
26742       •   Skip 3.2 seconds from the start of the AVI file in.avi, and overlay
26743           it on top of the input labelled "in":
26744
26745                   movie=in.avi:seek_point=3.2, scale=180:-1, setpts=PTS-STARTPTS [over];
26746                   [in] setpts=PTS-STARTPTS [main];
26747                   [main][over] overlay=16:16 [out]
26748
26749       •   Read from a video4linux2 device, and overlay it on top of the input
26750           labelled "in":
26751
26752                   movie=/dev/video0:f=video4linux2, scale=180:-1, setpts=PTS-STARTPTS [over];
26753                   [in] setpts=PTS-STARTPTS [main];
26754                   [main][over] overlay=16:16 [out]
26755
26756       •   Read the first video stream and the audio stream with id 0x81 from
26757           dvd.vob; the video is connected to the pad named "video" and the
26758           audio is connected to the pad named "audio":
26759
26760                   movie=dvd.vob:s=v:0+#0x81 [video] [audio]
26761
26762       Commands
26763
26764       Both movie and amovie support the following commands:
26765
26766       seek
26767           Perform seek using "av_seek_frame".  The syntax is: seek
26768           stream_index|timestamp|flags
26769
26770stream_index: If stream_index is -1, a default stream is
26771               selected, and timestamp is automatically converted from
26772               AV_TIME_BASE units to the stream specific time_base.
26773
26774timestamp: Timestamp in AVStream.time_base units or, if no
26775               stream is specified, in AV_TIME_BASE units.
26776
26777flags: Flags which select direction and seeking mode.
26778
26779       get_duration
26780           Get movie duration in AV_TIME_BASE units.
26781

SEE ALSO

26783       ffmpeg(1), ffplay(1), ffprobe(1), libavfilter(3)
26784

AUTHORS

26786       The FFmpeg developers.
26787
26788       For details about the authorship, see the Git history of the project
26789       (git://source.ffmpeg.org/ffmpeg), e.g. by typing the command git log in
26790       the FFmpeg source directory, or browsing the online repository at
26791       <http://source.ffmpeg.org>.
26792
26793       Maintainers for the specific components are listed in the file
26794       MAINTAINERS in the source code tree.
26795
26796
26797
26798                                                             FFMPEG-FILTERS(1)
Impressum