[MPlayer-dev-eng] [PATCH] unified timing patch for H264

Pásztor Szilárd don at tricon.hu
Thu Aug 19 18:49:09 CEST 2010


Reimar Döffinger:
> You just used it for !got_picture, however that doesn't help any,
> got_picture will be 0 regardless of whether the frame was skipped
> because it is a single field or for some other reason.
> Libavcodec to my knowledge just does not provide that information,
> which is why I was surprised how this was supposed to work.

To my understanding (after looking at decode_frame() in libavcodec/h264.c),
got_picture is set to 0 only if we have a single but correct field. The value
remains untouched in the case of a frame error. So if we supply a negative
value before calling the function, we could in theory know the reason: if it
remains negative after returning, we have an error.
Other decoders never set the new NULL image type so there should be no change
in effect at codecs other than h264.

Could you point me to a buggy h264 file sampledir -rt

> And btw. you said that the patch gets the information from the
> "parser", however it seems to only get information from the
> decoder, the parser is either part of the demuxer or comes in-between
> the demuxer and the decoder.

Yes, it's actually in vd_ffmpeg.c but it's good that libavcodec remained
unchanged.

s.

  ---------------------------------------------------------------------------
  |  The role may be thankless, but if you're willing to give it your all,  |
  |         you just might bring success to those who outlast you.          |
  ---------------------------------------------------------------------------


More information about the MPlayer-dev-eng mailing list