Codec AVOptions
===============

-b[:stream_specifier] INTEGER (output,audio,video)
     set bitrate (in bits/s)

-ab[:stream_specifier] INTEGER (output,audio)
     set bitrate (in bits/s)

-bt[:stream_specifier] INTEGER (output,audio,video)
     Set video bitrate tolerance (in bits/s). In 1-pass mode, bitrate tolerance specifies how far ratecontrol is willing to deviate from the target average bitrate value. This is not related to minimum/maximum bitrate. Lowering tolerance too much has an adverse effect on quality.

-flags[:stream_specifier] FLAGS (input/output,audio,video,subtitles)

     Possible values:

     unaligned
          allow decoders to produce unaligned output

     mv4
          use four motion vectors per macroblock (MPEG-4)

     qpel
          use 1/4-pel motion compensation

     loop
          use loop filter

     qscale
          use fixed qscale

     recon_frame
          export reconstructed frames

     copy_opaque
          propagate opaque values

     frame_duration
          use frame durations

     pass1
          use internal 2-pass ratecontrol in first  pass mode

     pass2
          use internal 2-pass ratecontrol in second pass mode

     gray
          only decode/encode grayscale

     psnr
          error[?] variables will be set during encoding

     ildct
          use interlaced DCT

     low_delay
          force low delay

     global_header
          place global headers in extradata instead of every keyframe

     bitexact
          use only bitexact functions (except (I)DCT)

     aic
          H.263 advanced intra coding / MPEG-4 AC prediction

     ilme
          interlaced motion estimation

     cgop
          closed GOP

     output_corrupt
          Output even potentially corrupted frames

     drop_changed
          Drop frames whose parameters differ from first decoded frame

-flags2[:stream_specifier] FLAGS (input/output,audio,video,subtitles)

     Possible values:

     fast
          allow non-spec-compliant speedup tricks

     noout
          skip bitstream encoding

     ignorecrop
          ignore cropping information from sps

     local_header
          place global headers at every keyframe instead of in extradata

     chunks
          Frame data might be split into multiple chunks

     showall
          Show all frames before the first keyframe

     export_mvs
          export motion vectors through frame side data

     skip_manual
          do not skip samples and export skip information as frame side data

     ass_ro_flush_noop
          do not reset ASS ReadOrder field on flush

     icc_profiles
          generate/parse embedded ICC profiles from/to colorimetry tags

-export_side_data[:stream_specifier] FLAGS (input/output,audio,video,subtitles)
     Export metadata as side data

     Possible values:

     mvs
          export motion vectors through frame side data

     prft
          export Producer Reference Time through packet side data

     venc_params
          export video encoding parameters through frame side data

     film_grain
          export film grain parameters through frame side data

     enhancements
          export picture enhancement metadata through frame side data

-g[:stream_specifier] INTEGER (output,video)
     set the group of picture (GOP) size

-ar[:stream_specifier] INTEGER (input/output,audio)
     set audio sampling rate (in Hz)

-cutoff[:stream_specifier] INTEGER (output,audio)
     set cutoff bandwidth

-frame_size[:stream_specifier] INTEGER (output,audio)

-qcomp[:stream_specifier] FLOAT (output,video)
     video quantizer scale compression (VBR). Constant of ratecontrol equation. Recommended range for default rc_eq: 0.0-1.0

-qblur[:stream_specifier] FLOAT (output,video)
     video quantizer scale blur (VBR)

-qmin[:stream_specifier] INTEGER (output,video)
     minimum video quantizer scale (VBR)

-qmax[:stream_specifier] INTEGER (output,video)
     maximum video quantizer scale (VBR)

-qdiff[:stream_specifier] INTEGER (output,video)
     maximum difference between the quantizer scales (VBR)

-bf[:stream_specifier] INTEGER (output,video)
     set maximum number of B-frames between non-B-frames

-b_qfactor[:stream_specifier] FLOAT (output,video)
     QP factor between P- and B-frames

-bug[:stream_specifier] FLAGS (input,video)
     work around not autodetected encoder bugs

     Possible values:

     autodetect

     xvid_ilace
          Xvid interlacing bug (autodetected if FOURCC == XVIX)

     ump4
          (autodetected if FOURCC == UMP4)

     no_padding
          padding bug (autodetected)

     amv

     qpel_chroma

     std_qpel
          old standard qpel (autodetected per FOURCC/version)

     qpel_chroma2

     direct_blocksize
          direct-qpel-blocksize bug (autodetected per FOURCC/version)

     edge
          edge padding bug (autodetected per FOURCC/version)

     hpel_chroma

     dc_clip

     ms
          work around various bugs in Microsoft's broken decoders

     trunc
          truncated frames

     iedge

