[FFmpeg-devel] [PATCH] doc/filters: fix localtime drawtext example.

Simon Thelen ffmpeg-dev at c-14.de
Wed Sep 10 20:18:42 CEST 2014


On 10/09/14 at 10:24, Nicolas George wrote:
> Le quartidi 24 fructidor, an CCXXII, Simon Thelen a écrit :
> > The colon after the localtime function call needs an additional layer of
> > escaping or else everything until the next colon is treated as a
> > fontfile.
> 
> The change looks ok, thanks. The commit message seems strange, though: I
> would have expected that the text starting at "%a" would be interpreted as
> options, not fontfile.
I'm not sure why it's being detected as a fontfile instead of as an
option either, but here are the error messages if you're interested:
[..]
[Parsed_drawtext_0 @ 0x2c02800] Could not load font "%a %b %d %Y}": cannot open resource
[Parsed_drawtext_0 @ 0x2c02800] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[..]
[Parsed_drawtext_0 @ 0x2c02800] Unterminated %{} near '{localtime'}'
[..]

And that was with this command line:
ffmpeg -i input.mp4 -vf drawtext='fontfile=/usr/share/fonts/dejavu/DejaVuSans.ttf:text=%{localtime:%a %b %d %Y}' out.mkv

-- 
Simon Thelen


More information about the ffmpeg-devel mailing list