codecs.texi 27 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126
  1. @anchor{codec-options}
  2. @chapter Codec Options
  3. @c man begin CODEC OPTIONS
  4. libavcodec provides some generic global options, which can be set on
  5. all the encoders and decoders. In addition each codec may support
  6. so-called private options, which are specific for a given codec.
  7. Sometimes, a global option may only affect a specific kind of codec,
  8. and may be unsensical or ignored by another, so you need to be aware
  9. of the meaning of the specified options. Also some options are
  10. meant only for decoding or encoding.
  11. Options may be set by specifying -@var{option} @var{value} in the
  12. FFmpeg tools, or by setting the value explicitly in the
  13. @code{AVCodecContext} options or using the @file{libavutil/opt.h} API
  14. for programmatic use.
  15. The list of supported options follow:
  16. @table @option
  17. @item b @var{integer} (@emph{encoding,audio,video})
  18. Set bitrate in bits/s. Default value is 200K.
  19. @item ab @var{integer} (@emph{encoding,audio})
  20. Set audio bitrate (in bits/s). Default value is 128K.
  21. @item bt @var{integer} (@emph{encoding,video})
  22. Set video bitrate tolerance (in bits/s). In 1-pass mode, bitrate
  23. tolerance specifies how far ratecontrol is willing to deviate from the
  24. target average bitrate value. This is not related to min/max
  25. bitrate. Lowering tolerance too much has an adverse effect on quality.
  26. @item flags @var{flags} (@emph{decoding/encoding,audio,video,subtitles})
  27. Set generic flags.
  28. Possible values:
  29. @table @samp
  30. @item mv4
  31. Use four motion vector by macroblock (mpeg4).
  32. @item qpel
  33. Use 1/4 pel motion compensation.
  34. @item loop
  35. Use loop filter.
  36. @item qscale
  37. Use fixed qscale.
  38. @item gmc
  39. Use gmc.
  40. @item mv0
  41. Always try a mb with mv=<0,0>.
  42. @item input_preserved
  43. @item pass1
  44. Use internal 2pass ratecontrol in first pass mode.
  45. @item pass2
  46. Use internal 2pass ratecontrol in second pass mode.
  47. @item gray
  48. Only decode/encode grayscale.
  49. @item emu_edge
  50. Do not draw edges.
  51. @item psnr
  52. Set error[?] variables during encoding.
  53. @item truncated
  54. @item naq
  55. Normalize adaptive quantization.
  56. @item ildct
  57. Use interlaced DCT.
  58. @item low_delay
  59. Force low delay.
  60. @item global_header
  61. Place global headers in extradata instead of every keyframe.
  62. @item bitexact
  63. Use only bitexact stuff (except (I)DCT).
  64. @item aic
  65. Apply H263 advanced intra coding / mpeg4 ac prediction.
  66. @item cbp
  67. Deprecated, use mpegvideo private options instead.
  68. @item qprd
  69. Deprecated, use mpegvideo private options instead.
  70. @item ilme
  71. Apply interlaced motion estimation.
  72. @item cgop
  73. Use closed gop.
  74. @end table
  75. @item me_method @var{integer} (@emph{encoding,video})
  76. Set motion estimation method.
  77. Possible values:
  78. @table @samp
  79. @item zero
  80. zero motion estimation (fastest)
  81. @item full
  82. full motion estimation (slowest)
  83. @item epzs
  84. EPZS motion estimation (default)
  85. @item esa
  86. esa motion estimation (alias for full)
  87. @item tesa
  88. tesa motion estimation
  89. @item dia
  90. dia motion estimation (alias for epzs)
  91. @item log
  92. log motion estimation
  93. @item phods
  94. phods motion estimation
  95. @item x1
  96. X1 motion estimation
  97. @item hex
  98. hex motion estimation
  99. @item umh
  100. umh motion estimation
  101. @item iter
  102. iter motion estimation
  103. @end table
  104. @item extradata_size @var{integer}
  105. Set extradata size.
  106. @item time_base @var{rational number}
  107. Set codec time base.
  108. It is the fundamental unit of time (in seconds) in terms of which
  109. frame timestamps are represented. For fixed-fps content, timebase
  110. should be @code{1 / frame_rate} and timestamp increments should be
  111. identically 1.
  112. @item g @var{integer} (@emph{encoding,video})
  113. Set the group of picture size. Default value is 12.
  114. @item ar @var{integer} (@emph{decoding/encoding,audio})
  115. Set audio sampling rate (in Hz).
  116. @item ac @var{integer} (@emph{decoding/encoding,audio})
  117. Set number of audio channels.
  118. @item cutoff @var{integer} (@emph{encoding,audio})
  119. Set cutoff bandwidth.
  120. @item frame_size @var{integer} (@emph{encoding,audio})
  121. Set audio frame size.
  122. Each submitted frame except the last must contain exactly frame_size
  123. samples per channel. May be 0 when the codec has
  124. CODEC_CAP_VARIABLE_FRAME_SIZE set, in that case the frame size is not
  125. restricted. It is set by some decoders to indicate constant frame
  126. size.
  127. @item frame_number @var{integer}
  128. Set the frame number.
  129. @item delay @var{integer}
  130. @item qcomp @var{float} (@emph{encoding,video})
  131. Set video quantizer scale compression (VBR). It is used as a constant
  132. in the ratecontrol equation. Recommended range for default rc_eq:
  133. 0.0-1.0.
  134. @item qblur @var{float} (@emph{encoding,video})
  135. Set video quantizer scale blur (VBR).
  136. @item qmin @var{integer} (@emph{encoding,video})
  137. Set min video quantizer scale (VBR). Must be included between -1 and
  138. 69, default value is 2.
  139. @item qmax @var{integer} (@emph{encoding,video})
  140. Set max video quantizer scale (VBR). Must be included between -1 and
  141. 1024, default value is 31.
  142. @item qdiff @var{integer} (@emph{encoding,video})
  143. Set max difference between the quantizer scale (VBR).
  144. @item bf @var{integer} (@emph{encoding,video})
  145. Set max number of B frames between non-B-frames.
  146. Must be an integer between -1 and 16. 0 means that B-frames are
  147. disabled. If a value of -1 is used, it will choose an automatic value
  148. depending on the encoder.
  149. Default value is 0.
  150. @item b_qfactor @var{float} (@emph{encoding,video})
  151. Set qp factor between P and B frames.
  152. @item rc_strategy @var{integer} (@emph{encoding,video})
  153. Set ratecontrol method.
  154. @item b_strategy @var{integer} (@emph{encoding,video})
  155. Set strategy to choose between I/P/B-frames.
  156. @item ps @var{integer} (@emph{encoding,video})
  157. Set RTP payload size in bytes.
  158. @item mv_bits @var{integer}
  159. @item header_bits @var{integer}
  160. @item i_tex_bits @var{integer}
  161. @item p_tex_bits @var{integer}
  162. @item i_count @var{integer}
  163. @item p_count @var{integer}
  164. @item skip_count @var{integer}
  165. @item misc_bits @var{integer}
  166. @item frame_bits @var{integer}
  167. @item codec_tag @var{integer}
  168. @item bug @var{flags} (@emph{decoding,video})
  169. Workaround not auto detected encoder bugs.
  170. Possible values:
  171. @table @samp
  172. @item autodetect
  173. @item old_msmpeg4
  174. some old lavc generated msmpeg4v3 files (no autodetection)
  175. @item xvid_ilace
  176. Xvid interlacing bug (autodetected if fourcc==XVIX)
  177. @item ump4
  178. (autodetected if fourcc==UMP4)
  179. @item no_padding
  180. padding bug (autodetected)
  181. @item amv
  182. @item ac_vlc
  183. illegal vlc bug (autodetected per fourcc)
  184. @item qpel_chroma
  185. @item std_qpel
  186. old standard qpel (autodetected per fourcc/version)
  187. @item qpel_chroma2
  188. @item direct_blocksize
  189. direct-qpel-blocksize bug (autodetected per fourcc/version)
  190. @item edge
  191. edge padding bug (autodetected per fourcc/version)
  192. @item hpel_chroma
  193. @item dc_clip
  194. @item ms
  195. Workaround various bugs in microsoft broken decoders.
  196. @item trunc
  197. trancated frames
  198. @end table
  199. @item lelim @var{integer} (@emph{encoding,video})
  200. Set single coefficient elimination threshold for luminance (negative
  201. values also consider DC coefficient).
  202. @item celim @var{integer} (@emph{encoding,video})
  203. Set single coefficient elimination threshold for chrominance (negative
  204. values also consider dc coefficient)
  205. @item strict @var{integer} (@emph{decoding/encoding,audio,video})
  206. Specify how strictly to follow the standards.
  207. Possible values:
  208. @table @samp
  209. @item very
  210. strictly conform to a older more strict version of the spec or reference software
  211. @item strict
  212. strictly conform to all the things in the spec no matter what consequences
  213. @item normal
  214. @item unofficial
  215. allow unofficial extensions
  216. @item experimental
  217. allow non standardized experimental things, experimental
  218. (unfinished/work in progress/not well tested) decoders and encoders.
  219. Note: experimental decoders can pose a security risk, do not use this for
  220. decoding untrusted input.
  221. @end table
  222. @item b_qoffset @var{float} (@emph{encoding,video})
  223. Set QP offset between P and B frames.
  224. @item err_detect @var{flags} (@emph{decoding,audio,video})
  225. Set error detection flags.
  226. Possible values:
  227. @table @samp
  228. @item crccheck
  229. verify embedded CRCs
  230. @item bitstream
  231. detect bitstream specification deviations
  232. @item buffer
  233. detect improper bitstream length
  234. @item explode
  235. abort decoding on minor error detection
  236. @item ignore_err
  237. ignore decoding errors, and continue decoding.
  238. This is useful if you want to analyze the content of a video and thus want
  239. everything to be decoded no matter what. This option will not result in a video
  240. that is pleasing to watch in case of errors.
  241. @item careful
  242. consider things that violate the spec and have not been seen in the wild as errors
  243. @item compliant
  244. consider all spec non compliancies as errors
  245. @item aggressive
  246. consider things that a sane encoder should not do as an error
  247. @end table
  248. @item has_b_frames @var{integer}
  249. @item block_align @var{integer}
  250. @item mpeg_quant @var{integer} (@emph{encoding,video})
  251. Use MPEG quantizers instead of H.263.
  252. @item qsquish @var{float} (@emph{encoding,video})
  253. How to keep quantizer between qmin and qmax (0 = clip, 1 = use
  254. differentiable function).
  255. @item rc_qmod_amp @var{float} (@emph{encoding,video})
  256. Set experimental quantizer modulation.
  257. @item rc_qmod_freq @var{integer} (@emph{encoding,video})
  258. Set experimental quantizer modulation.
  259. @item rc_override_count @var{integer}
  260. @item rc_eq @var{string} (@emph{encoding,video})
  261. Set rate control equation. When computing the expression, besides the
  262. standard functions defined in the section 'Expression Evaluation', the
  263. following functions are available: bits2qp(bits), qp2bits(qp). Also
  264. the following constants are available: iTex pTex tex mv fCode iCount
  265. mcVar var isI isP isB avgQP qComp avgIITex avgPITex avgPPTex avgBPTex
  266. avgTex.
  267. @item maxrate @var{integer} (@emph{encoding,audio,video})
  268. Set max bitrate tolerance (in bits/s). Requires bufsize to be set.
  269. @item minrate @var{integer} (@emph{encoding,audio,video})
  270. Set min bitrate tolerance (in bits/s). Most useful in setting up a CBR
  271. encode. It is of little use elsewise.
  272. @item bufsize @var{integer} (@emph{encoding,audio,video})
  273. Set ratecontrol buffer size (in bits).
  274. @item rc_buf_aggressivity @var{float} (@emph{encoding,video})
  275. Currently useless.
  276. @item i_qfactor @var{float} (@emph{encoding,video})
  277. Set QP factor between P and I frames.
  278. @item i_qoffset @var{float} (@emph{encoding,video})
  279. Set QP offset between P and I frames.
  280. @item rc_init_cplx @var{float} (@emph{encoding,video})
  281. Set initial complexity for 1-pass encoding.
  282. @item dct @var{integer} (@emph{encoding,video})
  283. Set DCT algorithm.
  284. Possible values:
  285. @table @samp
  286. @item auto
  287. autoselect a good one (default)
  288. @item fastint
  289. fast integer
  290. @item int
  291. accurate integer
  292. @item mmx
  293. @item altivec
  294. @item faan
  295. floating point AAN DCT
  296. @end table
  297. @item lumi_mask @var{float} (@emph{encoding,video})
  298. Compress bright areas stronger than medium ones.
  299. @item tcplx_mask @var{float} (@emph{encoding,video})
  300. Set temporal complexity masking.
  301. @item scplx_mask @var{float} (@emph{encoding,video})
  302. Set spatial complexity masking.
  303. @item p_mask @var{float} (@emph{encoding,video})
  304. Set inter masking.
  305. @item dark_mask @var{float} (@emph{encoding,video})
  306. Compress dark areas stronger than medium ones.
  307. @item idct @var{integer} (@emph{decoding/encoding,video})
  308. Select IDCT implementation.
  309. Possible values:
  310. @table @samp
  311. @item auto
  312. @item int
  313. @item simple
  314. @item simplemmx
  315. @item simpleauto
  316. Automatically pick a IDCT compatible with the simple one
  317. @item arm
  318. @item altivec
  319. @item sh4
  320. @item simplearm
  321. @item simplearmv5te
  322. @item simplearmv6
  323. @item simpleneon
  324. @item simplealpha
  325. @item ipp
  326. @item xvidmmx
  327. @item faani
  328. floating point AAN IDCT
  329. @end table
  330. @item slice_count @var{integer}
  331. @item ec @var{flags} (@emph{decoding,video})
  332. Set error concealment strategy.
  333. Possible values:
  334. @table @samp
  335. @item guess_mvs
  336. iterative motion vector (MV) search (slow)
  337. @item deblock
  338. use strong deblock filter for damaged MBs
  339. @item favor_inter
  340. favor predicting from the previous frame instead of the current
  341. @end table
  342. @item bits_per_coded_sample @var{integer}
  343. @item pred @var{integer} (@emph{encoding,video})
  344. Set prediction method.
  345. Possible values:
  346. @table @samp
  347. @item left
  348. @item plane
  349. @item median
  350. @end table
  351. @item aspect @var{rational number} (@emph{encoding,video})
  352. Set sample aspect ratio.
  353. @item debug @var{flags} (@emph{decoding/encoding,audio,video,subtitles})
  354. Print specific debug info.
  355. Possible values:
  356. @table @samp
  357. @item pict
  358. picture info
  359. @item rc
  360. rate control
  361. @item bitstream
  362. @item mb_type
  363. macroblock (MB) type
  364. @item qp
  365. per-block quantization parameter (QP)
  366. @item mv
  367. motion vector
  368. @item dct_coeff
  369. @item skip
  370. @item startcode
  371. @item pts
  372. @item er
  373. error recognition
  374. @item mmco
  375. memory management control operations (H.264)
  376. @item bugs
  377. @item vis_qp
  378. visualize quantization parameter (QP), lower QP are tinted greener
  379. @item vis_mb_type
  380. visualize block types
  381. @item buffers
  382. picture buffer allocations
  383. @item thread_ops
  384. threading operations
  385. @end table
  386. @item vismv @var{integer} (@emph{decoding,video})
  387. Visualize motion vectors (MVs).
  388. This option is deprecated, see the codecview filter instead.
  389. Possible values:
  390. @table @samp
  391. @item pf
  392. forward predicted MVs of P-frames
  393. @item bf
  394. forward predicted MVs of B-frames
  395. @item bb
  396. backward predicted MVs of B-frames
  397. @end table
  398. @item cmp @var{integer} (@emph{encoding,video})
  399. Set full pel me compare function.
  400. Possible values:
  401. @table @samp
  402. @item sad
  403. sum of absolute differences, fast (default)
  404. @item sse
  405. sum of squared errors
  406. @item satd
  407. sum of absolute Hadamard transformed differences
  408. @item dct
  409. sum of absolute DCT transformed differences
  410. @item psnr
  411. sum of squared quantization errors (avoid, low quality)
  412. @item bit
  413. number of bits needed for the block
  414. @item rd
  415. rate distortion optimal, slow
  416. @item zero
  417. 0
  418. @item vsad
  419. sum of absolute vertical differences
  420. @item vsse
  421. sum of squared vertical differences
  422. @item nsse
  423. noise preserving sum of squared differences
  424. @item w53
  425. 5/3 wavelet, only used in snow
  426. @item w97
  427. 9/7 wavelet, only used in snow
  428. @item dctmax
  429. @item chroma
  430. @end table
  431. @item subcmp @var{integer} (@emph{encoding,video})
  432. Set sub pel me compare function.
  433. Possible values:
  434. @table @samp
  435. @item sad
  436. sum of absolute differences, fast (default)
  437. @item sse
  438. sum of squared errors
  439. @item satd
  440. sum of absolute Hadamard transformed differences
  441. @item dct
  442. sum of absolute DCT transformed differences
  443. @item psnr
  444. sum of squared quantization errors (avoid, low quality)
  445. @item bit
  446. number of bits needed for the block
  447. @item rd
  448. rate distortion optimal, slow
  449. @item zero
  450. 0
  451. @item vsad
  452. sum of absolute vertical differences
  453. @item vsse
  454. sum of squared vertical differences
  455. @item nsse
  456. noise preserving sum of squared differences
  457. @item w53
  458. 5/3 wavelet, only used in snow
  459. @item w97
  460. 9/7 wavelet, only used in snow
  461. @item dctmax
  462. @item chroma
  463. @end table
  464. @item mbcmp @var{integer} (@emph{encoding,video})
  465. Set macroblock compare function.
  466. Possible values:
  467. @table @samp
  468. @item sad
  469. sum of absolute differences, fast (default)
  470. @item sse
  471. sum of squared errors
  472. @item satd
  473. sum of absolute Hadamard transformed differences
  474. @item dct
  475. sum of absolute DCT transformed differences
  476. @item psnr
  477. sum of squared quantization errors (avoid, low quality)
  478. @item bit
  479. number of bits needed for the block
  480. @item rd
  481. rate distortion optimal, slow
  482. @item zero
  483. 0
  484. @item vsad
  485. sum of absolute vertical differences
  486. @item vsse
  487. sum of squared vertical differences
  488. @item nsse
  489. noise preserving sum of squared differences
  490. @item w53
  491. 5/3 wavelet, only used in snow
  492. @item w97
  493. 9/7 wavelet, only used in snow
  494. @item dctmax
  495. @item chroma
  496. @end table
  497. @item ildctcmp @var{integer} (@emph{encoding,video})
  498. Set interlaced dct compare function.
  499. Possible values:
  500. @table @samp
  501. @item sad
  502. sum of absolute differences, fast (default)
  503. @item sse
  504. sum of squared errors
  505. @item satd
  506. sum of absolute Hadamard transformed differences
  507. @item dct
  508. sum of absolute DCT transformed differences
  509. @item psnr
  510. sum of squared quantization errors (avoid, low quality)
  511. @item bit
  512. number of bits needed for the block
  513. @item rd
  514. rate distortion optimal, slow
  515. @item zero
  516. 0
  517. @item vsad
  518. sum of absolute vertical differences
  519. @item vsse
  520. sum of squared vertical differences
  521. @item nsse
  522. noise preserving sum of squared differences
  523. @item w53
  524. 5/3 wavelet, only used in snow
  525. @item w97
  526. 9/7 wavelet, only used in snow
  527. @item dctmax
  528. @item chroma
  529. @end table
  530. @item dia_size @var{integer} (@emph{encoding,video})
  531. Set diamond type & size for motion estimation.
  532. @item last_pred @var{integer} (@emph{encoding,video})
  533. Set amount of motion predictors from the previous frame.
  534. @item preme @var{integer} (@emph{encoding,video})
  535. Set pre motion estimation.
  536. @item precmp @var{integer} (@emph{encoding,video})
  537. Set pre motion estimation compare function.
  538. Possible values:
  539. @table @samp
  540. @item sad
  541. sum of absolute differences, fast (default)
  542. @item sse
  543. sum of squared errors
  544. @item satd
  545. sum of absolute Hadamard transformed differences
  546. @item dct
  547. sum of absolute DCT transformed differences
  548. @item psnr
  549. sum of squared quantization errors (avoid, low quality)
  550. @item bit
  551. number of bits needed for the block
  552. @item rd
  553. rate distortion optimal, slow
  554. @item zero
  555. 0
  556. @item vsad
  557. sum of absolute vertical differences
  558. @item vsse
  559. sum of squared vertical differences
  560. @item nsse
  561. noise preserving sum of squared differences
  562. @item w53
  563. 5/3 wavelet, only used in snow
  564. @item w97
  565. 9/7 wavelet, only used in snow
  566. @item dctmax
  567. @item chroma
  568. @end table
  569. @item pre_dia_size @var{integer} (@emph{encoding,video})
  570. Set diamond type & size for motion estimation pre-pass.
  571. @item subq @var{integer} (@emph{encoding,video})
  572. Set sub pel motion estimation quality.
  573. @item dtg_active_format @var{integer}
  574. @item me_range @var{integer} (@emph{encoding,video})
  575. Set limit motion vectors range (1023 for DivX player).
  576. @item ibias @var{integer} (@emph{encoding,video})
  577. Set intra quant bias.
  578. @item pbias @var{integer} (@emph{encoding,video})
  579. Set inter quant bias.
  580. @item color_table_id @var{integer}
  581. @item global_quality @var{integer} (@emph{encoding,audio,video})
  582. @item coder @var{integer} (@emph{encoding,video})
  583. Possible values:
  584. @table @samp
  585. @item vlc
  586. variable length coder / huffman coder
  587. @item ac
  588. arithmetic coder
  589. @item raw
  590. raw (no encoding)
  591. @item rle
  592. run-length coder
  593. @item deflate
  594. deflate-based coder
  595. @end table
  596. @item context @var{integer} (@emph{encoding,video})
  597. Set context model.
  598. @item slice_flags @var{integer}
  599. @item xvmc_acceleration @var{integer}
  600. @item mbd @var{integer} (@emph{encoding,video})
  601. Set macroblock decision algorithm (high quality mode).
  602. Possible values:
  603. @table @samp
  604. @item simple
  605. use mbcmp (default)
  606. @item bits
  607. use fewest bits
  608. @item rd
  609. use best rate distortion
  610. @end table
  611. @item stream_codec_tag @var{integer}
  612. @item sc_threshold @var{integer} (@emph{encoding,video})
  613. Set scene change threshold.
  614. @item lmin @var{integer} (@emph{encoding,video})
  615. Set min lagrange factor (VBR).
  616. @item lmax @var{integer} (@emph{encoding,video})
  617. Set max lagrange factor (VBR).
  618. @item nr @var{integer} (@emph{encoding,video})
  619. Set noise reduction.
  620. @item rc_init_occupancy @var{integer} (@emph{encoding,video})
  621. Set number of bits which should be loaded into the rc buffer before
  622. decoding starts.
  623. @item flags2 @var{flags} (@emph{decoding/encoding,audio,video})
  624. Possible values:
  625. @table @samp
  626. @item fast
  627. Allow non spec compliant speedup tricks.
  628. @item sgop
  629. Deprecated, use mpegvideo private options instead.
  630. @item noout
  631. Skip bitstream encoding.
  632. @item ignorecrop
  633. Ignore cropping information from sps.
  634. @item local_header
  635. Place global headers at every keyframe instead of in extradata.
  636. @item chunks
  637. Frame data might be split into multiple chunks.
  638. @item showall
  639. Show all frames before the first keyframe.
  640. @item skiprd
  641. Deprecated, use mpegvideo private options instead.
  642. @item export_mvs
  643. Export motion vectors into frame side-data (see @code{AV_FRAME_DATA_MOTION_VECTORS})
  644. for codecs that support it. See also @file{doc/examples/export_mvs.c}.
  645. @end table
  646. @item error @var{integer} (@emph{encoding,video})
  647. @item qns @var{integer} (@emph{encoding,video})
  648. Deprecated, use mpegvideo private options instead.
  649. @item threads @var{integer} (@emph{decoding/encoding,video})
  650. Possible values:
  651. @table @samp
  652. @item auto
  653. detect a good number of threads
  654. @end table
  655. @item me_threshold @var{integer} (@emph{encoding,video})
  656. Set motion estimation threshold.
  657. @item mb_threshold @var{integer} (@emph{encoding,video})
  658. Set macroblock threshold.
  659. @item dc @var{integer} (@emph{encoding,video})
  660. Set intra_dc_precision.
  661. @item nssew @var{integer} (@emph{encoding,video})
  662. Set nsse weight.
  663. @item skip_top @var{integer} (@emph{decoding,video})
  664. Set number of macroblock rows at the top which are skipped.
  665. @item skip_bottom @var{integer} (@emph{decoding,video})
  666. Set number of macroblock rows at the bottom which are skipped.
  667. @item profile @var{integer} (@emph{encoding,audio,video})
  668. Possible values:
  669. @table @samp
  670. @item unknown
  671. @item aac_main
  672. @item aac_low
  673. @item aac_ssr
  674. @item aac_ltp
  675. @item aac_he
  676. @item aac_he_v2
  677. @item aac_ld
  678. @item aac_eld
  679. @item mpeg2_aac_low
  680. @item mpeg2_aac_he
  681. @item dts
  682. @item dts_es
  683. @item dts_96_24
  684. @item dts_hd_hra
  685. @item dts_hd_ma
  686. @end table
  687. @item level @var{integer} (@emph{encoding,audio,video})
  688. Possible values:
  689. @table @samp
  690. @item unknown
  691. @end table
  692. @item lowres @var{integer} (@emph{decoding,audio,video})
  693. Decode at 1= 1/2, 2=1/4, 3=1/8 resolutions.
  694. @item skip_threshold @var{integer} (@emph{encoding,video})
  695. Set frame skip threshold.
  696. @item skip_factor @var{integer} (@emph{encoding,video})
  697. Set frame skip factor.
  698. @item skip_exp @var{integer} (@emph{encoding,video})
  699. Set frame skip exponent.
  700. Negative values behave identical to the corresponding positive ones, except
  701. that the score is normalized.
  702. Positive values exist primarily for compatibility reasons and are not so useful.
  703. @item skipcmp @var{integer} (@emph{encoding,video})
  704. Set frame skip compare function.
  705. Possible values:
  706. @table @samp
  707. @item sad
  708. sum of absolute differences, fast (default)
  709. @item sse
  710. sum of squared errors
  711. @item satd
  712. sum of absolute Hadamard transformed differences
  713. @item dct
  714. sum of absolute DCT transformed differences
  715. @item psnr
  716. sum of squared quantization errors (avoid, low quality)
  717. @item bit
  718. number of bits needed for the block
  719. @item rd
  720. rate distortion optimal, slow
  721. @item zero
  722. 0
  723. @item vsad
  724. sum of absolute vertical differences
  725. @item vsse
  726. sum of squared vertical differences
  727. @item nsse
  728. noise preserving sum of squared differences
  729. @item w53
  730. 5/3 wavelet, only used in snow
  731. @item w97
  732. 9/7 wavelet, only used in snow
  733. @item dctmax
  734. @item chroma
  735. @end table
  736. @item border_mask @var{float} (@emph{encoding,video})
  737. Increase the quantizer for macroblocks close to borders.
  738. @item mblmin @var{integer} (@emph{encoding,video})
  739. Set min macroblock lagrange factor (VBR).
  740. @item mblmax @var{integer} (@emph{encoding,video})
  741. Set max macroblock lagrange factor (VBR).
  742. @item mepc @var{integer} (@emph{encoding,video})
  743. Set motion estimation bitrate penalty compensation (1.0 = 256).
  744. @item skip_loop_filter @var{integer} (@emph{decoding,video})
  745. @item skip_idct @var{integer} (@emph{decoding,video})
  746. @item skip_frame @var{integer} (@emph{decoding,video})
  747. Make decoder discard processing depending on the frame type selected
  748. by the option value.
  749. @option{skip_loop_filter} skips frame loop filtering, @option{skip_idct}
  750. skips frame IDCT/dequantization, @option{skip_frame} skips decoding.
  751. Possible values:
  752. @table @samp
  753. @item none
  754. Discard no frame.
  755. @item default
  756. Discard useless frames like 0-sized frames.
  757. @item noref
  758. Discard all non-reference frames.
  759. @item bidir
  760. Discard all bidirectional frames.
  761. @item nokey
  762. Discard all frames excepts keyframes.
  763. @item all
  764. Discard all frames.
  765. @end table
  766. Default value is @samp{default}.
  767. @item bidir_refine @var{integer} (@emph{encoding,video})
  768. Refine the two motion vectors used in bidirectional macroblocks.
  769. @item brd_scale @var{integer} (@emph{encoding,video})
  770. Downscale frames for dynamic B-frame decision.
  771. @item keyint_min @var{integer} (@emph{encoding,video})
  772. Set minimum interval between IDR-frames.
  773. @item refs @var{integer} (@emph{encoding,video})
  774. Set reference frames to consider for motion compensation.
  775. @item chromaoffset @var{integer} (@emph{encoding,video})
  776. Set chroma qp offset from luma.
  777. @item trellis @var{integer} (@emph{encoding,audio,video})
  778. Set rate-distortion optimal quantization.
  779. @item sc_factor @var{integer} (@emph{encoding,video})
  780. Set value multiplied by qscale for each frame and added to
  781. scene_change_score.
  782. @item mv0_threshold @var{integer} (@emph{encoding,video})
  783. @item b_sensitivity @var{integer} (@emph{encoding,video})
  784. Adjust sensitivity of b_frame_strategy 1.
  785. @item compression_level @var{integer} (@emph{encoding,audio,video})
  786. @item min_prediction_order @var{integer} (@emph{encoding,audio})
  787. @item max_prediction_order @var{integer} (@emph{encoding,audio})
  788. @item timecode_frame_start @var{integer} (@emph{encoding,video})
  789. Set GOP timecode frame start number, in non drop frame format.
  790. @item request_channels @var{integer} (@emph{decoding,audio})
  791. Set desired number of audio channels.
  792. @item bits_per_raw_sample @var{integer}
  793. @item channel_layout @var{integer} (@emph{decoding/encoding,audio})
  794. Possible values:
  795. @table @samp
  796. @end table
  797. @item request_channel_layout @var{integer} (@emph{decoding,audio})
  798. Possible values:
  799. @table @samp
  800. @end table
  801. @item rc_max_vbv_use @var{float} (@emph{encoding,video})
  802. @item rc_min_vbv_use @var{float} (@emph{encoding,video})
  803. @item ticks_per_frame @var{integer} (@emph{decoding/encoding,audio,video})
  804. @item color_primaries @var{integer} (@emph{decoding/encoding,video})
  805. @item color_trc @var{integer} (@emph{decoding/encoding,video})
  806. @item colorspace @var{integer} (@emph{decoding/encoding,video})
  807. @item color_range @var{integer} (@emph{decoding/encoding,video})
  808. @item chroma_sample_location @var{integer} (@emph{decoding/encoding,video})
  809. @item log_level_offset @var{integer}
  810. Set the log level offset.
  811. @item slices @var{integer} (@emph{encoding,video})
  812. Number of slices, used in parallelized encoding.
  813. @item thread_type @var{flags} (@emph{decoding/encoding,video})
  814. Select which multithreading methods to use.
  815. Use of @samp{frame} will increase decoding delay by one frame per
  816. thread, so clients which cannot provide future frames should not use
  817. it.
  818. Possible values:
  819. @table @samp
  820. @item slice
  821. Decode more than one part of a single frame at once.
  822. Multithreading using slices works only when the video was encoded with
  823. slices.
  824. @item frame
  825. Decode more than one frame at once.
  826. @end table
  827. Default value is @samp{slice+frame}.
  828. @item audio_service_type @var{integer} (@emph{encoding,audio})
  829. Set audio service type.
  830. Possible values:
  831. @table @samp
  832. @item ma
  833. Main Audio Service
  834. @item ef
  835. Effects
  836. @item vi
  837. Visually Impaired
  838. @item hi
  839. Hearing Impaired
  840. @item di
  841. Dialogue
  842. @item co
  843. Commentary
  844. @item em
  845. Emergency
  846. @item vo
  847. Voice Over
  848. @item ka
  849. Karaoke
  850. @end table
  851. @item request_sample_fmt @var{sample_fmt} (@emph{decoding,audio})
  852. Set sample format audio decoders should prefer. Default value is
  853. @code{none}.
  854. @item pkt_timebase @var{rational number}
  855. @item sub_charenc @var{encoding} (@emph{decoding,subtitles})
  856. Set the input subtitles character encoding.
  857. @item field_order @var{field_order} (@emph{video})
  858. Set/override the field order of the video.
  859. Possible values:
  860. @table @samp
  861. @item progressive
  862. Progressive video
  863. @item tt
  864. Interlaced video, top field coded and displayed first
  865. @item bb
  866. Interlaced video, bottom field coded and displayed first
  867. @item tb
  868. Interlaced video, top coded first, bottom displayed first
  869. @item bt
  870. Interlaced video, bottom coded first, top displayed first
  871. @end table
  872. @item skip_alpha @var{integer} (@emph{decoding,video})
  873. Set to 1 to disable processing alpha (transparency). This works like the
  874. @samp{gray} flag in the @option{flags} option which skips chroma information
  875. instead of alpha. Default is 0.
  876. @end table
  877. @c man end CODEC OPTIONS
  878. @ifclear config-writeonly
  879. @include decoders.texi
  880. @end ifclear
  881. @ifclear config-readonly
  882. @include encoders.texi
  883. @end ifclear