[FFmpeg-devel] [PATCH] Extends docs for av_gettime()

Reimar Döffinger Reimar.Doeffinger
Fri Jan 1 16:25:36 CET 2010


On Fri, Jan 01, 2010 at 03:27:25PM +0100, Stefano Sabatini wrote:
> On date Friday 2010-01-01 15:17:44 +0100, Stefano Sabatini encoded:
> > Hi, as in subject.
> 
> ... and the patch.
> -- 
> FFmpeg = Faithless Fiendish Magic Pitiless Egregious Gadget

> Index: ffmpeg/libavformat/avformat.h
> ===================================================================
> --- ffmpeg.orig/libavformat/avformat.h	2010-01-01 15:00:33.000000000 +0100
> +++ ffmpeg/libavformat/avformat.h	2010-01-01 15:13:17.000000000 +0100
> @@ -1211,7 +1211,10 @@
>   */
>  int64_t parse_date(const char *datestr, int duration);
>  
> -/** Gets the current time in microseconds. */
> +/**
> + * Gets the current time as the number of elapsed microseconds since
> + * Unix Epoch (1970-01-01).
> + */
>  int64_t av_gettime(void);

Which would mean we won't be able to switch to a guaranteed monotonic
clock for this, which is actually what all current uses of av_gettime
should be using though.
Documentation should be "returns the current time in microseconds from a
monotonic clock source with an unspecified starting time".
Until the functions is fixed, the "monotonic" should probably be left
out though.



More information about the ffmpeg-devel mailing list