[FFmpeg-user] drawtext parameter keys "n" and "t" not working? How to overlay text at specified seconds/frame into the video?

Fing Cmo fingcmo at gmail.com
Thu Apr 12 09:18:25 CEST 2012


All,

I am trying to use drawtext filter to overlay text 10 seconds into the
video.
I couldn't find any solution using drawtext filter.
Does anyone know how one would:

1-- Overlay text 10 seconds into the video.
2-- Overlay text over video at 1 second intervals into the video.
      The text last for 1 second or specified duration.

I tried using drawtext's "n" and "t" parameter keys and the example below
returns:

[drawtext @ 0xa64ca40] Key 'n' not found.
[drawtext @ 0xa64e6c0] Error parsing options string:
'fontfile=/usr/share/fonts/truetype/ttf-dejavu/DejaVuSerif.ttf:text=Text at
5 Looks good:fontsize=20:fontcolor=red:x=100:y=100:n=688'
Error initializing filter 'drawtext' with args
'fontfile=/usr/share/fonts/truetype/ttf-dejavu/DejaVuSerif.ttf:text=Text at
5 Looks good:fontsize=20:fontcolor=red:x=100:y=100:n=688'

ffmpeg -vsync 0 -t 10 -i in)video.mp4 -vf
drawtext="fontfile=/usr/share/fonts/truetype/ttf-dejavu/DejaVuSerif.ttf:text='Text
at 5 Looks good':fontsize=20:fontcolor=red:x=100:y=100:*n=688*" out.mp4

If anyone knows if these parameters work, please give a usage example.

Otherwise, do you have any advice on how to achieve objective "1--" and
"2--" above?

Thanks,
Ad.
------------------------------------


More information about the ffmpeg-user mailing list