Changes between Version 47 and Version 48 of FilteringGuide


Ignore:
Timestamp:
Feb 24, 2018, 6:00:58 AM (7 months ago)
Author:
jdlh
Comment:

Add description of filter syntax, especially filter options.

Legend:

Unmodified
Added
Removed
Modified
  • FilteringGuide

    v47 v48  
    77 
    88Refer to the [http://ffmpeg.org/ffmpeg-filters.html FFmpeg filters documentation] for more information and examples for each filter. This wiki page is for user contributed examples and tips, and contributions to this page are encouraged. 
     9 
     10== Filter syntax == 
     11 
     12When documentation refers to "filter options", or says the "filter accepts the following options", the syntax to use for the options is as described in '''FFmpeg Filters''', section ''4.1 [http://ffmpeg.org/ffmpeg-filters.html#Filtergraph-syntax-1 Filtergraph] syntax''. Briefly, that syntax is to add, after the name of the filter, an `=` character, then the name of the first filter option, an `=` character, and the value of that option. If you want to specify further filter options, you delimit them with `:`, then append the name of the next filter option, an `=` character, and the next value.  
     13 
     14For instance, to apply the [http://ffmpeg.org/ffmpeg-filters.html#loudnorm loudnorm filter] to an audio stream, the basic syntax is: 
     15{{{ 
     16ffmpeg -i input -filter:a loudnorm  output 
     17}}} 
     18To add the `print_format` and `linear` filter options, use the syntax: 
     19 
     20{{{ 
     21ffmpeg -i input -filter:a loudnorm=print_format=summary:linear=true  output 
     22}}} 
     23 
     24As described in section ''4.1 [http://ffmpeg.org/ffmpeg-filters.html#Filtergraph-syntax-1 Filtergraph] syntax'', you can omit the option names and `=` characters, supplying just the values, delimited by `:` characters. For example, in this invocation: 
     25{{{ 
     26ffmpeg -i input -vf scale=iw/2:-1 output 
     27}}} 
     28FFmpeg assumes the option names in the order they are declared in the source code.  For instance, in this use of the [http://ffmpeg.org/ffmpeg-filters.html#scale scale filter], FFmpeg assumes the option name `width` for the value `iw/2`, and the name `height` for the value `-1`.  
    929 
    1030== Examples ==