GNOME Bugzilla – Bug 764176
expose pad_link_maybe_ghosting
Last modified: 2016-04-06 13:34:27 UTC
gst_element_link_pads(full) only works with pad names which doesn't really work if you have actual pads you're attempting to link together across bin boundaries.
Created attachment 324734 [details] [review] utils: expose pad_link_maybe_ghosting()
Review of attachment 324734 [details] [review]: ::: gst/gstutils.c @@ +1520,3 @@ +gboolean +gst_pad_link_maybe_ghosting_full (GstPad * src, GstPad * sink, This needs docs and a Since marker :) Also should probably mention under which situations it can actually work
Created attachment 325075 [details] [review] utils: expose pad_link_maybe_ghosting() Now with docs!
Created attachment 325318 [details] [review] utils: check the correct element state when ghosting
Comment on attachment 325318 [details] [review] utils: check the correct element state when ghosting Bonus points for a unit test :)
commit e8c8c27ae81519af7942d34ed65a390baf27328e Author: Matthew Waters <matthew@centricular.com> Date: Mon Apr 4 10:28:18 2016 +0000 utils: check the correct element's state on ghosting pads Checking the current element's state when we're adding pads to the parent element is checking the wrong thing. Silences a 'attempting to add an inactive pad to a running element' warning when adding a ghost pad to a running parent bin of the parent bin of the element. https://bugzilla.gnome.org/show_bug.cgi?id=764176 commit f87630663856e15ef6d6e93b40a1f01f56aaa718 Author: Matthew Waters <matthew@centricular.com> Date: Fri Mar 25 01:28:18 2016 +0000 utils: expose pad_link_maybe_ghosting This is a useful function to automatically add ghost pads when linking two elements across bin boundaries without know their exact parentage. e.g. when using gst_parse_bin_from_description (with or without it ghosting pads), one can simply retreive the src/sink pads from the bin to link to another pad. Similar functionality is provided by gst_element_link_pads{_full}() however only by pad name rather than by actual pads. API: gst_pad_link_maybe_ghosting_full https://bugzilla.gnome.org/show_bug.cgi?id=764176
Comment on attachment 325318 [details] [review] utils: check the correct element state when ghosting Committed with a unit test.