-strict[:stream_specifier] INTEGER (input/output,audio,video)
     how strictly to follow the standards

     Possible values:

     very
          strictly conform to a older more strict version of the spec or reference software

     strict
          strictly conform to all the things in the spec no matter what the consequences

     normal

     unofficial
          allow unofficial extensions

     experimental
          allow non-standardized experimental things

-b_qoffset[:stream_specifier] FLOAT (output,video)
     QP offset between P- and B-frames

-err_detect[:stream_specifier] FLAGS (input/output,audio,video,subtitles)
     set error detection flags

     Possible values:

     crccheck
          verify embedded CRCs

     bitstream
          detect bitstream specification deviations

     buffer
          detect improper bitstream length

     explode
          abort decoding on minor error detection

     ignore_err
          ignore errors

     careful
          consider things that violate the spec, are fast to check and have not been seen in the wild as errors

     compliant
          consider all spec non compliancies as errors

     aggressive
          consider things that a sane encoder should not do as an error

-maxrate[:stream_specifier] INTEGER (output,audio,video)
     maximum bitrate (in bits/s). Used for VBV together with bufsize.

-minrate[:stream_specifier] INTEGER (output,audio,video)
     minimum bitrate (in bits/s). Most useful in setting up a CBR encode. It is of little use otherwise.

-bufsize[:stream_specifier] INTEGER (output,audio,video)
     set ratecontrol buffer size (in bits)

-i_qfactor[:stream_specifier] FLOAT (output,video)
     QP factor between P- and I-frames

-i_qoffset[:stream_specifier] FLOAT (output,video)
     QP offset between P- and I-frames

-dct[:stream_specifier] INTEGER (output,video)
     DCT algorithm

     Possible values:

     auto
          autoselect a good one

     fastint
          fast integer

     int
          accurate integer

     mmx

     altivec

     faan
          floating point AAN DCT

     neon

-lumi_mask[:stream_specifier] FLOAT (output,video)
     compresses bright areas stronger than medium ones

-tcplx_mask[:stream_specifier] FLOAT (output,video)
     temporal complexity masking

-scplx_mask[:stream_specifier] FLOAT (output,video)
     spatial complexity masking

-p_mask[:stream_specifier] FLOAT (output,video)
     inter masking

-dark_mask[:stream_specifier] FLOAT (output,video)
     compresses dark areas stronger than medium ones

-idct[:stream_specifier] INTEGER (input/output,video)
     select IDCT implementation

     Possible values:

     auto

     int

     simple

     simplemmx

     arm

     altivec

     simplearm

     simplearmv5te

     simplearmv6

     simpleneon

     xvid

     xvidmmx
          deprecated, for compatibility only

     faani
          floating point AAN IDCT

     simpleauto

-ec[:stream_specifier] FLAGS (input,video)
     set error concealment strategy

     Possible values:

     guess_mvs
          iterative motion vector (MV) search (slow)

     deblock
          use strong deblock filter for damaged MBs

     favor_inter
          favor predicting from the previous frame

-aspect[:stream_specifier] RATIONAL NUMBER (output,video)
     sample aspect ratio

-sar[:stream_specifier] RATIONAL NUMBER (output,video)
     sample aspect ratio

-debug[:stream_specifier] FLAGS (input/output,audio,video,subtitles)
     print specific debug info

     Possible values:

     pict
          picture info

     rc
          rate control

     bitstream

     mb_type
          macroblock (MB) type

     qp
          per-block quantization parameter (QP)

     dct_coeff

     green_metadata

     skip

     startcode

     er
          error recognition

     mmco
          memory management control operations (H.264)

     bugs

     buffers
          picture buffer allocations

     thread_ops
          threading operations

     nomc
          skip motion compensation

-dia_size[:stream_specifier] INTEGER (output,video)
     diamond type & size for motion estimation

-last_pred[:stream_specifier] INTEGER (output,video)
     amount of motion predictors from the previous frame

-pre_dia_size[:stream_specifier] INTEGER (output,video)
     diamond type & size for motion estimation pre-pass

-subq[:stream_specifier] INTEGER (output,video)
     sub-pel motion estimation quality

-me_range[:stream_specifier] INTEGER (output,video)
     limit motion vectors range (1023 for DivX player)

-global_quality[:stream_specifier] INTEGER (output,audio,video)

-mbd[:stream_specifier] INTEGER (output,video)
     macroblock decision algorithm (high quality mode)

     Possible values:

     simple
          use mbcmp

     bits
          use fewest bits

     rd
          use best rate distortion

