[FFmpeg-devel] H.264 + PAFF: BBC HD recording shows extreme interlacing artefacts

Reinhard Nissl rnissl
Mon Nov 5 22:22:19 CET 2007


Hi,

Jeff Downs schrieb:

>>> To me, when FIELD_PICTURE is true, the patch says:
>>>
>>> top_field_first = MIN(top_poc, bottom_poc) == bottom_poc
>>>
>>> or, more simply:
>>>
>>> top_field_first = bottom_poc <= top_poc
>>>
>>> Or do I miss something?
>>
>> I've hacked in this equation and it works opposite to mine. What I have
>> seen in my previous tests was that for field pictures poc pointed to the
>> second decoded field at that source location and hence the
>> top_field_first had to be set when poc pointed to the bottom field.
> 
> Are you dealing with field pictures all the time? The above was analyzed 

No. The sample stream on ASTRA HD+ changes between field and frame
pictures frequently. The BBC HD sample mentioned in the subject uses
only MBAFF.

> in context of field pictures only (ie, I removed the variability of 
> FIELD_PICTURE from your original).  What you had for !FIELD_PICTURE looked 
> like it would be plausible.

Your equation matched the frame picture case on ASTRA HD+, but not the
field picture case, nor the MBAFF case (at least the latter was expected
behavior).

> poc does not necessarily have to be the second decoded field's poc.
> It should be the minimum of the two field pocs, regardless of decoding 
> order, once a field pair is complete.

A short excerpt from an above mentioned frame / field / frame
transition. The message is logged at the position where I've added the
top_field_first logic. The lines marked with ~~~ indicate, where your
equation differs from mine.

picture_structure: 3, field_poc[0]: 164, field_poc[1]: 164, poc: 164
picture_structure: 3, field_poc[0]: 166, field_poc[1]: 166, poc: 166
picture_structure: 2, field_poc[0]: 172, field_poc[1]: 173, poc: 173 ~~~
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
picture_structure: 2, field_poc[0]: 170, field_poc[1]: 171, poc: 171 ~~~
picture_structure: 2, field_poc[0]: 176, field_poc[1]: 177, poc: 177 ~~~
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
[h264 @ 0xb62062f0]Interlaced pictures + spatial direct mode is not
implemented
picture_structure: 2, field_poc[0]: 174, field_poc[1]: 175, poc: 175 ~~~
picture_structure: 3, field_poc[0]: 182, field_poc[1]: 182, poc: 182
picture_structure: 3, field_poc[0]: 178, field_poc[1]: 178, poc: 178

> As an aside, are you testing this directly with ffmpeg, or libxine as well 
> (like in your other post).  Reason I ask is that the same problem 
> occurring there might be impacting things here, too.

Well, I've only tested with libxine so far. You're right that when the
other error occurs then top_field_first will be determined incorrectly.
I assume this as moving objects in the deinterlaced content jump back
and forth.

Bye.
-- 
Dipl.-Inform. (FH) Reinhard Nissl
mailto:rnissl at gmx.de




More information about the ffmpeg-devel mailing list