Name
GstClock -- Clocking and synchronisation.
Description
GstClock provides an easy way to synchonize against a global clock.
Details
GstClockTime
typedef guint64 GstClockTime; |
GstClockTimeDiff
typedef gint64 GstClockTimeDiff; |
GST_CLOCK_DIFF()
#define GST_CLOCK_DIFF(s, e) (GstClockTimeDiff)((s)-(e)) |
Calculate the difference between to timestamps. This does not create
and absolute difference so the result might be negative if the first
timestamp is less than the second timestamp.
struct GstClock
struct GstClock {
gchar *name;
GstClockTime start_time;
GstClockTime current_time;
GstClockTimeDiff adjust;
gboolean locking;
GList *sinkobjects;
gint num, num_locked;
GMutex *sinkmutex;
GMutex *lock;
}; |
gst_clock_new ()
create a new clock element
gst_clock_get_system ()
Get the global system clock
gst_clock_register ()
State that an object is interested in listening to the
given clock
gst_clock_set ()
Set the time of the given clock to time.
gst_clock_reset ()
Reset the given clock. The of the clock will be adjusted back
to 0.
gst_clock_wait ()
Wait for a specific clock tick on the given clock.
gst_clock_current_diff ()
Calculate the difference between the given clock and the
given time