[Libav-user] Why does av_seek_frame() not seek to a keyframe?

Roger Pack rogerdpack2 at gmail.com
Thu Aug 2 20:10:38 CEST 2012

> Could you provide a sample that does not seek to a keyframe with
> ffmpeg -ss x -i input out.png
> (I tested this yesterday on random mpeg2video samples and afaict,
> it did work.)

With me, I get this:

with this file: http://rogerdpack.t28.net/incoming/sintel.mpg

$ ffmpeg -i sintel.mpg -vcodec copy -acodec copy -ss 90.0 starting_at_90.mpg

then try and use it again:

$ ffmpeg -i starting_at_90.mpg  -vframes 1 -f image2 -an snap.jpg

I get this warning message:
[mpeg2video @ 01f09860] warning: first frame is no keyframe

Anybody know if this is expected? I almost don't think it is...

More information about the Libav-user mailing list