GNOME Bugzilla – Bug 592209
[GstPad] Deprecated markers missing in the header for internal links function related things
Last modified: 2009-08-21 17:19:49 UTC
Hi, GST_PAD_INTLINKFUNC(), gst_pad_set_internal_link_function, gst_pad_get_internal_links, gst_pad_get_internal_links_default are still in the public gstpad.h header and not inside a GST_DISABLE_DEPRECATED block although they're deprecated. Adding such a block there has some other problems though, like core elements still using it ;) Patches follow...
Created attachment 141063 [details] [review] gstpad-deprecate-internal-links.diff
Created attachment 141064 [details] [review] multiqueue-iterate-pads.diff This is completely untested but *should* work I guess. Does someone know an easy way to check if it works? :)
Created attachment 141065 [details] [review] tools-iterate-pads.diff
(In reply to comment #2) > Created an attachment (id=141064) [details] > multiqueue-iterate-pads.diff > > This is completely untested but *should* work I guess. Does someone know an > easy way to check if it works? :) Whatever, I've tested it from a small sample application. It's even valgrind clean ;)
Next step is the input/streamselector from gst-plugins-base that needs fixing...
Created attachment 141107 [details] [review] selector-internal-links.diff This might not be 100% correct but should work... comments?
Ok, I've slightly changed the selector patch. Next part is rtpjitterbuffer and rtpssrcdemux ;)
Created attachment 141159 [details] [review] good-rtp-iterate-links.diff Patch for gst-plugins-good that fixes the RTP plugin. I'll commit this after freeze but this is no blocker for this bug because we build pre-releases/releases without -DGST_DISABLE_DEPRECATED.
Created attachment 141161 [details] [review] bad-iterate-pads.diff Same for gst-plugins-bad... I'm going to commit all the other patches now.
Closing this as the core/base part is fixed... I'll simply push the good/bad parts when they're not frozen anymore.
We should probably have a "gst_iterator_new_single()" or something instead of copying the same code everywhere.
(In reply to comment #11) > We should probably have a "gst_iterator_new_single()" or something instead of > copying the same code everywhere. Sure but that wouldn't save a lot of code either. You still need a custom free function and a custom "get the element" function because that part is still different. Or do you have any idea to save even more duplication?
I was thinking of a function that takes a GObject, so the free would always be g_object_unref() and just give it the pad directly (just like the old iterate_links code worked).
(In reply to comment #13) > I was thinking of a function that takes a GObject, so the free would always be > g_object_unref() and just give it the pad directly (just like the old > iterate_links code worked). But then you could get outdated information from the iterator and would also have no way to resync the iterator to get the current valid information.
For most cases when there is a single possiblity (like rtpsession, etc), there is only one possibility and it won't change.