[FFmpeg-devel] [RFC]subtitle timestamps (Was Basic XSUB encoder (take 5))

Reimar Döffinger Reimar.Doeffinger
Sat May 23 17:20:51 CEST 2009


On Sat, Feb 07, 2009 at 03:01:24PM +0100, Bj?rn Axelsson wrote:
> On Fri, 6 Feb 2009, Michael Niedermayer wrote:
> > On Thu, Feb 05, 2009 at 10:45:25PM +0100, Bj?rn Axelsson wrote:
> [...]
> > > I still need some help solving the timestamp problem as I don't think the
> > > hack used in the patch is acceptable.
> >
> > i thought about this a little, but i think your hack is not that far from
> > a possible solution
> > look at AVFrame.pts & AVCodecContext.time_base
> > AVSubtitle.pts should be like AVFrame.pts
> >
> > also start_display_time must be 0 on encoding because not all subtitle
> > encoders support it. Actually i think start_display_time should be handled
> > somehow different but iam not sure also this is getting off topic i guess
> 
> New topic started, so now it is on topic =)
> 
> If I understand this correctly some subtitle codecs (e.g. XSUB, SSA)
> require absolute timestamps, while other codecs (e.g. DVB, DVD) work
> only on timestamps relative to packet timestamps.
> 
> I made an initial attempt to implement that in the attached
> patch subtitle_pts.diff. I'm not very happy with it as the timestamp
> semantics of AVSubtitle got quite complex.
> 
> xsubdec_pts.diff implements the new semantics for the XSUB decoder.
> 
> (And the ffmpeg.c and ffplay.c patches should probably be broken out and
> cleaned up somewhat. But they are mostly included as examples and for
> testing.)

Does anyone know what to do about this?



More information about the ffmpeg-devel mailing list