[FFmpeg-user] How to get video duration in a script using ffmpeg?

Bo Berglund bo.berglund at gmail.com
Wed Jan 19 13:59:45 EET 2022


On Wed, 19 Jan 2022 17:10:26 +0530, Gyan Doshi <ffmpeg at gyani.pro> wrote:

>> What do I need to just get that output I want?
>
>The closest you can get is
>
>      ffprobe -v 0 -of compact=p=0:nk=1 -sexagesimal -show_entries 
>format=duration INPUT

Thanks, this returns the following output:
0:43:26.384000

Can the duration be limited to only seconds resolution (no decimals)?


-- 
Bo Berglund
Developer in Sweden



More information about the ffmpeg-user mailing list