summaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authorStefano Sabatini <stefasab@gmail.com>2012-10-29 11:48:53 +0100
committerStefano Sabatini <stefasab@gmail.com>2012-10-29 17:44:53 +0100
commit19add3224f1ea6ea8e78a9bf79340edd3e924e04 (patch)
tree3c0b59ea857b7370fd89ac61ee192cdd57561419 /doc
parentd4604d10fe728f3954b294c0a4373b6df65f4ec9 (diff)
downloadffmpeg-streaming-19add3224f1ea6ea8e78a9bf79340edd3e924e04.zip
ffmpeg-streaming-19add3224f1ea6ea8e78a9bf79340edd3e924e04.tar.gz
lavfi/scale: implement clever/insane parsing heuristic, and add a size option
If the first argument can be read as a video size, set that output size in the scale. This allows to specify in a filtergraph scale=qcif or scale=320x240. This is not completely safe, for example in case of a typo in the video size string the first argument will be read as the input width expression, giving rise to a confusing comment.
Diffstat (limited to 'doc')
-rw-r--r--doc/filters.texi27
1 files changed, 24 insertions, 3 deletions
diff --git a/doc/filters.texi b/doc/filters.texi
index 7807b45..b9ad187 100644
--- a/doc/filters.texi
+++ b/doc/filters.texi
@@ -3017,7 +3017,9 @@ of the input, by changing the output sample aspect ratio.
This filter accepts a list of named options in the form of
@var{key}=@var{value} pairs separated by ":". If the key for the first
two options is not specified, the assumed keys for the first two
-values are @code{w} and @code{h}.
+values are @code{w} and @code{h}. If the first option has no key and
+can be interpreted like a video size specification, it will be used
+to set the video size.
A description of the accepted options follows.
@@ -3050,6 +3052,10 @@ Default value is @code{0}.
@item flags
Set libswscale scaling flags. If not explictly specified the filter
applies a bilinear scaling algorithm.
+
+@item size, s
+Set the video size, the value must be a valid abbreviation or in the
+form @var{width}x@var{height}.
@end table
The values of the @var{w} and @var{h} options are expressions
@@ -3102,12 +3108,27 @@ Scale the input video to a size of 200x100:
scale=200:100
@end example
-@item
-The above example is the same as:
+This is equivalent to:
@example
scale=w=200:h=100
@end example
+or:
+@example
+scale=200x100
+@end example
+
+@item
+Specify a size abbreviation for the output size:
+@example
+scale=qcif
+@end example
+
+which can also be written as:
+@example
+scale=size=qcif
+@end example
+
@item
Scale the input to 2x:
@example
OpenPOWER on IntegriCloud