-rc_init_occupancy[:stream_specifier] INTEGER (output,video)
     number of bits which should be loaded into the rc buffer before decoding starts

-threads[:stream_specifier] INTEGER (input/output,audio,video)
     set the number of threads

     Possible values:

     auto
          autodetect a suitable number of threads to use

-dc[:stream_specifier] INTEGER (output,video)
     intra_dc_precision

-nssew[:stream_specifier] INTEGER (output,video)
     nsse weight

-skip_top[:stream_specifier] INTEGER (input,video)
     number of macroblock rows at the top which are skipped

-skip_bottom[:stream_specifier] INTEGER (input,video)
     number of macroblock rows at the bottom which are skipped

-profile[:stream_specifier] INTEGER (output,audio,video)

     Possible values:

     unknown

     main10

-level[:stream_specifier] INTEGER (output,audio,video)
     encoding level, usually corresponding to the profile level, codec-specific

     Possible values:

     unknown

-lowres[:stream_specifier] INTEGER (input,audio,video)
     decode at 1= 1/2, 2=1/4, 3=1/8 resolutions

-cmp[:stream_specifier] INTEGER (output,video)
     full-pel ME compare function

     Possible values:

     sad
          sum of absolute differences, fast

     sse
          sum of squared errors

     satd
          sum of absolute Hadamard transformed differences

     dct
          sum of absolute DCT transformed differences

     psnr
          sum of squared quantization errors (avoid, low quality)

     bit
          number of bits needed for the block

     rd
          rate distortion optimal, slow

     zero
          0

     vsad
          sum of absolute vertical differences

     vsse
          sum of squared vertical differences

     nsse
          noise preserving sum of squared differences

     w53
          5/3 wavelet, only used in snow

     w97
          9/7 wavelet, only used in snow

     dctmax

     chroma

     msad
          sum of absolute differences, median predicted

-subcmp[:stream_specifier] INTEGER (output,video)
     sub-pel ME compare function

     Possible values:

     sad
          sum of absolute differences, fast

     sse
          sum of squared errors

     satd
          sum of absolute Hadamard transformed differences

     dct
          sum of absolute DCT transformed differences

     psnr
          sum of squared quantization errors (avoid, low quality)

     bit
          number of bits needed for the block

     rd
          rate distortion optimal, slow

     zero
          0

     vsad
          sum of absolute vertical differences

     vsse
          sum of squared vertical differences

     nsse
          noise preserving sum of squared differences

     w53
          5/3 wavelet, only used in snow

     w97
          9/7 wavelet, only used in snow

     dctmax

     chroma

     msad
          sum of absolute differences, median predicted

-mbcmp[:stream_specifier] INTEGER (output,video)
     macroblock compare function

     Possible values:

     sad
          sum of absolute differences, fast

     sse
          sum of squared errors

     satd
          sum of absolute Hadamard transformed differences

     dct
          sum of absolute DCT transformed differences

     psnr
          sum of squared quantization errors (avoid, low quality)

     bit
          number of bits needed for the block

     rd
          rate distortion optimal, slow

     zero
          0

     vsad
          sum of absolute vertical differences

     vsse
          sum of squared vertical differences

     nsse
          noise preserving sum of squared differences

     w53
          5/3 wavelet, only used in snow

     w97
          9/7 wavelet, only used in snow

     dctmax

     chroma

     msad
          sum of absolute differences, median predicted

-ildctcmp[:stream_specifier] INTEGER (output,video)
     interlaced DCT compare function

     Possible values:

     sad
          sum of absolute differences, fast

     sse
          sum of squared errors

     satd
          sum of absolute Hadamard transformed differences

     dct
          sum of absolute DCT transformed differences

     psnr
          sum of squared quantization errors (avoid, low quality)

     bit
          number of bits needed for the block

     rd
          rate distortion optimal, slow

     zero
          0

     vsad
          sum of absolute vertical differences

     vsse
          sum of squared vertical differences

     nsse
          noise preserving sum of squared differences

     w53
          5/3 wavelet, only used in snow

     w97
          9/7 wavelet, only used in snow

     dctmax

     chroma

     msad
          sum of absolute differences, median predicted

