[FFmpeg-devel] [PATCH] H.264/AVCHD interlaced fixes

Michael Niedermayer michaelni
Mon Feb 9 22:31:38 CET 2009


On Mon, Feb 09, 2009 at 09:39:27PM +0100, Ivan Schreter wrote:
> Michael Niedermayer wrote:
> > On Mon, Feb 09, 2009 at 01:01:53AM +0100, Ivan Schreter wrote:
> >   
> >> [...]
> >> In that case, however, each second field frame must get the same 
> >> timestamp as first field frame it is paired with. I.e., lavf's utils.c 
> >> must somehow know it is handling the second field of the same frame and 
> >> assign same DTS/PTS as first field (or offset by 1/2 frame duration in 
> >> case of interlaced video).
> >>
> >> [...]
> >>     
> >
> > we should support 2 fields in one buffer either way
> > what i want is correct and full support of h264 in h222 timestamp
> > interpolation
> >
> >
> >   
> In that case, is the above the solution (at least for common case)? If 
> yes, I'll send you a patch. I suppose it should be enough - DTS/PTS 
> computation for full frames does work and even in field-picture stream, 
> current formulas for first field of a frame still hold - problematic is 
> just second frame. Right?

as ive said already, you have a guranteed timestamps once every 0.7 seconds
this can be always on the first field or always on the second or randomly

the current code cannot interpolate timestamps for h264, building code on
the assumtation that the current would work for the first field seems
strange. But you can point me to the section of H222/264 that supports
your theory about conseutive field timestamp relation.

Besides the only point of not merging fields to frames is to support
cases where this is not possible, your assumtations seem to still
include the mpeg2 field pairedness that allows the fields to be merged.

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Everything should be made as simple as possible, but not simpler.
-- Albert Einstein
-------------- 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/20090209/6760c0f5/attachment.pgp>



More information about the ffmpeg-devel mailing list