[FFmpeg-devel] [PATCH] doc/filters: rework and itemize examples for the overlay filter

Clément Bœsch ubitux at gmail.com
Sat Dec 15 20:09:14 CET 2012


On Sat, Dec 15, 2012 at 03:06:29PM +0100, Stefano Sabatini wrote:
> ---
>  doc/filters.texi |   55 ++++++++++++++++++++++++++++++++++++++----------------
>  1 file changed, 39 insertions(+), 16 deletions(-)
> 
> diff --git a/doc/filters.texi b/doc/filters.texi
> index 5b69559..fecb629 100644
> --- a/doc/filters.texi
> +++ b/doc/filters.texi
> @@ -3132,34 +3132,57 @@ to pass the two inputs through a @var{setpts=PTS-STARTPTS} filter to
>  have them begin in the same zero timestamp, as it does the example for
>  the @var{movie} filter.
>  
> -Follow some examples:
> +You can chain together more overlays but the efficiency of such
> +approach is yet to be tested.
> +

Why introduce this line as this, to change it right away in the next
patch?

> + at subsection Examples
> +
> + at itemize
> + at item
> +Draw the overlay at 10 pixels from the bottom right corner of the main
> +video:
>  @example
> -# draw the overlay at 10 pixels from the bottom right
> -# corner of the main video.
>  overlay=main_w-overlay_w-10:main_h-overlay_h-10
> + at end example
> +
> +Using named options the example above becomes:
> + at example
> +overlay=x=main_w-overlay_w-10:y=main_h-overlay_h-10
> + at end example
>  
> -# insert a transparent PNG logo in the bottom left corner of the input
> + at item
> +Insert a transparent PNG logo in the bottom left corner of the input,
> +using the @command{ffmpeg} tool with the @code{-filter_complex} option:
> + at example
>  ffmpeg -i input -i logo -filter_complex 'overlay=10:main_h-overlay_h-10' output
> + at end example
>  
> -# insert 2 different transparent PNG logos (second logo on bottom
> -# right corner):
> -ffmpeg -i input -i logo1 -i logo2 -filter_complex
> -'overlay=10:H-h-10,overlay=W-w-10:H-h-10' output
> + at item
> +Insert 2 different transparent PNG logos (second logo on bottom
> +right corner) using the @command{ffmpeg} tool:
> + at example
> +ffmpeg -i input -i logo1 -i logo2 -filter_complex 'overlay=10:H-h-10,overlay=W-w-10:H-h-10' output
> + at end example
>  
> -# add a transparent color layer on top of the main video,
> -# WxH specifies the size of the main input to the overlay filter
> + at item
> +Add a transparent color layer on top of the main video, WxH specifies
> +the size of the main input to the overlay filter:
> + at example
>  color=red@@.3:WxH [over]; [in][over] overlay [out]
> + at end example
>  
> -# play an original video and a filtered version (here with the deshake filter)
> -# side by side
> + at item
> +Play an original video and a filtered version (here with the deshake
> +filter) side by side using the @command{ffplay} tool:
> + at example
>  ffplay input.avi -vf 'split[a][b]; [a]pad=iw*2:ih[src]; [b]deshake[filt]; [src][filt]overlay=w'
> + at end example
>  
> -# the previous example is the same as:
> +The above command is the same as:
> + at example
>  ffplay input.avi -vf 'split[b], pad=iw*2[src], [b]deshake, [src]overlay=w'
>  @end example
> -
> -You can chain together more overlays but the efficiency of such
> -approach is yet to be tested.
> + at end itemize
>  
>  @section pad
>  

LGTM

-- 
Clément B.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 490 bytes
Desc: not available
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20121215/eac73e6c/attachment.asc>


More information about the ffmpeg-devel mailing list