[gst-devel] plugin breakage

Benjamin Otte in7y118 at public.uni-hamburg.de
Tue Nov 11 04:51:03 CET 2003


On Sat, 8 Nov 2003, Andy Wingo wrote:

> On Fri, 31 Oct 2003, Benjamin Otte wrote:
>
> > 3)
> > Pad templates and element details are added to the element's class
> > structure in the base_init function.
>
> As it is, you can still add pad templates during the class_init. Those
> pad templates will still be inherited by subclasses (because the
> template list is just copied over, by value), but they won't be reffed,
> so you would need to ref them yourself.
>
> So I'm not sure which one is better: the extra syntactic hassle of
> making base_init functions or the hassle of going through the list and
> individually reffing pad templates. When you have properties you
> have to have a class_init, but there's not a real need for base_init, it
> seems to me. As long as you can share pad templates just by reffing,
> anyway.
>
It certainly is a possibility to make every class_init function ref the
padtemplates itself. But that doesn't buy you anything but trouble I
think. (You still work on the same GList elements for example)
Especially when you consider the fact that GStreamer wants to support
unloading of modules some time in the future.


Benjamin





More information about the gstreamer-devel mailing list