[FFmpeg-user] 'Duration: N/A' for some videos ?
krueger at lesspain.de
Fri Aug 30 13:09:54 CEST 2013
On Fri, Aug 30, 2013 at 12:27 PM, Carl Eugen Hoyos <cehoyos at ag.or.at> wrote:
> Shyam Sundar <sw.craftsman <at> gmail.com> writes:
>> Bit-rate is understood ... I want to find out the
>> 'duration' using FFProbe like how it used to give before.
> It was wrong before.
>> The newer version also gives only the max
>> bit-rate but not the duration.
> Because the duration is unknown:
> Known are filesize and maximum duration, you have to
> decode to know the actual duration.
parse the packets/headers, actually. It is possible to retrieve an
accurate duration with quite a bit of I/O but rather little CPU time
(i.e. in most practical cases a lot faster that by really decoding the
file). The thing is, I don't believe that option (parse the packets
and add their duration) is currently implemented in any of the
fftools. However, I have seen posts by people who have done that via
scripts that extract the packet durations using ffprobe and then add
those. I assume that for some formats tools like mediainfo or exiftool
take that approach but I have not verified that by looking at their
@Carl: Of course you may interprete parsing headers as a subset of
decoding, I just wanted to make sure he did not get the impression he
had to decode (as in decoding image data) the whole video to get a
More information about the ffmpeg-user