[gst-devel] review for event handling patch

Stefan Kost ensonic at hora-obscura.de
Tue Jan 24 14:20:05 CET 2006


quick followup - I also tried

gst_element_found_tags(GST_ELEMENT(bin), taglist);

as an alternative for sending an tag event. Anyway that seems to do
roughly the same. In my case does not work :(
Is it suppose to work like this? Otherwise we might want to emit a
warning "can't send tags to a bin".

Stefan


Stefan Kost wrote:
> hi,
>
> I try to allow the following code:
>
>   seek_event = gst_event_new_seek(1.0, GST_FORMAT_TIME,
>         GST_SEEK_FLAG_FLUSH,
>         GST_SEEK_TYPE_SET, 0,
>         GST_SEEK_TYPE_SET, (GstClockTime)song_length);
>   }
>   if(!(gst_element_send_event(GST_ELEMENT(pipeline),seek_event))) {
>     GST_WARNING("element failed to handle seek event");
>   }
>   tag_event=gst_event_new_tag(taglist);
>   if(!(gst_element_send_event(GST_ELEMENT(pipeline),tag_event))) {
>     GST_WARNING("element failed to handle tag event");
>   }
>
> Attached is a patch with my current changes. The pipeline is something
> like a bunch of audiotestsrc elements hitting a bin containg an
> oggmuxer, encoder and a filesink.
> Alternatively the bin can contain an audiosink.
>
> When doing encoding both seek and tag events fails, when doing playback
> the tag-event fails.
> I need the seek to get an EOS (also for encoding). The tags are only
> needed when encoding.
>
> Am I challanging gst too much? Any feedback is very welcome.
>
> Stefan
>   





More information about the gstreamer-devel mailing list