codecs.texi 30 KB

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