[Ffmpeg-devel] Re: [PATCH] x264 avc encoding, movenc avcC, ctts

Baptiste COUDURIER baptiste.coudurier
Mon Feb 20 14:14:20 CET 2006


Michael Niedermayer wrote:
> just add it for mpeg4 and h264

I saw some samples containing MPEG2 having a ctts atom. That would mean
3 codecs.
Why not detecting B frames ? If tried in the modified patch, is this
acceptable ?

> [...]
> no this is wrong pts-dts does not need to be a multiple of pkt->duration
> the correct code IMHO is trk->cluster[cl][id].cts= (pkt->pts - pkt->dts) * enc->time_base.num;
> though i didnt check the spec ...
> also note that mov_write_stts_tag() is totally wrong, it must store the dts
> not blindly assume they are all equally spaced
> [...]

Here is a modified patch which do not seek and contains last entry.
About the pkt->duration, did you figure out something ?

Baptiste COUDURIER                              GnuPG Key Id: 0x5C1ABAAA
SMARTJOG S.A.                                    http://www.smartjog.com
Key fingerprint                 8D77134D20CC9220201FC5DB0AC9325C5C1ABAAA
Phone: +33 1 49966312
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: movenc_ctts.patch
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20060220/b47cef37/attachment.asc>

More information about the ffmpeg-devel mailing list