pad: add method to mark reconfigure
authorWim Taymans <wim.taymans@collabora.co.uk>
Thu, 4 Aug 2011 15:12:21 +0000 (17:12 +0200)
committerWim Taymans <wim.taymans@collabora.co.uk>
Thu, 4 Aug 2011 15:12:21 +0000 (17:12 +0200)
gst/gstpad.c
gst/gstpad.h

index bf1c70d..6e83033 100644 (file)
@@ -1264,6 +1264,23 @@ gst_pad_check_reconfigure (GstPad * pad)
 }
 
 /**
+ * gst_pad_mark_reconfigure:
+ * @pad: the #GstPad to mark
+ *
+ * Mark a pad for needing reconfiguration. The next call to
+ * gst_pad_check_reconfigure() will return %TRUE after this call.
+ */
+void
+gst_pad_mark_reconfigure (GstPad * pad)
+{
+  g_return_if_fail (GST_IS_PAD (pad));
+
+  GST_OBJECT_LOCK (pad);
+  GST_OBJECT_FLAG_SET (pad, GST_PAD_NEED_RECONFIGURE);
+  GST_OBJECT_UNLOCK (pad);
+}
+
+/**
  * gst_pad_set_activate_function:
  * @pad: a #GstPad.
  * @activate: the #GstPadActivateFunction to set.
index b22bfad..999a537 100644 (file)
@@ -827,6 +827,7 @@ void                    gst_pad_remove_probe                    (GstPad *pad, gu
 gboolean               gst_pad_is_blocked                      (GstPad *pad);
 gboolean               gst_pad_is_blocking                     (GstPad *pad);
 
+void                    gst_pad_mark_reconfigure                (GstPad *pad);
 gboolean               gst_pad_check_reconfigure               (GstPad *pad);
 
 void                   gst_pad_set_element_private             (GstPad *pad, gpointer priv);