GNOME Bugzilla – Bug 525532
[fakesink/fakesrc/identity] Uses GObject marshallers for marshalling GstBuffer
Last modified: 2008-05-13 12:53:46 UTC
Hi, fakesink/fakesrc/identity currently uses the gst_marshal_VOID__OBJECT_OBJECT marshaller for marshalling "void (GstBuffer *, GstPad *)". As GstBuffer is a GstMiniObject and the OBJECT marshallers as created by glib-genmarshall are expecting GObject derived types this is not correct. It only works and causes no assertions because gstmarshal.c is compiled with G_ENABLE_DEBUG. So, what needs to be done is either private VOID:MINIOBJECT,OBJECT marshaller or custom marshallers in gstmarshal.c for this. I guess we're using OBJECT marshallers for GstMiniObjects at other places too.
Or we could add our own gst-genmarshal that is a fork of glib-genmarshal + mini object support ;)
I think we should just use POINTER_OBJECT here instead. I don't really see the point in special mini object support, since it's not needed technically and doesn't really add any value whatsoever (and we still specify the GType separately anyway, presumably for future introspection purposes(?)).
2008-05-13 Sebastian Dröge <slomo@circular-chaos.org> * plugins/elements/gstfakesink.c: (marshal_VOID__MINIOBJECT_OBJECT), (gst_fake_sink_class_init): * plugins/elements/gstfakesrc.c: (marshal_VOID__MINIOBJECT_OBJECT), (gst_fake_src_class_init): Use custom marshalers that take GstMiniObject as first parameter. Using OBJECT as parameter while a GstMiniObject is given will lead to assertions if built with G_ENABLE_DEBUG. Fixes bug #525532.