[FFmpeg-devel] [PATCH] libavfilter-soc: Make the overlay filter able to align to opposite edges

Stefano Sabatini stefano.sabatini-lala
Thu May 14 20:21:50 CEST 2009


On date Thursday 2009-05-14 01:18:41 +0300, Martin Storsj? encoded:
> On Wed, 13 May 2009, Stefano Sabatini wrote:
> 
> > Please also add documentation to vfilters.texi.
> 
> Added.
> 
> > > Fine by me, but maybe Stefano might want to comment, since he's been  
> > > working with passing parameters to filters.
> > 
> > Looks fine to me, but I'm not particularly fond of positional
> > parameter, if the av_set_options_string() will be applied we could use
> > the x=...:y=... syntax, but we can eventually add it later.
> 
> Yeah, that's probably a good second step. This step doesn't change the
> existing parameter format, it just extends it :-) That'd be a good thing 
> to consider when av_set_options_string() is fully merged, though.
> 
> > I'm not sure if it makes sense at this point to also support some
> > alignment flags:
> > align=top+right
> > 
> > since the new syntax is expressive enough, maybe it would be anyway a
> > nice UI bonus (with a slightly price in term of complexity).
> 
> Perhaps it'd be a bonus, but I don't feel it's necessary at the moment, 
> since this is so much more expressive (in addition to aligning to the 
> other edges, it also makes centering easy, etc.). At least not necessary 
> for this first patch. :-)
> 
> // Martin
> diff --git a/doc/vfilters.texi b/doc/vfilters.texi
> index b81df79..dbe89c6 100644
> --- a/doc/vfilters.texi
> +++ b/doc/vfilters.texi
> @@ -145,6 +145,19 @@ 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.
>  
> +Parameters to the filter are separated by a colon. The first parameter
> +is the x coordinate of the overlay, the second parameter is the y
> +coordinate. The parameters need not be constant expressions, but may
> +be expressions containing the names @var{mainW}, @var{mainH},
> + at var{overlayW} and @var{overlayH}, for the size of the first and second
> +input video, respectively. For example,
> + at example
> +overlay=mainW-overlayW-10:mainH-overlayH-10
> + at end example
> +can be used to
> +draw the overlay at 10 pixels from the bottom right corner of the main
> +video.

Weird indentation.

[...]

And I'm fine with applying to the soc repo this patch.

Regards.
-- 
FFmpeg = Funny & Frenzy Mournful Pure Elegant Gospel



More information about the ffmpeg-devel mailing list