--- libavfilter.texi.nodt 2010-05-03 00:39:50.516428954 -0700 +++ libavfilter.texi 2010-05-03 00:28:42.221181682 -0700 @@ -148,6 +148,91 @@ Draw a box with @var{x}:@var{y}:@var{width}:@var{height}:@var{color} dimensions in a chosen color. +@section drawtext + +Draws text string or text from specified file on top of video. +The filter also recognizes strftime() sequences in the provided text and +expand them accordingly. Check the documentation of strftime(). + +The filter accepts parameters as a list of $var{key}=var{value} pairs, +separated by ":" + +The description of the accepted parameters follows. + +@table @option +@item fontfile + +Specifies the font file to be used for drawing text. Path must be included. +This parameter is mandatory. + +@item text + +Specifies the text string to be drawn. +This parameter is mandatory if no file is specified. + +@item textfile + +Specifies a text file containing text to be drawn. Max of 1024 characters are +read from the file. + +This parameter is mandatory if no text string is specified. + +If both text and textfile are specified, an error is thrown. + +@item x, y + +Specify the offsets where text will be drawn within the video +frame. Relative to the top/left border of the output image. + +The default value of $var{x} and $var{y} is 0. + +@item fontsize + +Specifies the font size to be used for drawing text. + +The default value of $var{size} is 16. + +@item fgcolor + +Specifies the foreground color to be used for drawing text. +Specify either as a string (e.g. red) or as 0xRRGGBB[AA] (e.g. 0xff000033) + +The default value of $var{fgcolor} is black. + +@item bgcolor + +Specifies the background color to be used for drawing box around text +or drawing text outline based on option selected. +Specify either as a string (e.g. yellow) or as 0xRRGGBB[AA] (e.g. 0xff00ff) + +The default value of $var{bgcolor} is white. + +@item box + +Specifies whether to draw a box around text using background color. +Value should be either 1(enable) or 0(disable). + +The default value of $var{box} is 0. + +@item outline + +Specifies whether to draw an outline around text using background color. +Value should be either 1(enable) or 0(disable). + +The default value of $var{outline} is 0. + +@end table +@example +drawtext="fontfile=FreeSerif.ttf: text=TestText: x=100: y=50: fontsize=24: + fgcolor=0xff00ff33: bgcolor=Red: b=1" +@end example + +Draw 'TestText' with font FreeSerif of size 24 at (100,50), text color is yellow, +background color is red, draw a box around text. + +Note that the double quotes are not necessary if spaces are not used within +the parameter list. + @section fifo @example