10 | 8 |
deleted file mode 100644 |
... | ... |
@@ -1,303 +0,0 @@ |
1 |
-@chapter Expression Evaluation |
|
2 |
-@c man begin EXPRESSION EVALUATION |
|
3 |
- |
|
4 |
-When evaluating an arithmetic expression, FFmpeg uses an internal |
|
5 |
-formula evaluator, implemented through the @file{libavutil/eval.h} |
|
6 |
-interface. |
|
7 |
- |
|
8 |
-An expression may contain unary, binary operators, constants, and |
|
9 |
-functions. |
|
10 |
- |
|
11 |
-Two expressions @var{expr1} and @var{expr2} can be combined to form |
|
12 |
-another expression "@var{expr1};@var{expr2}". |
|
13 |
-@var{expr1} and @var{expr2} are evaluated in turn, and the new |
|
14 |
-expression evaluates to the value of @var{expr2}. |
|
15 |
- |
|
16 |
-The following binary operators are available: @code{+}, @code{-}, |
|
17 |
-@code{*}, @code{/}, @code{^}. |
|
18 |
- |
|
19 |
-The following unary operators are available: @code{+}, @code{-}. |
|
20 |
- |
|
21 |
-The following functions are available: |
|
22 |
-@table @option |
|
23 |
-@item abs(x) |
|
24 |
-Compute absolute value of @var{x}. |
|
25 |
- |
|
26 |
-@item acos(x) |
|
27 |
-Compute arccosine of @var{x}. |
|
28 |
- |
|
29 |
-@item asin(x) |
|
30 |
-Compute arcsine of @var{x}. |
|
31 |
- |
|
32 |
-@item atan(x) |
|
33 |
-Compute arctangent of @var{x}. |
|
34 |
- |
|
35 |
-@item between(x, min, max) |
|
36 |
-Return 1 if @var{x} is greater than or equal to @var{min} and lesser than or |
|
37 |
-equal to @var{max}, 0 otherwise. |
|
38 |
- |
|
39 |
-@item bitand(x, y) |
|
40 |
-@item bitor(x, y) |
|
41 |
-Compute bitwise and/or operation on @var{x} and @var{y}. |
|
42 |
- |
|
43 |
-The results of the evaluation of @var{x} and @var{y} are converted to |
|
44 |
-integers before executing the bitwise operation. |
|
45 |
- |
|
46 |
-Note that both the conversion to integer and the conversion back to |
|
47 |
-floating point can lose precision. Beware of unexpected results for |
|
48 |
-large numbers (usually 2^53 and larger). |
|
49 |
- |
|
50 |
-@item ceil(expr) |
|
51 |
-Round the value of expression @var{expr} upwards to the nearest |
|
52 |
-integer. For example, "ceil(1.5)" is "2.0". |
|
53 |
- |
|
54 |
-@item cos(x) |
|
55 |
-Compute cosine of @var{x}. |
|
56 |
- |
|
57 |
-@item cosh(x) |
|
58 |
-Compute hyperbolic cosine of @var{x}. |
|
59 |
- |
|
60 |
-@item eq(x, y) |
|
61 |
-Return 1 if @var{x} and @var{y} are equivalent, 0 otherwise. |
|
62 |
- |
|
63 |
-@item exp(x) |
|
64 |
-Compute exponential of @var{x} (with base @code{e}, the Euler's number). |
|
65 |
- |
|
66 |
-@item floor(expr) |
|
67 |
-Round the value of expression @var{expr} downwards to the nearest |
|
68 |
-integer. For example, "floor(-1.5)" is "-2.0". |
|
69 |
- |
|
70 |
-@item gauss(x) |
|
71 |
-Compute Gauss function of @var{x}, corresponding to |
|
72 |
-@code{exp(-x*x/2) / sqrt(2*PI)}. |
|
73 |
- |
|
74 |
-@item gcd(x, y) |
|
75 |
-Return the greatest common divisor of @var{x} and @var{y}. If both @var{x} and |
|
76 |
-@var{y} are 0 or either or both are less than zero then behavior is undefined. |
|
77 |
- |
|
78 |
-@item gt(x, y) |
|
79 |
-Return 1 if @var{x} is greater than @var{y}, 0 otherwise. |
|
80 |
- |
|
81 |
-@item gte(x, y) |
|
82 |
-Return 1 if @var{x} is greater than or equal to @var{y}, 0 otherwise. |
|
83 |
- |
|
84 |
-@item hypot(x, y) |
|
85 |
-This function is similar to the C function with the same name; it returns |
|
86 |
-"sqrt(@var{x}*@var{x} + @var{y}*@var{y})", the length of the hypotenuse of a |
|
87 |
-right triangle with sides of length @var{x} and @var{y}, or the distance of the |
|
88 |
-point (@var{x}, @var{y}) from the origin. |
|
89 |
- |
|
90 |
-@item if(x, y) |
|
91 |
-Evaluate @var{x}, and if the result is non-zero return the result of |
|
92 |
-the evaluation of @var{y}, return 0 otherwise. |
|
93 |
- |
|
94 |
-@item if(x, y, z) |
|
95 |
-Evaluate @var{x}, and if the result is non-zero return the evaluation |
|
96 |
-result of @var{y}, otherwise the evaluation result of @var{z}. |
|
97 |
- |
|
98 |
-@item ifnot(x, y) |
|
99 |
-Evaluate @var{x}, and if the result is zero return the result of the |
|
100 |
-evaluation of @var{y}, return 0 otherwise. |
|
101 |
- |
|
102 |
-@item ifnot(x, y, z) |
|
103 |
-Evaluate @var{x}, and if the result is zero return the evaluation |
|
104 |
-result of @var{y}, otherwise the evaluation result of @var{z}. |
|
105 |
- |
|
106 |
-@item isinf(x) |
|
107 |
-Return 1.0 if @var{x} is +/-INFINITY, 0.0 otherwise. |
|
108 |
- |
|
109 |
-@item isnan(x) |
|
110 |
-Return 1.0 if @var{x} is NAN, 0.0 otherwise. |
|
111 |
- |
|
112 |
-@item ld(var) |
|
113 |
-Allow to load the value of the internal variable with number |
|
114 |
-@var{var}, which was previously stored with st(@var{var}, @var{expr}). |
|
115 |
-The function returns the loaded value. |
|
116 |
- |
|
117 |
-@item log(x) |
|
118 |
-Compute natural logarithm of @var{x}. |
|
119 |
- |
|
120 |
-@item lt(x, y) |
|
121 |
-Return 1 if @var{x} is lesser than @var{y}, 0 otherwise. |
|
122 |
- |
|
123 |
-@item lte(x, y) |
|
124 |
-Return 1 if @var{x} is lesser than or equal to @var{y}, 0 otherwise. |
|
125 |
- |
|
126 |
-@item max(x, y) |
|
127 |
-Return the maximum between @var{x} and @var{y}. |
|
128 |
- |
|
129 |
-@item min(x, y) |
|
130 |
-Return the maximum between @var{x} and @var{y}. |
|
131 |
- |
|
132 |
-@item mod(x, y) |
|
133 |
-Compute the remainder of division of @var{x} by @var{y}. |
|
134 |
- |
|
135 |
-@item not(expr) |
|
136 |
-Return 1.0 if @var{expr} is zero, 0.0 otherwise. |
|
137 |
- |
|
138 |
-@item pow(x, y) |
|
139 |
-Compute the power of @var{x} elevated @var{y}, it is equivalent to |
|
140 |
-"(@var{x})^(@var{y})". |
|
141 |
- |
|
142 |
-@item print(t) |
|
143 |
-@item print(t, l) |
|
144 |
-Print the value of expression @var{t} with loglevel @var{l}. If |
|
145 |
-@var{l} is not specified then a default log level is used. |
|
146 |
-Returns the value of the expression printed. |
|
147 |
- |
|
148 |
-Prints t with loglevel l |
|
149 |
- |
|
150 |
-@item random(x) |
|
151 |
-Return a pseudo random value between 0.0 and 1.0. @var{x} is the index of the |
|
152 |
-internal variable which will be used to save the seed/state. |
|
153 |
- |
|
154 |
-@item root(expr, max) |
|
155 |
-Find an input value for which the function represented by @var{expr} |
|
156 |
-with argument @var{ld(0)} is 0 in the interval 0..@var{max}. |
|
157 |
- |
|
158 |
-The expression in @var{expr} must denote a continuous function or the |
|
159 |
-result is undefined. |
|
160 |
- |
|
161 |
-@var{ld(0)} is used to represent the function input value, which means |
|
162 |
-that the given expression will be evaluated multiple times with |
|
163 |
-various input values that the expression can access through |
|
164 |
-@code{ld(0)}. When the expression evaluates to 0 then the |
|
165 |
-corresponding input value will be returned. |
|
166 |
- |
|
167 |
-@item sin(x) |
|
168 |
-Compute sine of @var{x}. |
|
169 |
- |
|
170 |
-@item sinh(x) |
|
171 |
-Compute hyperbolic sine of @var{x}. |
|
172 |
- |
|
173 |
-@item sqrt(expr) |
|
174 |
-Compute the square root of @var{expr}. This is equivalent to |
|
175 |
-"(@var{expr})^.5". |
|
176 |
- |
|
177 |
-@item squish(x) |
|
178 |
-Compute expression @code{1/(1 + exp(4*x))}. |
|
179 |
- |
|
180 |
-@item st(var, expr) |
|
181 |
-Allow to store the value of the expression @var{expr} in an internal |
|
182 |
-variable. @var{var} specifies the number of the variable where to |
|
183 |
-store the value, and it is a value ranging from 0 to 9. The function |
|
184 |
-returns the value stored in the internal variable. |
|
185 |
-Note, Variables are currently not shared between expressions. |
|
186 |
- |
|
187 |
-@item tan(x) |
|
188 |
-Compute tangent of @var{x}. |
|
189 |
- |
|
190 |
-@item tanh(x) |
|
191 |
-Compute hyperbolic tangent of @var{x}. |
|
192 |
- |
|
193 |
-@item taylor(expr, x) |
|
194 |
-@item taylor(expr, x, id) |
|
195 |
-Evaluate a Taylor series at @var{x}, given an expression representing |
|
196 |
-the @code{ld(id)}-th derivative of a function at 0. |
|
197 |
- |
|
198 |
-When the series does not converge the result is undefined. |
|
199 |
- |
|
200 |
-@var{ld(id)} is used to represent the derivative order in @var{expr}, |
|
201 |
-which means that the given expression will be evaluated multiple times |
|
202 |
-with various input values that the expression can access through |
|
203 |
-@code{ld(id)}. If @var{id} is not specified then 0 is assumed. |
|
204 |
- |
|
205 |
-Note, when you have the derivatives at y instead of 0, |
|
206 |
-@code{taylor(expr, x-y)} can be used. |
|
207 |
- |
|
208 |
-@item time(0) |
|
209 |
-Return the current (wallclock) time in seconds. |
|
210 |
- |
|
211 |
-@item trunc(expr) |
|
212 |
-Round the value of expression @var{expr} towards zero to the nearest |
|
213 |
-integer. For example, "trunc(-1.5)" is "-1.0". |
|
214 |
- |
|
215 |
-@item while(cond, expr) |
|
216 |
-Evaluate expression @var{expr} while the expression @var{cond} is |
|
217 |
-non-zero, and returns the value of the last @var{expr} evaluation, or |
|
218 |
-NAN if @var{cond} was always false. |
|
219 |
-@end table |
|
220 |
- |
|
221 |
-The following constants are available: |
|
222 |
-@table @option |
|
223 |
-@item PI |
|
224 |
-area of the unit disc, approximately 3.14 |
|
225 |
-@item E |
|
226 |
-exp(1) (Euler's number), approximately 2.718 |
|
227 |
-@item PHI |
|
228 |
-golden ratio (1+sqrt(5))/2, approximately 1.618 |
|
229 |
-@end table |
|
230 |
- |
|
231 |
-Assuming that an expression is considered "true" if it has a non-zero |
|
232 |
-value, note that: |
|
233 |
- |
|
234 |
-@code{*} works like AND |
|
235 |
- |
|
236 |
-@code{+} works like OR |
|
237 |
- |
|
238 |
-For example the construct: |
|
239 |
-@example |
|
240 |
-if (A AND B) then C |
|
241 |
-@end example |
|
242 |
-is equivalent to: |
|
243 |
-@example |
|
244 |
-if(A*B, C) |
|
245 |
-@end example |
|
246 |
- |
|
247 |
-In your C code, you can extend the list of unary and binary functions, |
|
248 |
-and define recognized constants, so that they are available for your |
|
249 |
-expressions. |
|
250 |
- |
|
251 |
-The evaluator also recognizes the International System unit prefixes. |
|
252 |
-If 'i' is appended after the prefix, binary prefixes are used, which |
|
253 |
-are based on powers of 1024 instead of powers of 1000. |
|
254 |
-The 'B' postfix multiplies the value by 8, and can be appended after a |
|
255 |
-unit prefix or used alone. This allows using for example 'KB', 'MiB', |
|
256 |
-'G' and 'B' as number postfix. |
|
257 |
- |
|
258 |
-The list of available International System prefixes follows, with |
|
259 |
-indication of the corresponding powers of 10 and of 2. |
|
260 |
-@table @option |
|
261 |
-@item y |
|
262 |
-10^-24 / 2^-80 |
|
263 |
-@item z |
|
264 |
-10^-21 / 2^-70 |
|
265 |
-@item a |
|
266 |
-10^-18 / 2^-60 |
|
267 |
-@item f |
|
268 |
-10^-15 / 2^-50 |
|
269 |
-@item p |
|
270 |
-10^-12 / 2^-40 |
|
271 |
-@item n |
|
272 |
-10^-9 / 2^-30 |
|
273 |
-@item u |
|
274 |
-10^-6 / 2^-20 |
|
275 |
-@item m |
|
276 |
-10^-3 / 2^-10 |
|
277 |
-@item c |
|
278 |
-10^-2 |
|
279 |
-@item d |
|
280 |
-10^-1 |
|
281 |
-@item h |
|
282 |
-10^2 |
|
283 |
-@item k |
|
284 |
-10^3 / 2^10 |
|
285 |
-@item K |
|
286 |
-10^3 / 2^10 |
|
287 |
-@item M |
|
288 |
-10^6 / 2^20 |
|
289 |
-@item G |
|
290 |
-10^9 / 2^30 |
|
291 |
-@item T |
|
292 |
-10^12 / 2^40 |
|
293 |
-@item P |
|
294 |
-10^15 / 2^40 |
|
295 |
-@item E |
|
296 |
-10^18 / 2^50 |
|
297 |
-@item Z |
|
298 |
-10^21 / 2^60 |
|
299 |
-@item Y |
|
300 |
-10^24 / 2^70 |
|
301 |
-@end table |
|
302 |
- |
|
303 |
-@c man end |
26 | 24 |
deleted file mode 100644 |
... | ... |
@@ -1,22 +0,0 @@ |
1 |
-@chapter OpenCL Options |
|
2 |
-@c man begin OPENCL OPTIONS |
|
3 |
- |
|
4 |
-When FFmpeg is configured with @code{--enable-opencl}, it is possible |
|
5 |
-to set the options to set in the global OpenCL context. The list of |
|
6 |
-supported options follows: |
|
7 |
- |
|
8 |
-@table @option |
|
9 |
-@item build_options |
|
10 |
-Set build options which used to compiled kernels, see reference "OpenCL Specification Version: 1.2 chapter 5.6.4" |
|
11 |
- |
|
12 |
-@item platform_idx |
|
13 |
-Select platform to run OpenCL code, the platform_idx is the index of platform |
|
14 |
-in the device list which can be obtained with av_opencl_get_device_list(). |
|
15 |
- |
|
16 |
-@item device_idx |
|
17 |
-Select device to run OpenCL code, the device_idx is the index of device in |
|
18 |
-the device list which can be obtained with av_opencl_get_device_list(). |
|
19 |
- |
|
20 |
-@end table |
|
21 |
- |
|
22 |
-@c man end OPENCL OPTIONS |
23 | 1 |
deleted file mode 100644 |
... | ... |
@@ -1,258 +0,0 @@ |
1 |
-@chapter Syntax |
|
2 |
-@c man begin SYNTAX |
|
3 |
- |
|
4 |
-This section documents the syntax and formats employed by the FFmpeg |
|
5 |
-libraries and tools. |
|
6 |
- |
|
7 |
-@anchor{quoting_and_escaping} |
|
8 |
-@section Quoting and escaping |
|
9 |
- |
|
10 |
-FFmpeg adopts the following quoting and escaping mechanism, unless |
|
11 |
-explicitly specified. The following rules are applied: |
|
12 |
- |
|
13 |
-@itemize |
|
14 |
-@item |
|
15 |
-@code{'} and @code{\} are special characters (respectively used for |
|
16 |
-quoting and escaping). In addition to them, there might be other |
|
17 |
-special characters depending on the specific syntax where the escaping |
|
18 |
-and quoting are employed. |
|
19 |
- |
|
20 |
-@item |
|
21 |
-A special character is escaped by prefixing it with a '\'. |
|
22 |
- |
|
23 |
-@item |
|
24 |
-All characters enclosed between '' are included literally in the |
|
25 |
-parsed string. The quote character @code{'} itself cannot be quoted, |
|
26 |
-so you may need to close the quote and escape it. |
|
27 |
- |
|
28 |
-@item |
|
29 |
-Leading and trailing whitespaces, unless escaped or quoted, are |
|
30 |
-removed from the parsed string. |
|
31 |
-@end itemize |
|
32 |
- |
|
33 |
-Note that you may need to add a second level of escaping when using |
|
34 |
-the command line or a script, which depends on the syntax of the |
|
35 |
-adopted shell language. |
|
36 |
- |
|
37 |
-The function @code{av_get_token} defined in |
|
38 |
-@file{libavutil/avstring.h} can be used to parse a token quoted or |
|
39 |
-escaped according to the rules defined above. |
|
40 |
- |
|
41 |
-The tool @file{tools/ffescape} in the FFmpeg source tree can be used |
|
42 |
-to automatically quote or escape a string in a script. |
|
43 |
- |
|
44 |
-@subsection Examples |
|
45 |
- |
|
46 |
-@itemize |
|
47 |
-@item |
|
48 |
-Escape the string @code{Crime d'Amour} containing the @code{'} special |
|
49 |
-character: |
|
50 |
-@example |
|
51 |
-Crime d\'Amour |
|
52 |
-@end example |
|
53 |
- |
|
54 |
-@item |
|
55 |
-The string above contains a quote, so the @code{'} needs to be escaped |
|
56 |
-when quoting it: |
|
57 |
-@example |
|
58 |
-'Crime d'\''Amour' |
|
59 |
-@end example |
|
60 |
- |
|
61 |
-@item |
|
62 |
-Include leading or trailing whitespaces using quoting: |
|
63 |
-@example |
|
64 |
-' this string starts and ends with whitespaces ' |
|
65 |
-@end example |
|
66 |
- |
|
67 |
-@item |
|
68 |
-Escaping and quoting can be mixed together: |
|
69 |
-@example |
|
70 |
-' The string '\'string\'' is a string ' |
|
71 |
-@end example |
|
72 |
- |
|
73 |
-@item |
|
74 |
-To include a literal @code{\} you can use either escaping or quoting: |
|
75 |
-@example |
|
76 |
-'c:\foo' can be written as c:\\foo |
|
77 |
-@end example |
|
78 |
-@end itemize |
|
79 |
- |
|
80 |
-@anchor{date syntax} |
|
81 |
-@section Date |
|
82 |
- |
|
83 |
-The accepted syntax is: |
|
84 |
-@example |
|
85 |
-[(YYYY-MM-DD|YYYYMMDD)[T|t| ]]((HH:MM:SS[.m...]]])|(HHMMSS[.m...]]]))[Z] |
|
86 |
-now |
|
87 |
-@end example |
|
88 |
- |
|
89 |
-If the value is "now" it takes the current time. |
|
90 |
- |
|
91 |
-Time is local time unless Z is appended, in which case it is |
|
92 |
-interpreted as UTC. |
|
93 |
-If the year-month-day part is not specified it takes the current |
|
94 |
-year-month-day. |
|
95 |
- |
|
96 |
-@anchor{time duration syntax} |
|
97 |
-@section Time duration |
|
98 |
- |
|
99 |
-The accepted syntax is: |
|
100 |
-@example |
|
101 |
-[-][HH:]MM:SS[.m...] |
|
102 |
-[-]S+[.m...] |
|
103 |
-@end example |
|
104 |
- |
|
105 |
-@var{HH} expresses the number of hours, @var{MM} the number a of minutes |
|
106 |
-and @var{SS} the number of seconds. |
|
107 |
- |
|
108 |
-@anchor{video size syntax} |
|
109 |
-@section Video size |
|
110 |
-Specify the size of the sourced video, it may be a string of the form |
|
111 |
-@var{width}x@var{height}, or the name of a size abbreviation. |
|
112 |
- |
|
113 |
-The following abbreviations are recognized: |
|
114 |
-@table @samp |
|
115 |
-@item ntsc |
|
116 |
-720x480 |
|
117 |
-@item pal |
|
118 |
-720x576 |
|
119 |
-@item qntsc |
|
120 |
-352x240 |
|
121 |
-@item qpal |
|
122 |
-352x288 |
|
123 |
-@item sntsc |
|
124 |
-640x480 |
|
125 |
-@item spal |
|
126 |
-768x576 |
|
127 |
-@item film |
|
128 |
-352x240 |
|
129 |
-@item ntsc-film |
|
130 |
-352x240 |
|
131 |
-@item sqcif |
|
132 |
-128x96 |
|
133 |
-@item qcif |
|
134 |
-176x144 |
|
135 |
-@item cif |
|
136 |
-352x288 |
|
137 |
-@item 4cif |
|
138 |
-704x576 |
|
139 |
-@item 16cif |
|
140 |
-1408x1152 |
|
141 |
-@item qqvga |
|
142 |
-160x120 |
|
143 |
-@item qvga |
|
144 |
-320x240 |
|
145 |
-@item vga |
|
146 |
-640x480 |
|
147 |
-@item svga |
|
148 |
-800x600 |
|
149 |
-@item xga |
|
150 |
-1024x768 |
|
151 |
-@item uxga |
|
152 |
-1600x1200 |
|
153 |
-@item qxga |
|
154 |
-2048x1536 |
|
155 |
-@item sxga |
|
156 |
-1280x1024 |
|
157 |
-@item qsxga |
|
158 |
-2560x2048 |
|
159 |
-@item hsxga |
|
160 |
-5120x4096 |
|
161 |
-@item wvga |
|
162 |
-852x480 |
|
163 |
-@item wxga |
|
164 |
-1366x768 |
|
165 |
-@item wsxga |
|
166 |
-1600x1024 |
|
167 |
-@item wuxga |
|
168 |
-1920x1200 |
|
169 |
-@item woxga |
|
170 |
-2560x1600 |
|
171 |
-@item wqsxga |
|
172 |
-3200x2048 |
|
173 |
-@item wquxga |
|
174 |
-3840x2400 |
|
175 |
-@item whsxga |
|
176 |
-6400x4096 |
|
177 |
-@item whuxga |
|
178 |
-7680x4800 |
|
179 |
-@item cga |
|
180 |
-320x200 |
|
181 |
-@item ega |
|
182 |
-640x350 |
|
183 |
-@item hd480 |
|
184 |
-852x480 |
|
185 |
-@item hd720 |
|
186 |
-1280x720 |
|
187 |
-@item hd1080 |
|
188 |
-1920x1080 |
|
189 |
-@item 2k |
|
190 |
-2048x1080 |
|
191 |
-@item 2kflat |
|
192 |
-1998x1080 |
|
193 |
-@item 2kscope |
|
194 |
-2048x858 |
|
195 |
-@item 4k |
|
196 |
-4096x2160 |
|
197 |
-@item 4kflat |
|
198 |
-3996x2160 |
|
199 |
-@item 4kscope |
|
200 |
-4096x1716 |
|
201 |
-@end table |
|
202 |
- |
|
203 |
-@anchor{video rate syntax} |
|
204 |
-@section Video rate |
|
205 |
- |
|
206 |
-Specify the frame rate of a video, expressed as the number of frames |
|
207 |
-generated per second. It has to be a string in the format |
|
208 |
-@var{frame_rate_num}/@var{frame_rate_den}, an integer number, a float |
|
209 |
-number or a valid video frame rate abbreviation. |
|
210 |
- |
|
211 |
-The following abbreviations are recognized: |
|
212 |
-@table @samp |
|
213 |
-@item ntsc |
|
214 |
-30000/1001 |
|
215 |
-@item pal |
|
216 |
-25/1 |
|
217 |
-@item qntsc |
|
218 |
-30000/1001 |
|
219 |
-@item qpal |
|
220 |
-25/1 |
|
221 |
-@item sntsc |
|
222 |
-30000/1001 |
|
223 |
-@item spal |
|
224 |
-25/1 |
|
225 |
-@item film |
|
226 |
-24/1 |
|
227 |
-@item ntsc-film |
|
228 |
-24000/1001 |
|
229 |
-@end table |
|
230 |
- |
|
231 |
-@anchor{ratio syntax} |
|
232 |
-@section Ratio |
|
233 |
- |
|
234 |
-A ratio can be expressed as an expression, or in the form |
|
235 |
-@var{numerator}:@var{denominator}. |
|
236 |
- |
|
237 |
-Note that a ratio with infinite (1/0) or negative value is |
|
238 |
-considered valid, so you should check on the returned value if you |
|
239 |
-want to exclude those values. |
|
240 |
- |
|
241 |
-The undefined value can be expressed using the "0:0" string. |
|
242 |
- |
|
243 |
-@anchor{color syntax} |
|
244 |
-@section Color |
|
245 |
- |
|
246 |
-It can be the name of a color (case insensitive match) or a |
|
247 |
-[0x|#]RRGGBB[AA] sequence, possibly followed by "@@" and a string |
|
248 |
-representing the alpha component. |
|
249 |
- |
|
250 |
-The alpha component may be a string composed by "0x" followed by an |
|
251 |
-hexadecimal number or a decimal number between 0.0 and 1.0, which |
|
252 |
-represents the opacity value (0x00/0.0 means completely transparent, |
|
253 |
-0xff/1.0 completely opaque). |
|
254 |
-If the alpha component is not specified then 0xff is assumed. |
|
255 |
- |
|
256 |
-The string "random" will result in a random color. |
|
257 |
- |
|
258 |
-@c man end SYNTAX |
259 | 1 |
new file mode 100644 |
... | ... |
@@ -0,0 +1,585 @@ |
0 |
+@chapter Syntax |
|
1 |
+@c man begin SYNTAX |
|
2 |
+ |
|
3 |
+This section documents the syntax and formats employed by the FFmpeg |
|
4 |
+libraries and tools. |
|
5 |
+ |
|
6 |
+@anchor{quoting_and_escaping} |
|
7 |
+@section Quoting and escaping |
|
8 |
+ |
|
9 |
+FFmpeg adopts the following quoting and escaping mechanism, unless |
|
10 |
+explicitly specified. The following rules are applied: |
|
11 |
+ |
|
12 |
+@itemize |
|
13 |
+@item |
|
14 |
+@code{'} and @code{\} are special characters (respectively used for |
|
15 |
+quoting and escaping). In addition to them, there might be other |
|
16 |
+special characters depending on the specific syntax where the escaping |
|
17 |
+and quoting are employed. |
|
18 |
+ |
|
19 |
+@item |
|
20 |
+A special character is escaped by prefixing it with a '\'. |
|
21 |
+ |
|
22 |
+@item |
|
23 |
+All characters enclosed between '' are included literally in the |
|
24 |
+parsed string. The quote character @code{'} itself cannot be quoted, |
|
25 |
+so you may need to close the quote and escape it. |
|
26 |
+ |
|
27 |
+@item |
|
28 |
+Leading and trailing whitespaces, unless escaped or quoted, are |
|
29 |
+removed from the parsed string. |
|
30 |
+@end itemize |
|
31 |
+ |
|
32 |
+Note that you may need to add a second level of escaping when using |
|
33 |
+the command line or a script, which depends on the syntax of the |
|
34 |
+adopted shell language. |
|
35 |
+ |
|
36 |
+The function @code{av_get_token} defined in |
|
37 |
+@file{libavutil/avstring.h} can be used to parse a token quoted or |
|
38 |
+escaped according to the rules defined above. |
|
39 |
+ |
|
40 |
+The tool @file{tools/ffescape} in the FFmpeg source tree can be used |
|
41 |
+to automatically quote or escape a string in a script. |
|
42 |
+ |
|
43 |
+@subsection Examples |
|
44 |
+ |
|
45 |
+@itemize |
|
46 |
+@item |
|
47 |
+Escape the string @code{Crime d'Amour} containing the @code{'} special |
|
48 |
+character: |
|
49 |
+@example |
|
50 |
+Crime d\'Amour |
|
51 |
+@end example |
|
52 |
+ |
|
53 |
+@item |
|
54 |
+The string above contains a quote, so the @code{'} needs to be escaped |
|
55 |
+when quoting it: |
|
56 |
+@example |
|
57 |
+'Crime d'\''Amour' |
|
58 |
+@end example |
|
59 |
+ |
|
60 |
+@item |
|
61 |
+Include leading or trailing whitespaces using quoting: |
|
62 |
+@example |
|
63 |
+' this string starts and ends with whitespaces ' |
|
64 |
+@end example |
|
65 |
+ |
|
66 |
+@item |
|
67 |
+Escaping and quoting can be mixed together: |
|
68 |
+@example |
|
69 |
+' The string '\'string\'' is a string ' |
|
70 |
+@end example |
|
71 |
+ |
|
72 |
+@item |
|
73 |
+To include a literal @code{\} you can use either escaping or quoting: |
|
74 |
+@example |
|
75 |
+'c:\foo' can be written as c:\\foo |
|
76 |
+@end example |
|
77 |
+@end itemize |
|
78 |
+ |
|
79 |
+@anchor{date syntax} |
|
80 |
+@section Date |
|
81 |
+ |
|
82 |
+The accepted syntax is: |
|
83 |
+@example |
|
84 |
+[(YYYY-MM-DD|YYYYMMDD)[T|t| ]]((HH:MM:SS[.m...]]])|(HHMMSS[.m...]]]))[Z] |
|
85 |
+now |
|
86 |
+@end example |
|
87 |
+ |
|
88 |
+If the value is "now" it takes the current time. |
|
89 |
+ |
|
90 |
+Time is local time unless Z is appended, in which case it is |
|
91 |
+interpreted as UTC. |
|
92 |
+If the year-month-day part is not specified it takes the current |
|
93 |
+year-month-day. |
|
94 |
+ |
|
95 |
+@anchor{time duration syntax} |
|
96 |
+@section Time duration |
|
97 |
+ |
|
98 |
+The accepted syntax is: |
|
99 |
+@example |
|
100 |
+[-][HH:]MM:SS[.m...] |
|
101 |
+[-]S+[.m...] |
|
102 |
+@end example |
|
103 |
+ |
|
104 |
+@var{HH} expresses the number of hours, @var{MM} the number a of minutes |
|
105 |
+and @var{SS} the number of seconds. |
|
106 |
+ |
|
107 |
+@anchor{video size syntax} |
|
108 |
+@section Video size |
|
109 |
+Specify the size of the sourced video, it may be a string of the form |
|
110 |
+@var{width}x@var{height}, or the name of a size abbreviation. |
|
111 |
+ |
|
112 |
+The following abbreviations are recognized: |
|
113 |
+@table @samp |
|
114 |
+@item ntsc |
|
115 |
+720x480 |
|
116 |
+@item pal |
|
117 |
+720x576 |
|
118 |
+@item qntsc |
|
119 |
+352x240 |
|
120 |
+@item qpal |
|
121 |
+352x288 |
|
122 |
+@item sntsc |
|
123 |
+640x480 |
|
124 |
+@item spal |
|
125 |
+768x576 |
|
126 |
+@item film |
|
127 |
+352x240 |
|
128 |
+@item ntsc-film |
|
129 |
+352x240 |
|
130 |
+@item sqcif |
|
131 |
+128x96 |
|
132 |
+@item qcif |
|
133 |
+176x144 |
|
134 |
+@item cif |
|
135 |
+352x288 |
|
136 |
+@item 4cif |
|
137 |
+704x576 |
|
138 |
+@item 16cif |
|
139 |
+1408x1152 |
|
140 |
+@item qqvga |
|
141 |
+160x120 |
|
142 |
+@item qvga |
|
143 |
+320x240 |
|
144 |
+@item vga |
|
145 |
+640x480 |
|
146 |
+@item svga |
|
147 |
+800x600 |
|
148 |
+@item xga |
|
149 |
+1024x768 |
|
150 |
+@item uxga |
|
151 |
+1600x1200 |
|
152 |
+@item qxga |
|
153 |
+2048x1536 |
|
154 |
+@item sxga |
|
155 |
+1280x1024 |
|
156 |
+@item qsxga |
|
157 |
+2560x2048 |
|
158 |
+@item hsxga |
|
159 |
+5120x4096 |
|
160 |
+@item wvga |
|
161 |
+852x480 |
|
162 |
+@item wxga |
|
163 |
+1366x768 |
|
164 |
+@item wsxga |
|
165 |
+1600x1024 |
|
166 |
+@item wuxga |
|
167 |
+1920x1200 |
|
168 |
+@item woxga |
|
169 |
+2560x1600 |
|
170 |
+@item wqsxga |
|
171 |
+3200x2048 |
|
172 |
+@item wquxga |
|
173 |
+3840x2400 |
|
174 |
+@item whsxga |
|
175 |
+6400x4096 |
|
176 |
+@item whuxga |
|
177 |
+7680x4800 |
|
178 |
+@item cga |
|
179 |
+320x200 |
|
180 |
+@item ega |
|
181 |
+640x350 |
|
182 |
+@item hd480 |
|
183 |
+852x480 |
|
184 |
+@item hd720 |
|
185 |
+1280x720 |
|
186 |
+@item hd1080 |
|
187 |
+1920x1080 |
|
188 |
+@item 2k |
|
189 |
+2048x1080 |
|
190 |
+@item 2kflat |
|
191 |
+1998x1080 |
|
192 |
+@item 2kscope |
|
193 |
+2048x858 |
|
194 |
+@item 4k |
|
195 |
+4096x2160 |
|
196 |
+@item 4kflat |
|
197 |
+3996x2160 |
|
198 |
+@item 4kscope |
|
199 |
+4096x1716 |
|
200 |
+@end table |
|
201 |
+ |
|
202 |
+@anchor{video rate syntax} |
|
203 |
+@section Video rate |
|
204 |
+ |
|
205 |
+Specify the frame rate of a video, expressed as the number of frames |
|
206 |
+generated per second. It has to be a string in the format |
|
207 |
+@var{frame_rate_num}/@var{frame_rate_den}, an integer number, a float |
|
208 |
+number or a valid video frame rate abbreviation. |
|
209 |
+ |
|
210 |
+The following abbreviations are recognized: |
|
211 |
+@table @samp |
|
212 |
+@item ntsc |
|
213 |
+30000/1001 |
|
214 |
+@item pal |
|
215 |
+25/1 |
|
216 |
+@item qntsc |
|
217 |
+30000/1001 |
|
218 |
+@item qpal |
|
219 |
+25/1 |
|
220 |
+@item sntsc |
|
221 |
+30000/1001 |
|
222 |
+@item spal |
|
223 |
+25/1 |
|
224 |
+@item film |
|
225 |
+24/1 |
|
226 |
+@item ntsc-film |
|
227 |
+24000/1001 |
|
228 |
+@end table |
|
229 |
+ |
|
230 |
+@anchor{ratio syntax} |
|
231 |
+@section Ratio |
|
232 |
+ |
|
233 |
+A ratio can be expressed as an expression, or in the form |
|
234 |
+@var{numerator}:@var{denominator}. |
|
235 |
+ |
|
236 |
+Note that a ratio with infinite (1/0) or negative value is |
|
237 |
+considered valid, so you should check on the returned value if you |
|
238 |
+want to exclude those values. |
|
239 |
+ |
|
240 |
+The undefined value can be expressed using the "0:0" string. |
|
241 |
+ |
|
242 |
+@anchor{color syntax} |
|
243 |
+@section Color |
|
244 |
+ |
|
245 |
+It can be the name of a color (case insensitive match) or a |
|
246 |
+[0x|#]RRGGBB[AA] sequence, possibly followed by "@@" and a string |
|
247 |
+representing the alpha component. |
|
248 |
+ |
|
249 |
+The alpha component may be a string composed by "0x" followed by an |
|
250 |
+hexadecimal number or a decimal number between 0.0 and 1.0, which |
|
251 |
+represents the opacity value (0x00/0.0 means completely transparent, |
|
252 |
+0xff/1.0 completely opaque). |
|
253 |
+If the alpha component is not specified then 0xff is assumed. |
|
254 |
+ |
|
255 |
+The string "random" will result in a random color. |
|
256 |
+ |
|
257 |
+@c man end SYNTAX |
|
258 |
+ |
|
259 |
+@chapter Expression Evaluation |
|
260 |
+@c man begin EXPRESSION EVALUATION |
|
261 |
+ |
|
262 |
+When evaluating an arithmetic expression, FFmpeg uses an internal |
|
263 |
+formula evaluator, implemented through the @file{libavutil/eval.h} |
|
264 |
+interface. |
|
265 |
+ |
|
266 |
+An expression may contain unary, binary operators, constants, and |
|
267 |
+functions. |
|
268 |
+ |
|
269 |
+Two expressions @var{expr1} and @var{expr2} can be combined to form |
|
270 |
+another expression "@var{expr1};@var{expr2}". |
|
271 |
+@var{expr1} and @var{expr2} are evaluated in turn, and the new |
|
272 |
+expression evaluates to the value of @var{expr2}. |
|
273 |
+ |
|
274 |
+The following binary operators are available: @code{+}, @code{-}, |
|
275 |
+@code{*}, @code{/}, @code{^}. |
|
276 |
+ |
|
277 |
+The following unary operators are available: @code{+}, @code{-}. |
|
278 |
+ |
|
279 |
+The following functions are available: |
|
280 |
+@table @option |
|
281 |
+@item abs(x) |
|
282 |
+Compute absolute value of @var{x}. |
|
283 |
+ |
|
284 |
+@item acos(x) |
|
285 |
+Compute arccosine of @var{x}. |
|
286 |
+ |
|
287 |
+@item asin(x) |
|
288 |
+Compute arcsine of @var{x}. |
|
289 |
+ |
|
290 |
+@item atan(x) |
|
291 |
+Compute arctangent of @var{x}. |
|
292 |
+ |
|
293 |
+@item between(x, min, max) |
|
294 |
+Return 1 if @var{x} is greater than or equal to @var{min} and lesser than or |
|
295 |
+equal to @var{max}, 0 otherwise. |
|
296 |
+ |
|
297 |
+@item bitand(x, y) |
|
298 |
+@item bitor(x, y) |
|
299 |
+Compute bitwise and/or operation on @var{x} and @var{y}. |
|
300 |
+ |
|
301 |
+The results of the evaluation of @var{x} and @var{y} are converted to |
|
302 |
+integers before executing the bitwise operation. |
|
303 |
+ |
|
304 |
+Note that both the conversion to integer and the conversion back to |
|
305 |
+floating point can lose precision. Beware of unexpected results for |
|
306 |
+large numbers (usually 2^53 and larger). |
|
307 |
+ |
|
308 |
+@item ceil(expr) |
|
309 |
+Round the value of expression @var{expr} upwards to the nearest |
|
310 |
+integer. For example, "ceil(1.5)" is "2.0". |
|
311 |
+ |
|
312 |
+@item cos(x) |
|
313 |
+Compute cosine of @var{x}. |
|
314 |
+ |
|
315 |
+@item cosh(x) |
|
316 |
+Compute hyperbolic cosine of @var{x}. |
|
317 |
+ |
|
318 |
+@item eq(x, y) |
|
319 |
+Return 1 if @var{x} and @var{y} are equivalent, 0 otherwise. |
|
320 |
+ |
|
321 |
+@item exp(x) |
|
322 |
+Compute exponential of @var{x} (with base @code{e}, the Euler's number). |
|
323 |
+ |
|
324 |
+@item floor(expr) |
|
325 |
+Round the value of expression @var{expr} downwards to the nearest |
|
326 |
+integer. For example, "floor(-1.5)" is "-2.0". |
|
327 |
+ |
|
328 |
+@item gauss(x) |
|
329 |
+Compute Gauss function of @var{x}, corresponding to |
|
330 |
+@code{exp(-x*x/2) / sqrt(2*PI)}. |
|
331 |
+ |
|
332 |
+@item gcd(x, y) |
|
333 |
+Return the greatest common divisor of @var{x} and @var{y}. If both @var{x} and |
|
334 |
+@var{y} are 0 or either or both are less than zero then behavior is undefined. |
|
335 |
+ |
|
336 |
+@item gt(x, y) |
|
337 |
+Return 1 if @var{x} is greater than @var{y}, 0 otherwise. |
|
338 |
+ |
|
339 |
+@item gte(x, y) |
|
340 |
+Return 1 if @var{x} is greater than or equal to @var{y}, 0 otherwise. |
|
341 |
+ |
|
342 |
+@item hypot(x, y) |
|
343 |
+This function is similar to the C function with the same name; it returns |
|
344 |
+"sqrt(@var{x}*@var{x} + @var{y}*@var{y})", the length of the hypotenuse of a |
|
345 |
+right triangle with sides of length @var{x} and @var{y}, or the distance of the |
|
346 |
+point (@var{x}, @var{y}) from the origin. |
|
347 |
+ |
|
348 |
+@item if(x, y) |
|
349 |
+Evaluate @var{x}, and if the result is non-zero return the result of |
|
350 |
+the evaluation of @var{y}, return 0 otherwise. |
|
351 |
+ |
|
352 |
+@item if(x, y, z) |
|
353 |
+Evaluate @var{x}, and if the result is non-zero return the evaluation |
|
354 |
+result of @var{y}, otherwise the evaluation result of @var{z}. |
|
355 |
+ |
|
356 |
+@item ifnot(x, y) |
|
357 |
+Evaluate @var{x}, and if the result is zero return the result of the |
|
358 |
+evaluation of @var{y}, return 0 otherwise. |
|
359 |
+ |
|
360 |
+@item ifnot(x, y, z) |
|
361 |
+Evaluate @var{x}, and if the result is zero return the evaluation |
|
362 |
+result of @var{y}, otherwise the evaluation result of @var{z}. |
|
363 |
+ |
|
364 |
+@item isinf(x) |
|
365 |
+Return 1.0 if @var{x} is +/-INFINITY, 0.0 otherwise. |
|
366 |
+ |
|
367 |
+@item isnan(x) |
|
368 |
+Return 1.0 if @var{x} is NAN, 0.0 otherwise. |
|
369 |
+ |
|
370 |
+@item ld(var) |
|
371 |
+Allow to load the value of the internal variable with number |
|
372 |
+@var{var}, which was previously stored with st(@var{var}, @var{expr}). |
|
373 |
+The function returns the loaded value. |
|
374 |
+ |
|
375 |
+@item log(x) |
|
376 |
+Compute natural logarithm of @var{x}. |
|
377 |
+ |
|
378 |
+@item lt(x, y) |
|
379 |
+Return 1 if @var{x} is lesser than @var{y}, 0 otherwise. |
|
380 |
+ |
|
381 |
+@item lte(x, y) |
|
382 |
+Return 1 if @var{x} is lesser than or equal to @var{y}, 0 otherwise. |
|
383 |
+ |
|
384 |
+@item max(x, y) |
|
385 |
+Return the maximum between @var{x} and @var{y}. |
|
386 |
+ |
|
387 |
+@item min(x, y) |
|
388 |
+Return the maximum between @var{x} and @var{y}. |
|
389 |
+ |
|
390 |
+@item mod(x, y) |
|
391 |
+Compute the remainder of division of @var{x} by @var{y}. |
|
392 |
+ |
|
393 |
+@item not(expr) |
|
394 |
+Return 1.0 if @var{expr} is zero, 0.0 otherwise. |
|
395 |
+ |
|
396 |
+@item pow(x, y) |
|
397 |
+Compute the power of @var{x} elevated @var{y}, it is equivalent to |
|
398 |
+"(@var{x})^(@var{y})". |
|
399 |
+ |
|
400 |
+@item print(t) |
|
401 |
+@item print(t, l) |
|
402 |
+Print the value of expression @var{t} with loglevel @var{l}. If |
|
403 |
+@var{l} is not specified then a default log level is used. |
|
404 |
+Returns the value of the expression printed. |
|
405 |
+ |
|
406 |
+Prints t with loglevel l |
|
407 |
+ |
|
408 |
+@item random(x) |
|
409 |
+Return a pseudo random value between 0.0 and 1.0. @var{x} is the index of the |
|
410 |
+internal variable which will be used to save the seed/state. |
|
411 |
+ |
|
412 |
+@item root(expr, max) |
|
413 |
+Find an input value for which the function represented by @var{expr} |
|
414 |
+with argument @var{ld(0)} is 0 in the interval 0..@var{max}. |
|
415 |
+ |
|
416 |
+The expression in @var{expr} must denote a continuous function or the |
|
417 |
+result is undefined. |
|
418 |
+ |
|
419 |
+@var{ld(0)} is used to represent the function input value, which means |
|
420 |
+that the given expression will be evaluated multiple times with |
|
421 |
+various input values that the expression can access through |
|
422 |
+@code{ld(0)}. When the expression evaluates to 0 then the |
|
423 |
+corresponding input value will be returned. |
|
424 |
+ |
|
425 |
+@item sin(x) |
|
426 |
+Compute sine of @var{x}. |
|
427 |
+ |
|
428 |
+@item sinh(x) |
|
429 |
+Compute hyperbolic sine of @var{x}. |
|
430 |
+ |
|
431 |
+@item sqrt(expr) |
|
432 |
+Compute the square root of @var{expr}. This is equivalent to |
|
433 |
+"(@var{expr})^.5". |
|
434 |
+ |
|
435 |
+@item squish(x) |
|
436 |
+Compute expression @code{1/(1 + exp(4*x))}. |
|
437 |
+ |
|
438 |
+@item st(var, expr) |
|
439 |
+Allow to store the value of the expression @var{expr} in an internal |
|
440 |
+variable. @var{var} specifies the number of the variable where to |
|
441 |
+store the value, and it is a value ranging from 0 to 9. The function |
|
442 |
+returns the value stored in the internal variable. |
|
443 |
+Note, Variables are currently not shared between expressions. |
|
444 |
+ |
|
445 |
+@item tan(x) |
|
446 |
+Compute tangent of @var{x}. |
|
447 |
+ |
|
448 |
+@item tanh(x) |
|
449 |
+Compute hyperbolic tangent of @var{x}. |
|
450 |
+ |
|
451 |
+@item taylor(expr, x) |
|
452 |
+@item taylor(expr, x, id) |
|
453 |
+Evaluate a Taylor series at @var{x}, given an expression representing |
|
454 |
+the @code{ld(id)}-th derivative of a function at 0. |
|
455 |
+ |
|
456 |
+When the series does not converge the result is undefined. |
|
457 |
+ |
|
458 |
+@var{ld(id)} is used to represent the derivative order in @var{expr}, |
|
459 |
+which means that the given expression will be evaluated multiple times |
|
460 |
+with various input values that the expression can access through |
|
461 |
+@code{ld(id)}. If @var{id} is not specified then 0 is assumed. |
|
462 |
+ |
|
463 |
+Note, when you have the derivatives at y instead of 0, |
|
464 |
+@code{taylor(expr, x-y)} can be used. |
|
465 |
+ |
|
466 |
+@item time(0) |
|
467 |
+Return the current (wallclock) time in seconds. |
|
468 |
+ |
|
469 |
+@item trunc(expr) |
|
470 |
+Round the value of expression @var{expr} towards zero to the nearest |
|
471 |
+integer. For example, "trunc(-1.5)" is "-1.0". |
|
472 |
+ |
|
473 |
+@item while(cond, expr) |
|
474 |
+Evaluate expression @var{expr} while the expression @var{cond} is |
|
475 |
+non-zero, and returns the value of the last @var{expr} evaluation, or |
|
476 |
+NAN if @var{cond} was always false. |
|
477 |
+@end table |
|
478 |
+ |
|
479 |
+The following constants are available: |
|
480 |
+@table @option |
|
481 |
+@item PI |
|
482 |
+area of the unit disc, approximately 3.14 |
|
483 |
+@item E |
|
484 |
+exp(1) (Euler's number), approximately 2.718 |
|
485 |
+@item PHI |
|
486 |
+golden ratio (1+sqrt(5))/2, approximately 1.618 |
|
487 |
+@end table |
|
488 |
+ |
|
489 |
+Assuming that an expression is considered "true" if it has a non-zero |
|
490 |
+value, note that: |
|
491 |
+ |
|
492 |
+@code{*} works like AND |
|
493 |
+ |
|
494 |
+@code{+} works like OR |
|
495 |
+ |
|
496 |
+For example the construct: |
|
497 |
+@example |
|
498 |
+if (A AND B) then C |
|
499 |
+@end example |
|
500 |
+is equivalent to: |
|
501 |
+@example |
|
502 |
+if(A*B, C) |
|
503 |
+@end example |
|
504 |
+ |
|
505 |
+In your C code, you can extend the list of unary and binary functions, |
|
506 |
+and define recognized constants, so that they are available for your |
|
507 |
+expressions. |
|
508 |
+ |
|
509 |
+The evaluator also recognizes the International System unit prefixes. |
|
510 |
+If 'i' is appended after the prefix, binary prefixes are used, which |
|
511 |
+are based on powers of 1024 instead of powers of 1000. |
|
512 |
+The 'B' postfix multiplies the value by 8, and can be appended after a |
|
513 |
+unit prefix or used alone. This allows using for example 'KB', 'MiB', |
|
514 |
+'G' and 'B' as number postfix. |
|
515 |
+ |
|
516 |
+The list of available International System prefixes follows, with |
|
517 |
+indication of the corresponding powers of 10 and of 2. |
|
518 |
+@table @option |
|
519 |
+@item y |
|
520 |
+10^-24 / 2^-80 |
|
521 |
+@item z |
|
522 |
+10^-21 / 2^-70 |
|
523 |
+@item a |
|
524 |
+10^-18 / 2^-60 |
|
525 |
+@item f |
|
526 |
+10^-15 / 2^-50 |
|
527 |
+@item p |
|
528 |
+10^-12 / 2^-40 |
|
529 |
+@item n |
|
530 |
+10^-9 / 2^-30 |
|
531 |
+@item u |
|
532 |
+10^-6 / 2^-20 |
|
533 |
+@item m |
|
534 |
+10^-3 / 2^-10 |
|
535 |
+@item c |
|
536 |
+10^-2 |
|
537 |
+@item d |
|
538 |
+10^-1 |
|
539 |
+@item h |
|
540 |
+10^2 |
|
541 |
+@item k |
|
542 |
+10^3 / 2^10 |
|
543 |
+@item K |
|
544 |
+10^3 / 2^10 |
|
545 |
+@item M |
|
546 |
+10^6 / 2^20 |
|
547 |
+@item G |
|
548 |
+10^9 / 2^30 |
|
549 |
+@item T |
|
550 |
+10^12 / 2^40 |
|
551 |
+@item P |
|
552 |
+10^15 / 2^40 |
|
553 |
+@item E |
|
554 |
+10^18 / 2^50 |
|
555 |
+@item Z |
|
556 |
+10^21 / 2^60 |
|
557 |
+@item Y |
|
558 |
+10^24 / 2^70 |
|
559 |
+@end table |
|
560 |
+ |
|
561 |
+@c man end |
|
562 |
+ |
|
563 |
+@chapter OpenCL Options |
|
564 |
+@c man begin OPENCL OPTIONS |
|
565 |
+ |
|
566 |
+When FFmpeg is configured with @code{--enable-opencl}, it is possible |
|
567 |
+to set the options to set in the global OpenCL context. The list of |
|
568 |
+supported options follows: |
|
569 |
+ |
|
570 |
+@table @option |
|
571 |
+@item build_options |
|
572 |
+Set build options which used to compiled kernels, see reference "OpenCL Specification Version: 1.2 chapter 5.6.4" |
|
573 |
+ |
|
574 |
+@item platform_idx |
|
575 |
+Select platform to run OpenCL code, the platform_idx is the index of platform |
|
576 |
+in the device list which can be obtained with av_opencl_get_device_list(). |
|
577 |
+ |
|
578 |
+@item device_idx |
|
579 |
+Select device to run OpenCL code, the device_idx is the index of device in |
|
580 |
+the device list which can be obtained with av_opencl_get_device_list(). |
|
581 |
+ |
|
582 |
+@end table |
|
583 |
+ |
|
584 |
+@c man end OPENCL OPTIONS |