tee: Check for the removed pad flag also in the slow pushing path
[platform/upstream/gstreamer.git] / gst / gstobject.c
index 1bf9f72..3aa20c4 100644 (file)
@@ -278,6 +278,9 @@ gst_object_unref (gpointer object)
  * the floating flag while leaving the reference count unchanged. If the object
  * is not floating, then this call adds a new normal reference increasing the
  * reference count by one.
+ *
+ * For more background on "floating references" please see the #GObject
+ * documentation.
  */
 gpointer
 gst_object_ref_sink (gpointer object)
@@ -293,6 +296,30 @@ gst_object_ref_sink (gpointer object)
 }
 
 /**
+ * gst_clear_object: (skip)
+ * @object_ptr: a pointer to a #GstObject reference
+ *
+ * Clears a reference to a #GstObject.
+ *
+ * @object_ptr must not be %NULL.
+ *
+ * If the reference is %NULL then this function does nothing.
+ * Otherwise, the reference count of the object is decreased using
+ * gst_object_unref() and the pointer is set to %NULL.
+ *
+ * A macro is also included that allows this function to be used without
+ * pointer casts.
+ *
+ * Since: 1.16
+ **/
+#undef gst_clear_object
+void
+gst_clear_object (GstObject ** object_ptr)
+{
+  g_clear_pointer (object_ptr, gst_object_unref);
+}
+
+/**
  * gst_object_replace:
  * @oldobj: (inout) (transfer full) (nullable): pointer to a place of
  *     a #GstObject to replace
@@ -1329,7 +1356,7 @@ gst_object_get_value (GstObject * object, const gchar * property_name,
 }
 
 /**
- * gst_object_get_value_array:
+ * gst_object_get_value_array: (skip)
  * @object: the object that has controlled properties
  * @property_name: the name of the property to get
  * @timestamp: the time that should be processed
@@ -1380,7 +1407,7 @@ gst_object_get_value_array (GstObject * object, const gchar * property_name,
  * @timestamp: the time that should be processed
  * @interval: the time spacing between subsequent values
  * @n_values: the number of values
- * @values: array to put control-values in
+ * @values: (array length=n_values): array to put control-values in
  *
  * Gets a number of #GValues for the given controlled property starting at the
  * requested time. The array @values need to hold enough space for @n_values of
@@ -1421,7 +1448,7 @@ gst_object_get_g_value_array (GstObject * object, const gchar * property_name,
  *
  * Obtain the control-rate for this @object. Audio processing #GstElement
  * objects will use this rate to sub-divide their processing loop and call
- * gst_object_sync_values() inbetween. The length of the processing segment
+ * gst_object_sync_values() in between. The length of the processing segment
  * should be up to @control-rate nanoseconds.
  *
  * If the @object is not under property control, this will return
@@ -1447,7 +1474,7 @@ gst_object_get_control_rate (GstObject * object)
  *
  * Change the control-rate for this @object. Audio processing #GstElement
  * objects will use this rate to sub-divide their processing loop and call
- * gst_object_sync_values() inbetween. The length of the processing segment
+ * gst_object_sync_values() in between. The length of the processing segment
  * should be up to @control-rate nanoseconds.
  *
  * The control-rate should not change if the element is in %GST_STATE_PAUSED or