Skip to content

Seeking in H.264/AVC streams doesn't seek to I-frames

There seems to be some kind of issue with seeking in H.264/AVC streams. Tested with both the MP4 and MKV containers and with a multitude of files and it's rather reliably reproducible everywhere.

Steps to reproduce are simply:

  1. load h264 encoded file
  2. seek around a bit in it until your seek lands you on a suitable non-keyframe
  3. watch hilarious amounts of blocking and general garbage until the next IDR-frame.

Since H.264 has both IDR- and i-frames I can imagine this issue being related to something counting the i-frames as real I-frames for seeking purposes, but I probably shouldn't speculate.

Example screenshots: http://uppcon.se/thefluff/fansub/vlc/11.png http://uppcon.se/thefluff/fansub/vlc/05.PNG

Edited by Jean-Baptiste Kempf
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information