[FFmpeg-devel] Remaining problems in H.264 handling

Michael Niedermayer michaelni
Sat Mar 28 14:23:16 CET 2009

On Fri, Mar 27, 2009 at 07:56:59PM +0100, Ivan Schreter wrote:
> Hi,
> I changed the topic of the thread, since it doesn't have to do anything 
> with swscale anymore...
> Carl Eugen Hoyos wrote:
>> Ivan Schreter <schreter <at> gmx.net> writes:
>>> I provided a patch for this, which wasn't accepted by Michael.
>> Could you point me to the patch?
>> You had sent quite a lot...
> Well, the original patches didn't work anymore, so I attach a new one, just 
> for testing (doesn't increase minor of lavf/lavc).
>> [...]
>>> BTW, can you give me a link to a sample which doesn't play properly, so I 
>>> can look at it (if/when I get some time)?
>> Note that I do not know of any PAFF sample that does not work fine with 
>> ffmpeg
>> and ffplay. (I did not test AVCHD samples you mentioned, only the sony 
>> 9sec one.)
>> For MPlayer: 
>> http://lists.mplayerhq.hu/pipermail/mplayer-advusers/2009-March/001882.html
>> But I do not know of any PAFF sample that plays with currect MPlayer svn.
> Looking at the samples, yes, this is the case of MPEG-TS file with field 
> pictures (at least the second one), which declares double frame rate. My 
> patch should fix it, since frame rate is detected correctly then (though I 
> don't have time to test with mplayer).
> The first sample seems badly broken at the beginning, so our framerate 
> detection routine is confused. Possibly, there are also some other issues.

> IMHO, frame rate for H.264 (and probably also MPEG video) should be always 
> set to 1/2 tbc (and set to reliable, if timing info is provided), since 
> this maps the best to all possible combinations of picture structures. This 
> would also most probably make the first sample work without problem. But I 
> didn't do enough convinction work to convince Michael yet ;-).

convince me that the frame rate is 1/2 tbc?

if tbc is 1/90000 you want 45000 as framerate ?
if tbc is 1/60 on a telecined video you want it to be 1/30?

this is not about convincing its about starting out with ambgous terms
and ending with nonsense

1. time base and frame rate are 2 seperate things.
2. there is no frame rate field, and i repeat like i did many times in the
   past that people CANNOT hijack a timebase or the r_frame_rate field
   and set them to the frame rate.
   if you want a frame rate field that has to be added as a new field.

Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Into a blind darkness they enter who follow after the Ignorance,
they as if into a greater darkness enter who devote themselves
to the Knowledge alone. -- Isha Upanishad
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20090328/494bef36/attachment.pgp>

More information about the ffmpeg-devel mailing list