[FFmpeg-user] fixing videos that don't start with keyframes

Matthew Morgan lytithwyn at gmail.com
Thu Nov 10 18:15:09 CET 2011

On Thu 10 Nov 2011 11:40:03 AM EST, Carl Eugen Hoyos wrote:
> Matthew Morgan<lytithwyn<at>  gmail.com>  writes:
>> I mainly just need to know if it is possible using ffmpeg (and if so,
>> how) to trim everything off the beginning of a video file up to the
>> first keyframe.
> This is nowadays FFmpeg's default.
> The reason this was changed where many reports like yours, I am not sure if the
> discussion is completely over, but for the moment FFmpeg tries to skip the
> initial non-key frames.
> There probably are videos for which this does not work, but testing (and
> reporting) about this is very welcome! Please consider opening a report on
> http://avcodec.org/trac/ffmpeg if your problem is reproducible with current git
> head.
> Carl Eugen
So ffmpeg skips them by default?  That's actually really great news for 
me.  Does this behavior happen with '-acodec copy -vcodec' copy as well?

My idea is to just run the file through an ffmpeg conversion and let it 
trim the initial non-key frames off.  I'll going ahead and build from 
git-head and file a report if it doesn't work.

More information about the ffmpeg-user mailing list