DEV Community

Milan Tejani
Milan Tejani

Posted on

How to add day suffix[st,nd,rd,th] in timestamp's date in ffmpeg command?

I am using this command to add time stamp in video:

ffmpeg -y -i input.mp4 -vf "drawtext=fontfile=roboto.ttf:fontsize=36:fontcolor=yellow:text='%{pts\:gmtime\:1575526882\:%d %b, %Y %I\\\:%M %p}'" -preset ultrafast -f mp4 output.mp4

this command generate date & time: 05 Dec, 2019 06:21 AM

but i want to add day suffix after day in date like this…

Top comments (0)

AWS Security LIVE!

Join us for AWS Security LIVE!

Discover the future of cloud security. Tune in live for trends, tips, and solutions from AWS and AWS Partners.

Learn More

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay