[FFmpeg-devel] [SPAM] Re: Floating point dts, pts
cchatterj at hotmail.com
Mon Jan 23 18:14:56 CET 2012
Timebases are rationals which is great.
But pts, dts, duration are not.
Right now for 30fps, the dts will be 0, 33, 67, ... when they can be 0, 100/3, 200/3, .... more accurate.
The stream time bases can remain the way they are 1/1000 or 1/90000.
Adjusting the stream time bases to make the dtss integers is not advisable since stream time bases are used in many other calculations like pcr in TS which require accuracy and precision.
> Date: Mon, 23 Jan 2012 18:06:58 +0100
> From: h.leppkes at gmail.com
> To: ffmpeg-devel at ffmpeg.org
> Subject: Re: [FFmpeg-devel] [SPAM] Re: Floating point dts, pts
> On Mon, Jan 23, 2012 at 6:00 PM, C Chatterjee <cchatterj at hotmail.com> wrote:
> > Agree that AVRational will be better and more accurate than int64_t or double.
> > I proposed floating point for simplicity - may be not.
> > So how about int64_t rational?
> > Chanchal
> pts/dts are already more accurate then you give them credit for.
> They are "rationals", based on the related AVStreams time_base, which
> usually depends on the format in question.
> The demuxer sets those so that every timestamp in the file can be
> accurately represented, any more precision is useless.
> If the demuxer does something wrong there, its a bug. If any format
> would actually store timestamps in float, that might be another thing
> - but i'm not aware of any that does.
> - Hendrik
> ffmpeg-devel mailing list
> ffmpeg-devel at ffmpeg.org
More information about the ffmpeg-devel