FFmpeg 7.1.1
Loading...
Searching...
No Matches
timestamp.h File Reference

timestamp utils, mostly useful for debugging/logging purposes More...

#include "avutil.h"

Go to the source code of this file.

Macros

#define AV_TS_MAX_STRING_SIZE   32
 
#define av_ts2str(ts)
 Convenience macro, the return value should be used only directly in function arguments but never stand-alone.
 
#define av_ts2timestr(ts, tb)
 Convenience macro, the return value should be used only directly in function arguments but never stand-alone.
 

Functions

static char * av_ts_make_string (char *buf, int64_t ts)
 Fill the provided buffer with a string containing a timestamp representation.
 
char * av_ts_make_time_string2 (char *buf, int64_t ts, AVRational tb)
 Fill the provided buffer with a string containing a timestamp time representation.
 
static char * av_ts_make_time_string (char *buf, int64_t ts, const AVRational *tb)
 Fill the provided buffer with a string containing a timestamp representation.
 

Detailed Description

timestamp utils, mostly useful for debugging/logging purposes

Definition in file timestamp.h.

Macro Definition Documentation

◆ AV_TS_MAX_STRING_SIZE

#define AV_TS_MAX_STRING_SIZE   32

Definition at line 33 of file timestamp.h.

Referenced by av_ts_make_string().

◆ av_ts2str

#define av_ts2str ( ts)
Value:
static char * av_ts_make_string(char *buf, int64_t ts)
Fill the provided buffer with a string containing a timestamp representation.
Definition timestamp.h:43
#define AV_TS_MAX_STRING_SIZE
Definition timestamp.h:33

Convenience macro, the return value should be used only directly in function arguments but never stand-alone.

Examples
mux.c, and remux.c.

Definition at line 54 of file timestamp.h.

Referenced by log_packet(), and log_packet().

◆ av_ts2timestr

#define av_ts2timestr ( ts,
tb )
Value:
static char * av_ts_make_time_string(char *buf, int64_t ts, const AVRational *tb)
Fill the provided buffer with a string containing a timestamp representation.
Definition timestamp.h:73

Convenience macro, the return value should be used only directly in function arguments but never stand-alone.

Examples
demux_decode.c, mux.c, and remux.c.

Definition at line 83 of file timestamp.h.

Referenced by log_packet(), log_packet(), and output_audio_frame().

Function Documentation

◆ av_ts_make_string()

static char * av_ts_make_string ( char * buf,
int64_t ts )
inlinestatic

Fill the provided buffer with a string containing a timestamp representation.

Parameters
bufa buffer with size in bytes of at least AV_TS_MAX_STRING_SIZE
tsthe timestamp to represent
Returns
the buffer in input

Definition at line 43 of file timestamp.h.

◆ av_ts_make_time_string2()

char * av_ts_make_time_string2 ( char * buf,
int64_t ts,
AVRational tb )

Fill the provided buffer with a string containing a timestamp time representation.

Parameters
bufa buffer with size in bytes of at least AV_TS_MAX_STRING_SIZE
tsthe timestamp to represent
tbthe timebase of the timestamp
Returns
the buffer in input

Referenced by av_ts_make_time_string().

◆ av_ts_make_time_string()

static char * av_ts_make_time_string ( char * buf,
int64_t ts,
const AVRational * tb )
inlinestatic

Fill the provided buffer with a string containing a timestamp representation.

See also
av_ts_make_time_string2

Definition at line 73 of file timestamp.h.