Commit f0326eea authored by Wim Taymans's avatar Wim Taymans

- Remove the propsprivate header file

Original commit message from CVS:
- Remove the propsprivate header file
- Added new API for properties.
- Moved the clock distribution to the scheduler.
- Removed the lock from GstCaps
- Added boxed types for Caps/Props
- Simplified the clock, new systemclock implementation
- Removed deprecated element_info/send_event functions
- First step at exposing more info in the pad_connect functions
- Queue cleanup
- Make the scheduler aware of other schedulers inside it
- Added the _SELF_SCHEDULABLE flag to gstthread
- Removed _get_widget from _utils, changed to new props API
- Make fakesink sync on timestamps when requested
- Removed the offset notify from filesrc
- Added a fast scheduler
- some scheduler cleanups.
parent 2ed5aa24
......@@ -145,19 +145,18 @@ libgstreamerinclude_HEADERS = \
noinst_HEADERS = \
gst_private.h \
gstarch.h \
gstpropsprivate.h \
cothreads.h
libgstreamer_la_CFLAGS = -D_GNU_SOURCE -DGST_CONFIG_DIR=\""$(GST_CONFIG_DIR)"\" \
$(LIBGST_CFLAGS) \
-D_GNU_SOURCE \
-DG_LOG_DOMAIN=g_log_domain_gstreamer \
-DGST_CONFIG_DIR=\""$(GST_CONFIG_DIR)"\"
-DGST_CONFIG_DIR=\""$(GST_CONFIG_DIR)"\"
# the compiler shoots cothreads.c in the head at -O6
libcothreads_la_CFLAGS = $(libgstreamer_la_CFLAGS) -O2
libcothreads_la_CFLAGS = $(libgstreamer_la_CFLAGS) -O2
libgstreamer_la_LIBADD = $(LIBGST_LIBS)
libgstreamer_la_LDFLAGS = @GST_LT_LDFLAGS@ -version-info @GST_LIBVERSION@
libgstreamer_la_LDFLAGS = @GST_LT_LDFLAGS@ -version-info @GST_LIBVERSION@
EXTRA_DIST = ROADMAP
......@@ -46,6 +46,7 @@ enum {
ARG_NUM_SINKS,
ARG_SILENT,
ARG_DUMP,
ARG_SYNC,
ARG_LAST_MESSAGE,
};
......@@ -60,6 +61,7 @@ GST_PADTEMPLATE_FACTORY (fakesink_sink_factory,
static void gst_fakesink_class_init (GstFakeSinkClass *klass);
static void gst_fakesink_init (GstFakeSink *fakesink);
static void gst_fakesink_set_clock (GstElement *element, GstClock *clock);
static GstPad* gst_fakesink_request_new_pad (GstElement *element, GstPadTemplate *templ, const
gchar *unused);
......@@ -106,12 +108,14 @@ gst_fakesink_class_init (GstFakeSinkClass *klass)
parent_class = g_type_class_ref (GST_TYPE_ELEMENT);
g_object_class_install_property (G_OBJECT_CLASS (klass), ARG_NUM_SINKS,
g_param_spec_int ("num_sinks", "num_sinks", "num_sinks",
g_param_spec_int ("num_sinks", "Number of sinks", "The number of sinkpads",
1, G_MAXINT, 1, G_PARAM_READABLE));
g_object_class_install_property (G_OBJECT_CLASS (klass), ARG_LAST_MESSAGE,
g_param_spec_string ("last_message", "last_message", "last_message",
NULL, G_PARAM_READABLE));
g_object_class_install_property(G_OBJECT_CLASS(klass), ARG_SYNC,
g_param_spec_boolean("sync","Sync","Sync on the clock",
FALSE, G_PARAM_READWRITE)); /* CHECKME */
gst_element_class_install_std_props (
GST_ELEMENT_CLASS (klass),
......@@ -141,9 +145,22 @@ gst_fakesink_init (GstFakeSink *fakesink)
fakesink->silent = FALSE;
fakesink->dump = FALSE;
fakesink->sync = FALSE;
fakesink->last_message = NULL;
GST_ELEMENT (fakesink)->setclockfunc = gst_fakesink_set_clock;
}
static void
gst_fakesink_set_clock (GstElement *element, GstClock *clock)
{
GstFakeSink *sink;
sink = GST_FAKESINK (element);
sink->clock = clock;
}
static GstPad*
gst_fakesink_request_new_pad (GstElement *element, GstPadTemplate *templ, const gchar *unused)
{
......@@ -183,6 +200,9 @@ gst_fakesink_set_property (GObject *object, guint prop_id, const GValue *value,
case ARG_DUMP:
sink->dump = g_value_get_boolean (value);
break;
case ARG_SYNC:
sink->sync = g_value_get_boolean (value);
break;
default:
break;
}
......@@ -208,6 +228,9 @@ gst_fakesink_get_property (GObject *object, guint prop_id, GValue *value, GParam
case ARG_DUMP:
g_value_set_boolean (value, sink->dump);
break;
case ARG_SYNC:
g_value_set_boolean (value, sink->sync);
break;
case ARG_LAST_MESSAGE:
g_value_set_string (value, sink->last_message);
break;
......@@ -228,9 +251,12 @@ gst_fakesink_chain (GstPad *pad, GstBuffer *buf)
fakesink = GST_FAKESINK (gst_pad_get_parent (pad));
if (fakesink->sync) {
gst_element_clock_wait (GST_ELEMENT (fakesink), fakesink->clock, GST_BUFFER_TIMESTAMP (buf));
}
if (!fakesink->silent) {
if (fakesink->last_message)
g_free (fakesink->last_message);
g_free (fakesink->last_message);
fakesink->last_message = g_strdup_printf ("chain ******* (%s:%s)< (%d bytes, %lld) %p",
GST_DEBUG_PAD_NAME (pad), GST_BUFFER_SIZE (buf), GST_BUFFER_TIMESTAMP (buf), buf);
......
......@@ -52,11 +52,14 @@ typedef struct _GstFakeSink GstFakeSink;
typedef struct _GstFakeSinkClass GstFakeSinkClass;
struct _GstFakeSink {
GstElement element;
GstElement element;
gboolean silent;
gboolean dump;
gchar *last_message;
gboolean silent;
gboolean dump;
gboolean sync;
GstClock *clock;
gchar *last_message;
};
struct _GstFakeSinkClass {
......
......@@ -321,6 +321,7 @@ gst_fakesrc_event_handler (GstPad *pad, GstEvent *event)
switch (GST_EVENT_TYPE (event)) {
case GST_EVENT_SEEK:
src->buffer_count = GST_EVENT_SEEK_OFFSET (event);
if (!GST_EVENT_SEEK_FLUSH (event)) {
gst_event_free (event);
break;
......
......@@ -105,7 +105,8 @@ struct _GstFakeSrc {
gboolean silent;
gboolean dump;
gboolean need_flush;
gchar *last_message;
gchar *last_message;
};
struct _GstFakeSrcClass {
......
......@@ -78,7 +78,7 @@ GstElementDetails gst_filesrc_details = {
"(C) 1999",
};
/*#define fs_print(format,args...) g_print(format, ## args)*/
/*#define fs_print(format,args...) g_print(format, ## args) */
#define fs_print(format,args...)
/* FileSrc signals and args */
......@@ -549,7 +549,7 @@ gst_filesrc_get (GstPad *pad)
/* we're done, return the buffer */
src->curoffset += GST_BUFFER_SIZE(buf);
g_object_notify (G_OBJECT (src), "offset");
//g_object_notify (G_OBJECT (src), "offset");
return buf;
}
......@@ -590,7 +590,7 @@ gst_filesrc_open_file (GstFileSrc *src)
/* now notify of the changes */
g_object_freeze_notify (G_OBJECT (src));
g_object_notify (G_OBJECT (src), "filesize");
g_object_notify (G_OBJECT (src), "offset");
//g_object_notify (G_OBJECT (src), "offset");
g_object_thaw_notify (G_OBJECT (src));
GST_FLAG_SET (src, GST_FILESRC_OPEN);
......@@ -614,7 +614,7 @@ gst_filesrc_close_file (GstFileSrc *src)
/* and notify that things changed */
g_object_freeze_notify (G_OBJECT (src));
g_object_notify (G_OBJECT (src), "filesize");
g_object_notify (G_OBJECT (src), "offset");
//g_object_notify (G_OBJECT (src), "offset");
g_object_thaw_notify (G_OBJECT (src));
if (src->mapbuf)
......
......@@ -181,7 +181,7 @@ gst_tee_request_new_pad (GstElement *element, GstPadTemplate *templ, const gchar
GList *pads;
g_return_val_if_fail (GST_IS_TEE (element), NULL);
if (templ->direction != GST_PAD_SRC) {
g_warning ("gsttee: request new pad that is not a SRC pad\n");
return NULL;
......
......@@ -35,7 +35,6 @@
#include <gst/gstpad.h>
#include <gst/gstbuffer.h>
#include <gst/gstcpu.h>
#include <gst/gstsystemclock.h>
#include <gst/gstelement.h>
#include <gst/gstbin.h>
#include <gst/gstpipeline.h>
......
......@@ -152,78 +152,16 @@ gst_bin_new (const gchar * name)
return gst_elementfactory_make ("bin", name);
}
static inline void
gst_bin_reset_element_sched (GstElement * element, GstScheduler * sched)
{
GST_INFO_ELEMENT (GST_CAT_PARENTAGE, element, "resetting element's scheduler");
gst_element_set_sched (element, sched);
}
static void
gst_bin_get_clock_elements (GstBin *bin, GList **needing, GList **providing)
{
GList *children = gst_bin_get_list (bin);
while (children) {
GstElement *child = GST_ELEMENT (children->data);
if (GST_IS_BIN (child)) {
gst_bin_get_clock_elements (GST_BIN (child), needing, providing);
}
if (child->getclockfunc) {
*providing = g_list_prepend (*providing, child);
}
if (child->setclockfunc) {
*needing = g_list_prepend (*needing, child);
}
children = g_list_next (children);
}
}
static void
gst_bin_distribute_clock (GstBin *bin, GList *needing, GstClock *clock)
{
while (needing) {
GST_DEBUG (GST_CAT_CLOCK, "setting clock on %s", GST_ELEMENT_NAME (needing->data));
gst_element_set_clock (GST_ELEMENT (needing->data), clock);
needing = g_list_next (needing);
}
}
static void
gst_bin_distribute_clocks (GstBin *bin)
{
GList *needing = NULL, *providing = NULL;
GstClock *clock;
gst_bin_get_clock_elements (bin, &needing, &providing);
if (GST_FLAG_IS_SET (bin, GST_BIN_FLAG_FIXED_CLOCK)) {
clock = bin->clock;
}
else if (providing) {
clock = gst_element_get_clock (GST_ELEMENT (providing->data));
}
else {
GST_DEBUG (GST_CAT_CLOCK, "no clock provided, using default clock");
clock = gst_system_clock_obtain ();
}
GST_BIN_CLOCK (bin) = clock;
gst_bin_distribute_clock (bin, needing, clock);
}
GstClock*
gst_bin_get_clock (GstBin *bin)
{
g_return_val_if_fail (bin != NULL, NULL);
g_return_val_if_fail (GST_IS_BIN (bin), NULL);
return GST_BIN_CLOCK (bin);
if (GST_ELEMENT_SCHED (bin))
return gst_scheduler_get_clock (GST_ELEMENT_SCHED (bin));
return NULL;
}
void
......@@ -232,8 +170,8 @@ gst_bin_use_clock (GstBin *bin, GstClock *clock)
g_return_if_fail (bin != NULL);
g_return_if_fail (GST_IS_BIN (bin));
GST_FLAG_SET (bin, GST_BIN_FLAG_FIXED_CLOCK);
GST_BIN_CLOCK (bin) = clock;
if (GST_ELEMENT_SCHED (bin))
gst_scheduler_use_clock (GST_ELEMENT_SCHED (bin), clock);
}
void
......@@ -242,12 +180,12 @@ gst_bin_auto_clock (GstBin *bin)
g_return_if_fail (bin != NULL);
g_return_if_fail (GST_IS_BIN (bin));
GST_FLAG_UNSET (bin, GST_BIN_FLAG_FIXED_CLOCK);
GST_BIN_CLOCK (bin) = NULL;
if (GST_ELEMENT_SCHED (bin))
gst_scheduler_auto_clock (GST_ELEMENT_SCHED (bin));
}
static void
gst_bin_set_element_sched (GstElement * element, GstScheduler * sched)
gst_bin_set_element_sched (GstElement *element, GstScheduler *sched)
{
GList *children;
GstElement *child;
......@@ -264,6 +202,7 @@ gst_bin_set_element_sched (GstElement * element, GstScheduler * sched)
if (GST_IS_BIN (element)) {
if (GST_FLAG_IS_SET (element, GST_BIN_FLAG_MANAGER)) {
GST_INFO_ELEMENT (GST_CAT_PARENTAGE, element, "child is already a manager, not resetting");
gst_scheduler_add_scheduler (sched, GST_ELEMENT_SCHED (element));
return;
}
......@@ -278,7 +217,6 @@ gst_bin_set_element_sched (GstElement * element, GstScheduler * sched)
gst_bin_set_element_sched (child, sched);
}
}
/* otherwise, if it's just a regular old element */
else {
......@@ -288,7 +226,7 @@ gst_bin_set_element_sched (GstElement * element, GstScheduler * sched)
static void
gst_bin_unset_element_sched (GstElement * element)
gst_bin_unset_element_sched (GstElement *element, GstScheduler *sched)
{
GList *children;
GstElement *child;
......@@ -302,7 +240,7 @@ gst_bin_unset_element_sched (GstElement * element)
return;
}
GST_INFO (GST_CAT_SCHEDULING, "removing element \"%s\" from it sched %p",
GST_INFO (GST_CAT_SCHEDULING, "removing element \"%s\" from its sched %p",
GST_ELEMENT_NAME (element), GST_ELEMENT_SCHED (element));
/* if it's actually a Bin */
......@@ -311,20 +249,21 @@ gst_bin_unset_element_sched (GstElement * element)
if (GST_FLAG_IS_SET (element, GST_BIN_FLAG_MANAGER)) {
GST_INFO_ELEMENT (GST_CAT_PARENTAGE, element,
"child is already a manager, not unsetting sched");
if (sched) {
gst_scheduler_remove_scheduler (sched, GST_ELEMENT_SCHED (element));
}
return;
}
gst_scheduler_remove_element (GST_ELEMENT_SCHED (element), element);
/* for each child, remove them from their schedule */
children = GST_BIN (element)->children;
while (children) {
child = GST_ELEMENT (children->data);
children = g_list_next (children);
gst_bin_unset_element_sched (child);
gst_bin_unset_element_sched (child, sched);
}
gst_scheduler_remove_element (GST_ELEMENT_SCHED (element), element);
}
/* otherwise, if it's just a regular old element */
else {
......@@ -372,10 +311,11 @@ gst_bin_add_many (GstBin *bin, GstElement *element_1, ...)
* add a reference.
*/
void
gst_bin_add (GstBin * bin, GstElement * element)
gst_bin_add (GstBin *bin, GstElement *element)
{
gint state_idx = 0;
GstElementState state;
GstScheduler *sched;
g_return_if_fail (bin != NULL);
g_return_if_fail (GST_IS_BIN (bin));
......@@ -409,11 +349,9 @@ gst_bin_add (GstBin * bin, GstElement * element)
/* now we have to deal with manager stuff
* we can only do this if there's a scheduler:
* if we're not a manager, and aren't attached to anything, we have no sched (yet) */
if (GST_IS_BIN (element) && GST_FLAG_IS_SET (element, GST_BIN_FLAG_MANAGER)) {
GST_INFO_ELEMENT (GST_CAT_PARENTAGE, element, "child is a manager");
}
else if (GST_ELEMENT_SCHED (bin) != NULL) {
gst_bin_set_element_sched (element, GST_ELEMENT_SCHED (bin));
sched = GST_ELEMENT_SCHED (bin);
if (sched) {
gst_bin_set_element_sched (element, sched);
}
GST_INFO_ELEMENT (GST_CAT_PARENTAGE, bin, "added child \"%s\"", GST_ELEMENT_NAME (element));
......@@ -429,7 +367,7 @@ gst_bin_add (GstBin * bin, GstElement * element)
* Remove the element from its associated bin, unparenting as well.
*/
void
gst_bin_remove (GstBin * bin, GstElement * element)
gst_bin_remove (GstBin *bin, GstElement *element)
{
gint state_idx = 0;
GstElementState state;
......@@ -456,7 +394,7 @@ gst_bin_remove (GstBin * bin, GstElement * element)
}
/* remove this element from the list of managed elements */
gst_bin_unset_element_sched (element);
gst_bin_unset_element_sched (element, GST_ELEMENT_SCHED (bin));
/* now remove the element from the list of elements */
bin->children = g_list_remove (bin->children, element);
......@@ -504,7 +442,7 @@ gst_bin_child_state_change (GstBin *bin, GstElementState oldstate, GstElementSta
GST_LOCK (bin);
bin->child_states[old_idx]--;
bin->child_states[new_idx]++;
for (i = GST_NUM_STATES - 1; i >= 0; i--) {
if (bin->child_states[i] != 0) {
gint state = (1 << i);
......@@ -512,7 +450,9 @@ gst_bin_child_state_change (GstBin *bin, GstElementState oldstate, GstElementSta
GST_INFO (GST_CAT_STATES, "bin %s need state change to %s",
GST_ELEMENT_NAME (bin), gst_element_statename (state));
GST_STATE_PENDING (bin) = state;
GST_UNLOCK (bin);
gst_bin_change_state_norecurse (bin);
return;
}
break;
}
......@@ -542,7 +482,11 @@ gst_bin_change_state (GstElement * element)
GST_INFO_ELEMENT (GST_CAT_STATES, element, "changing childrens' state from %s to %s",
gst_element_statename (old_state), gst_element_statename (pending));
if (pending == GST_STATE_VOID_PENDING)
return GST_STATE_SUCCESS;
children = bin->children;
while (children) {
child = GST_ELEMENT (children->data);
children = g_list_next (children);
......@@ -569,28 +513,6 @@ gst_bin_change_state (GstElement * element)
}
}
if (GST_ELEMENT_SCHED (bin) != NULL && GST_ELEMENT_PARENT (bin) == NULL) {
switch (transition) {
case GST_STATE_NULL_TO_READY:
gst_bin_distribute_clocks (bin);
break;
case GST_STATE_READY_TO_PAUSED:
if (GST_BIN_CLOCK (bin))
gst_clock_reset (GST_BIN_CLOCK (bin));
break;
case GST_STATE_PAUSED_TO_PLAYING:
gst_bin_distribute_clocks (bin);
if (GST_BIN_CLOCK (bin))
gst_clock_activate (GST_BIN_CLOCK (bin), TRUE);
break;
case GST_STATE_PLAYING_TO_PAUSED:
if (GST_BIN_CLOCK (bin))
gst_clock_activate (GST_BIN_CLOCK (bin), FALSE);
break;
}
}
GST_INFO_ELEMENT (GST_CAT_STATES, element, "done changing bin's state from %s to %s, now in %s",
gst_element_statename (old_state),
gst_element_statename (pending),
......
......@@ -48,10 +48,6 @@ extern GType _gst_bin_type;
# define GST_BIN_CLASS GST_BIN_CLASS_CAST
#endif
#define GST_BIN_CLOCK_PROVIDERS(bin) (GST_BIN(bin)->clock_providers)
#define GST_BIN_CLOCK_RECEIVERS(bin) (GST_BIN(bin)->clock_receivers)
#define GST_BIN_CLOCK(bin) (GST_BIN(bin)->clock)
typedef enum {
/* this bin is a manager of child elements, i.e. a pipeline or thread */
GST_BIN_FLAG_MANAGER = GST_ELEMENT_FLAG_LAST,
......@@ -82,8 +78,6 @@ struct _GstBin {
GstElementState child_states[GST_NUM_STATES];
GstClock *clock;
gpointer sched_private;
};
......@@ -128,9 +122,6 @@ void gst_bin_auto_clock (GstBin *bin);
/* one of our childs signaled a state change */
void gst_bin_child_state_change (GstBin *bin, GstElementState oldstate,
GstElementState newstate, GstElement *child);
/* one of our childs signaled an error */
void gst_bin_child_error (GstBin *bin, GstElement *child);
#ifdef __cplusplus
}
......
......@@ -26,11 +26,11 @@
#include "gstcaps.h"
#include "gsttype.h"
#include "gstpropsprivate.h"
static GMemChunk *_gst_caps_chunk;
static GMutex *_gst_caps_chunk_lock;
GType _gst_caps_type;
void
_gst_caps_initialize (void)
{
......@@ -38,6 +38,11 @@ _gst_caps_initialize (void)
sizeof (GstCaps), sizeof (GstCaps) * 256,
G_ALLOC_AND_FREE);
_gst_caps_chunk_lock = g_mutex_new ();
_gst_caps_type = g_boxed_type_register_static ("GstCaps",
(GBoxedCopyFunc) gst_caps_ref,
(GBoxedFreeFunc) gst_caps_unref);
}
static guint16
......@@ -104,7 +109,6 @@ gst_caps_new_id (const gchar *name, const guint16 id, GstProps *props)
caps->properties = props;
caps->next = NULL;
caps->refcount = 1;
caps->lock = g_mutex_new ();
if (props)
caps->fixed = props->fixed;
else
......@@ -128,11 +132,8 @@ gst_caps_destroy (GstCaps *caps)
if (caps == NULL)
return;
GST_CAPS_LOCK (caps);
next = caps->next;
GST_CAPS_UNLOCK (caps);
g_mutex_free (caps->lock);
gst_props_unref (caps->properties);
g_free (caps->name);
g_mutex_lock (_gst_caps_chunk_lock);
......@@ -189,11 +190,9 @@ gst_caps_unref (GstCaps *caps)
g_return_val_if_fail (caps->refcount > 0, NULL);
GST_CAPS_LOCK (caps);
caps->refcount--;
zero = (caps->refcount == 0);
next = &caps->next;
GST_CAPS_UNLOCK (caps);
if (*next)
*next = gst_caps_unref (*next);
......@@ -218,9 +217,7 @@ gst_caps_ref (GstCaps *caps)
{
g_return_val_if_fail (caps != NULL, NULL);
GST_CAPS_LOCK (caps);
caps->refcount++;
GST_CAPS_UNLOCK (caps);
return caps;
}
......@@ -296,9 +293,7 @@ gst_caps_copy_on_write (GstCaps *caps)
g_return_val_if_fail (caps != NULL, NULL);
GST_CAPS_LOCK (caps);
needcopy = (caps->refcount > 1);
GST_CAPS_UNLOCK (caps);
if (needcopy) {
new = gst_caps_copy (caps);
......@@ -798,7 +793,6 @@ gst_caps_load_thyself (xmlNodePtr parent)
g_mutex_unlock (_gst_caps_chunk_lock);
caps->refcount = 1;
caps->lock = g_mutex_new ();
caps->next = NULL;
caps->fixed = TRUE;
......
......@@ -30,13 +30,14 @@
typedef struct _GstCaps GstCaps;
extern GType _gst_caps_type;
#define GST_TYPE_CAPS (_get_caps_type)
#define GST_CAPS(caps) \
((GstCaps *)(caps))
#define GST_CAPS_LOCK(caps) (g_mutex_lock(GST_CAPS(caps)->lock))
#define GST_CAPS_TRYLOCK(caps) (g_mutex_trylock(GST_CAPS(caps)->lock))
#define GST_CAPS_UNLOCK(caps) (g_mutex_unlock(GST_CAPS(caps)->lock))
#define GST_CAPS_IS_FIXED(caps) ((caps)->fixed)
#define GST_CAPS_IS_CHAINED(caps) ((caps)->next)
......@@ -45,7 +46,6 @@ struct _GstCaps {
guint16 id; /* type id (major type) */
guint refcount;
GMutex *lock; /* global lock for this capability */
gboolean fixed; /* this caps doesn't contain variable properties */
GstProps *properties; /* properties for this capability */
......@@ -104,14 +104,16 @@ GstCaps* gst_caps_set_props (GstCaps *caps, GstProps *props);
GstProps* gst_caps_get_props (GstCaps *caps);
#define gst_caps_set(caps, name, args...) gst_props_set ((caps)->properties, name, args)
#define gst_caps_get(caps, name, args...) gst_props_get ((caps)->properties, name, args)
#define gst_caps_get_int(caps, name) gst_props_get_int ((caps)->properties, name)
#define gst_caps_get_float(caps, name) gst_props_get_float ((caps)->properties, name)
#define gst_caps_get_fourcc_int(caps, name) gst_props_get_fourcc_int ((caps)->properties, name)
#define gst_caps_get_boolean(caps, name) gst_props_get_boolean ((caps)->properties, name)
#define gst_caps_get_string(caps, name) gst_props_get_string ((caps)->properties, name)
#define gst_caps_get_int(caps,name,res) gst_props_entry_get_int(gst_props_get_entry((caps)->properties,name),res)
#define gst_caps_get_float(caps,name,res) gst_props_entry_get_float(gst_props_get_entry((caps)->properties,name),res)
#define gst_caps_get_fourcc_int(caps,name,res) gst_props_entry_get_fourcc_int(gst_props_get_entry((caps)->properties,name),res)
#define gst_caps_get_boolean(caps,name,res) gst_props_entry_get_boolean(gst_props_get_entry((caps)->properties,name),res)
#define gst_caps_get_string(caps,name,res) gst_props_entry_get_string(gst_props_get_entry((caps)->properties,name),res)
#define gst_caps_has_property(caps, name) gst_props_has_property ((caps)->properties, name)
#define gst_caps_has_property_typed(caps, name) gst_props_has_property_typed ((caps)->properties, name)
#define gst_caps_has_fixed_property(caps, name) gst_props_has_fixed_property ((caps)->properties, name)
GstCaps* gst_caps_get_by_name (GstCaps *caps, const gchar *name);
......
......@@ -29,13 +29,80 @@
#define CLASS(clock) GST_CLOCK_CLASS (G_OBJECT_GET_CLASS (clock))
static GMemChunk *_gst_clock_entries_chunk;
static GMutex *_gst_clock_entries_chunk_lock;
static GList *_gst_clock_entries_pool;
static void gst_clock_class_init (GstClockClass *klass);
static void gst_clock_init (GstClock *clock);
static GstObjectClass *parent_class = NULL;
/* static guint gst_clock_signals[LAST_SIGNAL] = { 0 }; */