-precmp[:stream_specifier] INTEGER (output,video)
     pre motion estimation compare function

     Possible values:

     sad
          sum of absolute differences, fast

     sse
          sum of squared errors

     satd
          sum of absolute Hadamard transformed differences

     dct
          sum of absolute DCT transformed differences

     psnr
          sum of squared quantization errors (avoid, low quality)

     bit
          number of bits needed for the block

     rd
          rate distortion optimal, slow

     zero
          0

     vsad
          sum of absolute vertical differences

     vsse
          sum of squared vertical differences

     nsse
          noise preserving sum of squared differences

     w53
          5/3 wavelet, only used in snow

     w97
          9/7 wavelet, only used in snow

     dctmax

     chroma

     msad
          sum of absolute differences, median predicted

-mblmin[:stream_specifier] INTEGER (output,video)
     minimum macroblock Lagrange factor (VBR)

-mblmax[:stream_specifier] INTEGER (output,video)
     maximum macroblock Lagrange factor (VBR)

-skip_loop_filter[:stream_specifier] INTEGER (input,video)
     skip loop filtering process for the selected frames

     Possible values:

     none
          discard no frame

     default
          discard useless frames

     noref
          discard all non-reference frames

     bidir
          discard all bidirectional frames

     nointra
          discard all frames except I frames

     nokey
          discard all frames except keyframes

     all
          discard all frames

-skip_idct[:stream_specifier] INTEGER (input,video)
     skip IDCT/dequantization for the selected frames

     Possible values:

     none
          discard no frame

     default
          discard useless frames

     noref
          discard all non-reference frames

     bidir
          discard all bidirectional frames

     nointra
          discard all frames except I frames

     nokey
          discard all frames except keyframes

     all
          discard all frames

-skip_frame[:stream_specifier] INTEGER (input,video)
     skip decoding for the selected frames

     Possible values:

     none
          discard no frame

     default
          discard useless frames

     noref
          discard all non-reference frames

     bidir
          discard all bidirectional frames

     nointra
          discard all frames except I frames

     nokey
          discard all frames except keyframes

     all
          discard all frames

-bidir_refine[:stream_specifier] INTEGER (output,video)
     refine the two motion vectors used in bidirectional macroblocks

-keyint_min[:stream_specifier] INTEGER (output,video)
     minimum interval between IDR-frames

-refs[:stream_specifier] INTEGER (output,video)
     reference frames to consider for motion compensation

-trellis[:stream_specifier] INTEGER (output,audio,video)
     rate-distortion optimal quantization

-mv0_threshold[:stream_specifier] INTEGER (output,video)

-compression_level[:stream_specifier] INTEGER (output,audio,video)

-ch_layout[:stream_specifier] VALUE (input/output,audio)

     Possible values:

-rc_max_vbv_use[:stream_specifier] FLOAT (output,video)

-rc_min_vbv_use[:stream_specifier] FLOAT (output,video)

-ticks_per_frame[:stream_specifier] INTEGER (input/output,audio,video)

-color_primaries[:stream_specifier] INTEGER (input/output,video)
     color primaries

     Possible values:

     bt709
          BT.709

     unknown
          Unspecified

     bt470m
          BT.470 M

     bt470bg
          BT.470 BG

     smpte170m
          SMPTE 170 M

     smpte240m
          SMPTE 240 M

     film
          Film

     bt2020
          BT.2020

     smpte428
          SMPTE 428-1

     smpte428_1
          SMPTE 428-1

     smpte431
          SMPTE 431-2

     smpte432
          SMPTE 422-1

     jedec-p22
          JEDEC P22

     ebu3213
          EBU 3213-E

     unspecified
          Unspecified

-color_trc[:stream_specifier] INTEGER (input/output,video)
     color transfer characteristics

     Possible values:

     bt709
          BT.709

     unknown
          Unspecified

     gamma22
          BT.470 M

     gamma28
          BT.470 BG

     smpte170m
          SMPTE 170 M

     smpte240m
          SMPTE 240 M

     linear
          Linear

     log100
          Log

     log316
          Log square root

     iec61966-2-4
          IEC 61966-2-4

     bt1361e
          BT.1361

     iec61966-2-1
          IEC 61966-2-1

     bt2020-10
          BT.2020 - 10 bit

     bt2020-12
          BT.2020 - 12 bit

     smpte2084
          SMPTE 2084

     smpte428
          SMPTE 428-1

     arib-std-b67
          ARIB STD-B67

     unspecified
          Unspecified

     log
          Log

     log_sqrt
          Log square root

     iec61966_2_4
          IEC 61966-2-4

     bt1361
          BT.1361

     iec61966_2_1
          IEC 61966-2-1

     bt2020_10bit
          BT.2020 - 10 bit

     bt2020_12bit
          BT.2020 - 12 bit

     smpte428_1
          SMPTE 428-1

