summaryrefslogtreecommitdiff
path: root/gst/gstpad.h
diff options
context:
space:
mode:
authorWim Taymans <wim.taymans@collabora.co.uk>2011-11-18 17:27:16 +0100
committerWim Taymans <wim.taymans@collabora.co.uk>2011-11-18 17:27:16 +0100
commit770159fb1ca388b11f2905fd0af58ec66387a4a0 (patch)
treed05d835927a35a286228b2b220bb8099f6859c04 /gst/gstpad.h
parent016d404ccf6a697df97b51f7929cd210535eb95b (diff)
downloadgstreamer-770159fb1ca388b11f2905fd0af58ec66387a4a0.tar.gz
query: improve scheduling query
Turns some boolean arguments in the scheduling query to flags, which are easier to extend and makes the code easier to read. Make extra methods for configuring and querying the supported scheduling modes. This should make it easier to add new modes later.
Diffstat (limited to 'gst/gstpad.h')
-rw-r--r--gst/gstpad.h34
1 files changed, 18 insertions, 16 deletions
diff --git a/gst/gstpad.h b/gst/gstpad.h
index f2a1b21bb6..3951d38944 100644
--- a/gst/gstpad.h
+++ b/gst/gstpad.h
@@ -44,6 +44,22 @@ typedef enum {
GST_PAD_SINK
} GstPadDirection;
+/**
+ * GstPadMode:
+ * @GST_PAD_MODE_NONE: Pad will not handle dataflow
+ * @GST_PAD_MODE_PUSH: Pad handles dataflow in downstream push mode
+ * @GST_PAD_MODE_PULL: Pad handles dataflow in upstream pull mode
+ *
+ * The status of a GstPad. After activating a pad, which usually happens when the
+ * parent element goes from READY to PAUSED, the GstPadMode defines if the
+ * pad operates in push or pull mode.
+ */
+typedef enum {
+ GST_PAD_MODE_NONE,
+ GST_PAD_MODE_PUSH,
+ GST_PAD_MODE_PULL
+} GstPadMode;
+
#include <gst/gstobject.h>
#include <gst/gstbuffer.h>
#include <gst/gstbufferlist.h>
@@ -211,26 +227,11 @@ typedef enum {
*/
#define GST_PAD_LINK_CHECK_DEFAULT ((GstPadLinkCheck) (GST_PAD_LINK_CHECK_HIERARCHY | GST_PAD_LINK_CHECK_CAPS))
-/**
- * GstPadMode:
- * @GST_PAD_MODE_NONE: Pad will not handle dataflow
- * @GST_PAD_MODE_PUSH: Pad handles dataflow in downstream push mode
- * @GST_PAD_MODE_PULL: Pad handles dataflow in upstream pull mode
- *
- * The status of a GstPad. After activating a pad, which usually happens when the
- * parent element goes from READY to PAUSED, the GstPadMode defines if the
- * pad operates in push or pull mode.
- */
-typedef enum {
- GST_PAD_MODE_NONE,
- GST_PAD_MODE_PUSH,
- GST_PAD_MODE_PULL
-} GstPadMode;
-
/* pad states */
/**
* GstPadActivateFunction:
* @pad: a #GstPad
+ * @parent: the parent of @pad
*
* This function is called when the pad is activated during the element
* READY to PAUSED state change. By default this function will call the
@@ -243,6 +244,7 @@ typedef gboolean (*GstPadActivateFunction) (GstPad *pad, GstObject *parent);
/**
* GstPadActivateModeFunction:
* @pad: a #GstPad
+ * @parent: the parent of @pad
* @active: activate or deactivate the pad.
*
* The prototype of the push and pull activate functions.