[gst-devel] gst-python: Problem emiting signals from Python

Johan Dahlin johan at fluendo.com
Sat Nov 20 15:24:14 CET 2004


>   dvdblocksrc_signals[QUEUE_EVENT_SIGNAL] =
>     g_signal_new ("queue-event",
>         G_TYPE_FROM_CLASS (klass),
>         G_SIGNAL_ACTION,
>         G_STRUCT_OFFSET (DVDBlockSrcClass, queue_event),
>         NULL, NULL,
>         gst_marshal_VOID__POINTER,
>         G_TYPE_NONE,
>         1, GST_TYPE_EVENT);
> 
> i.e. it receives a GstEvent and returns void. I try to emit it using a
> line like
> 
>         self.element.emit('queue-event', someEvent);
> 
> The result is an exception with the following error message:
> 
>   TypeError: could not convert type gst.Event to GstEvent required for parameter 0

It's probably a bug, haven't really tested/handled the marshal code from
GstEvent to a PyObject correctly. For GstData its somewhat better, but
it needs to be done for GstEvent (and GstBuffer) aswell.

Put this in bugzilla and I'll have a look.

-- 
Johan Dahlin <johan at fluendo.com>
Fluendo S.L.





More information about the gstreamer-devel mailing list