-colorspace[:stream_specifier] INTEGER (input/output,video)
     color space

     Possible values:

     rgb
          RGB

     bt709
          BT.709

     unknown
          Unspecified

     fcc
          FCC

     bt470bg
          BT.470 BG

     smpte170m
          SMPTE 170 M

     smpte240m
          SMPTE 240 M

     ycgco
          YCGCO

     bt2020nc
          BT.2020 NCL

     bt2020c
          BT.2020 CL

     smpte2085
          SMPTE 2085

     chroma-derived-nc
          Chroma-derived NCL

     chroma-derived-c
          Chroma-derived CL

     ictcp
          ICtCp

     ipt-c2
          IPT-C2

     unspecified
          Unspecified

     ycocg
          YCGCO

     ycgco-re
          YCgCo-R, even add.

     ycgco-ro
          YCgCo-R, odd add.

     bt2020_ncl
          BT.2020 NCL

     bt2020_cl
          BT.2020 CL

-color_range[:stream_specifier] INTEGER (input/output,video)
     color range

     Possible values:

     unknown
          Unspecified

     tv
          MPEG (219*2^(n-8))

     pc
          JPEG (2^n-1)

     unspecified
          Unspecified

     mpeg
          MPEG (219*2^(n-8))

     jpeg
          JPEG (2^n-1)

     limited
          MPEG (219*2^(n-8))

     full
          JPEG (2^n-1)

-chroma_sample_location[:stream_specifier] INTEGER (input/output,video)
     chroma sample location

     Possible values:

     unknown
          Unspecified

     left
          Left

     center
          Center

     topleft
          Top-left

     top
          Top

     bottomleft
          Bottom-left

     bottom
          Bottom

     unspecified
          Unspecified

-slices[:stream_specifier] INTEGER (output,video)
     set the number of slices, used in parallelized encoding

-thread_type[:stream_specifier] FLAGS (input/output,audio,video)
     select multithreading type

     Possible values:

     slice

     frame

-audio_service_type[:stream_specifier] INTEGER (output,audio)
     audio service type

     Possible values:

     ma
          Main Audio Service

     ef
          Effects

     vi
          Visually Impaired

     hi
          Hearing Impaired

     di
          Dialogue

     co
          Commentary

     em
          Emergency

     vo
          Voice Over

     ka
          Karaoke

-request_sample_fmt[:stream_specifier] VALUE (input,audio)
     sample format audio decoders should prefer

     Possible values:

-sub_charenc[:stream_specifier] STRING (input,subtitles)
     set input text subtitles character encoding

-sub_charenc_mode[:stream_specifier] FLAGS (input,subtitles)
     set input text subtitles character encoding mode

     Possible values:

     do_nothing

     auto

     pre_decoder

     ignore

-apply_cropping[:stream_specifier] VALUE (input,video)

-skip_alpha[:stream_specifier] VALUE (input,video)
     Skip processing alpha

-field_order[:stream_specifier] INTEGER (input/output,video)
     Field order

     Possible values:

     progressive

     tt

     bb

     tb

     bt

-dump_separator[:stream_specifier] STRING (input/output,audio,video,subtitles)
     set information dump field separator

-codec_whitelist[:stream_specifier] STRING (input,audio,video,subtitles)
     List of decoders that are allowed to be used

-max_pixels[:stream_specifier] INTEGER (input/output,audio,video,subtitles)
     Maximum number of pixels

-max_samples[:stream_specifier] INTEGER (input/output,audio)
     Maximum number of samples

-hwaccel_flags[:stream_specifier] FLAGS (input,video)

     Possible values:

     ignore_level
          ignore level even if the codec level used is unknown or higher than the maximum supported level reported by the hardware driver

     allow_high_depth
          allow to output YUV pixel formats with a different chroma sampling than 4:2:0 and/or other than 8 bits per component

     allow_profile_mismatch
          attempt to decode anyway if HW accelerated decoder's supported profiles do not exactly match the stream

     unsafe_output
          allow potentially unsafe hwaccel frame output that might require special care to process successfully

-extra_hw_frames[:stream_specifier] INTEGER (input,video)
     Number of extra hardware frames to allocate for the user

-discard_damaged_percentage[:stream_specifier] INTEGER (input,video)
     Percentage of damaged samples to discard a frame

-side_data_prefer_packet[:stream_specifier] VALUE (input,audio,video,subtitles)
     Comma-separated list of side data types for which user-supplied (container) data is preferred over coded bytestream

     Possible values:

     replaygain

     displaymatrix

     spherical

     stereo3d

     audio_service_type

     mastering_display_metadata

     content_light_level

     icc_profile