bufferpool: add macro to check for flushing
authorWim Taymans <wim.taymans@collabora.co.uk>
Fri, 15 Jul 2011 09:52:22 +0000 (11:52 +0200)
committerWim Taymans <wim.taymans@collabora.co.uk>
Fri, 15 Jul 2011 09:52:22 +0000 (11:52 +0200)
gst/gstbufferpool.c
gst/gstbufferpool.h

index 410c8c3..e487a31 100644 (file)
@@ -397,7 +397,7 @@ wrong_config:
  * allocated form this pool must be returned or else this function will do
  * nothing and return FALSE.
  *
- * @condfig is a #GstStructure that contains the configuration parameters for
+ * @config is a #GstStructure that contains the configuration parameters for
  * the pool. A default and mandatory set of parameters can be configured with
  * gst_buffer_pool_config_set(). This function takes ownership of @config.
  *
index b71b1ed..fed431a 100644 (file)
@@ -85,6 +85,15 @@ typedef struct _GstBufferPoolParams {
 } GstBufferPoolParams;
 
 /**
+ * GST_BUFFER_POOL_IS_FLUSHING:
+ * @pool: a GstBufferPool
+ *
+ * Check if the bufferpool is flushing. Subclasses might want to check the
+ * state of the pool in the acquire function.
+ */
+#define GST_BUFFER_POOL_IS_FLUSHING(pool)  (g_atomic_int_get (&pool->flushing))
+
+/**
  * GstBufferPool:
  * @object: the parent structure
  *