1

I'm rendering animations from a collection of png's. I'd like to add the name of the file as a text overlay. I've got drawtext working with static text, but haven't been able to find a way to access the file name being rendered.

Current command:

ffmpeg -framerate 2 -i layer-%d.png -i logo.png -filter_complex "[0:v]fps=30[img];[1:v][img]scale2ref=163:163[a][b];[b][a]overlay=(81):(main_h-163-81)[vid];[vid]drawtext=text='TEXT':x=100:y=100:fontfile=font/SourceSansPro-Regular.otf:fontsize=30:fontcolor=white" -preset ultrafast -movflags +faststart -vcodec libx264 -crf 23 -pix_fmt yuv420p output.mp4

Is there something I can put in the 'TEXT' area to get the file name?

Geuis
  • 41,122
  • 56
  • 157
  • 219

0 Answers0