* Adds a pad (link point) to @element. @pad's parent will be set to @element;
* see gst_object_set_parent() for refcounting information.
*
- * Pads are not automatically activated so elements should perform the needed
- * steps to activate the pad in case this pad is added in the PAUSED or PLAYING
- * state. See gst_pad_set_active() for more information about activating pads.
+ * Pads are automatically activated when added in the PAUSED or PLAYING
+ * state.
*
* The pad and the element should be unlocked when calling this function.
*
/* check for active pads */
if (!active && (GST_STATE (element) > GST_STATE_READY ||
GST_STATE_NEXT (element) == GST_STATE_PAUSED)) {
- g_warning ("adding inactive pad '%s' to running element '%s', you need to "
- "use gst_pad_set_active(pad,TRUE) before adding it.",
- GST_STR_NULL (pad_name), GST_ELEMENT_NAME (element));
gst_pad_set_active (pad, TRUE);
}
* Locks the state of an element, so state changes of the parent don't affect
* this element anymore.
*
+ * Note that this is racy if the state lock of the parent bin is not taken.
+ * The parent bin might've just checked the flag in another thread and as the
+ * next step proceed to change the child element's state.
+ *
* MT safe.
*
* Returns: %TRUE if the state was changed, %FALSE if bad parameters were given
if (pending)
*pending = GST_STATE_VOID_PENDING;
- GST_CAT_INFO_OBJECT (GST_CAT_STATES, element, "interruped");
+ GST_CAT_INFO_OBJECT (GST_CAT_STATES, element, "interrupted");
GST_OBJECT_UNLOCK (element);
*
* Retrieves the factory that was used to create this element.
*
- * Returns: (transfer none): the #GstElementFactory used for creating this
- * element. no refcounting is needed.
+ * Returns: (transfer none) (nullable): the #GstElementFactory used for creating this
+ * element or %NULL if element has not been registered (static element). no refcounting is needed.
*/
GstElementFactory *
gst_element_get_factory (GstElement * element)