[FFmpeg-devel] [RFC] h264 avoid starting decode on a non top field

Joakim Plate elupus at ecce.se
Fri Nov 11 21:03:04 CET 2011


Hi, 

This is hack/fix for a mpegts live stream sample we've encountered. I may
be able to provide it, but i'll have to check with source.

After some seeks (ie not always), we'd get a continous errors like:

[h264 @ 0xa87a1e0] illegal short term buffer state detected
[h264 @ 0xa87a1e0] Missing reference picture
    Last message repeated 53 times274KB vq=15107KB sq=    0B f=1/82
[h264 @ 0xa87a1e0] mmco: unref short failure
    Last message repeated 1 times
[h264 @ 0xa87a1e0] illegal short term buffer state detected
[h264 @ 0xa87a1e0] Missing reference picture5084KB sq=    0B f=1/83
    Last message repeated 11 times
[h264 @ 0xa87a1e0] illegal short term buffer state detected

It seems it starts decode on wrong field and then doesn't recovers. I'm not
sure if h264 mandates top field first in bitstream, if not there is
probably something better to check. But this seems logical.

I still get a corruption on seek after the fix. But it's much much less
after this and limited in time.

/Joakim
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-RFC-avoid-h264-decoder-starting-on-wrong-field-after.patch
Type: text/x-patch
Size: 796 bytes
Desc: Attached file: 0001-RFC-avoid-h264-decoder-starting-on-wrong-field-after.patch
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20111111/1452af7f/attachment.bin>


More information about the ffmpeg-devel mailing list