syntax.texi 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158
  1. @chapter Syntax
  2. @c man begin SYNTAX
  3. When evaluating specific formats, FFmpeg uses internal library parsing
  4. functions, shared by the tools. This section documents the syntax of
  5. some of these formats.
  6. @anchor{date syntax}
  7. @section Date
  8. The accepted syntax is:
  9. @example
  10. [(YYYY-MM-DD|YYYYMMDD)[T|t| ]]((HH:MM:SS[.m...]]])|(HHMMSS[.m...]]]))[Z]
  11. now
  12. @end example
  13. If the value is "now" it takes the current time.
  14. Time is local time unless Z is appended, in which case it is
  15. interpreted as UTC.
  16. If the year-month-day part is not specified it takes the current
  17. year-month-day.
  18. @anchor{time duration syntax}
  19. @section Time duration
  20. The accepted syntax is:
  21. @example
  22. [-]HH:MM:SS[.m...]
  23. [-]S+[.m...]
  24. @end example
  25. @var{HH} expresses the number of hours, @var{MM} the number a of minutes
  26. and @var{SS} the number of seconds.
  27. @anchor{video size syntax}
  28. @section Video size
  29. Specify the size of the sourced video, it may be a string of the form
  30. @var{width}x@var{height}, or the name of a size abbreviation.
  31. The following abbreviations are recognized:
  32. @table @samp
  33. @item sqcif
  34. 128x96
  35. @item qcif
  36. 176x144
  37. @item cif
  38. 352x288
  39. @item 4cif
  40. 704x576
  41. @item 16cif
  42. 1408x1152
  43. @item qqvga
  44. 160x120
  45. @item qvga
  46. 320x240
  47. @item vga
  48. 640x480
  49. @item svga
  50. 800x600
  51. @item xga
  52. 1024x768
  53. @item uxga
  54. 1600x1200
  55. @item qxga
  56. 2048x1536
  57. @item sxga
  58. 1280x1024
  59. @item qsxga
  60. 2560x2048
  61. @item hsxga
  62. 5120x4096
  63. @item wvga
  64. 852x480
  65. @item wxga
  66. 1366x768
  67. @item wsxga
  68. 1600x1024
  69. @item wuxga
  70. 1920x1200
  71. @item woxga
  72. 2560x1600
  73. @item wqsxga
  74. 3200x2048
  75. @item wquxga
  76. 3840x2400
  77. @item whsxga
  78. 6400x4096
  79. @item whuxga
  80. 7680x4800
  81. @item cga
  82. 320x200
  83. @item ega
  84. 640x350
  85. @item hd480
  86. 852x480
  87. @item hd720
  88. 1280x720
  89. @item hd1080
  90. 1920x1080
  91. @end table
  92. @anchor{video rate syntax}
  93. @section Video rate
  94. Specify the frame rate of a video, expressed as the number of frames
  95. generated per second. It has to be a string in the format
  96. @var{frame_rate_num}/@var{frame_rate_den}, an integer number, a float
  97. number or a valid video frame rate abbreviation.
  98. The following abbreviations are recognized:
  99. @table @samp
  100. @item ntsc
  101. 30000/1001
  102. @item pal
  103. 25/1
  104. @item qntsc
  105. 30000/1
  106. @item qpal
  107. 25/1
  108. @item sntsc
  109. 30000/1
  110. @item spal
  111. 25/1
  112. @item film
  113. 24/1
  114. @item ntsc-film
  115. 24000/1
  116. @end table
  117. @anchor{ratio syntax}
  118. @section Ratio
  119. A ratio can be expressed as an expression, or in the form
  120. @var{numerator}:@var{denominator}.
  121. Note that a ratio with infinite (1/0) or negative value is
  122. considered valid, so you should check on the returned value if you
  123. want to exclude those values.
  124. The undefined value can be expressed using the "0:0" string.
  125. @anchor{color syntax}
  126. @section Color
  127. It can be the name of a color (case insensitive match) or a
  128. [0x|#]RRGGBB[AA] sequence, possibly followed by "@" and a string
  129. representing the alpha component.
  130. The alpha component may be a string composed by "0x" followed by an
  131. hexadecimal number or a decimal number between 0.0 and 1.0, which
  132. represents the opacity value (0x00/0.0 means completely transparent,
  133. 0xff/1.0 completely opaque).
  134. If the alpha component is not specified then 0xff is assumed.
  135. The string "random" will result in a random color.
  136. @c man end SYNTAX