Tracking the demuxer responsible for SEGMENT_DONE message

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

Tracking the demuxer responsible for SEGMENT_DONE message

Baby Octopus
Administrator
Hi,

I'm getting a SEGMENT_DONE message in the bus and pipeline is posting that. Is there a way fro me to know which demuxer would be responsible for this? Identifying the demuxer is crucial since there are mutliple demuxers in the pipeline

Any pointers will be helpful

~BO
Reply | Threaded
Open this post in threaded view
|

Re: Tracking the demuxer responsible for SEGMENT_DONE message

Tim Müller
On Mon, 2017-02-20 at 01:25 -0800, Baby Octopus wrote:

Hi,

> I'm getting a SEGMENT_DONE message in the bus and pipeline is posting
> that. Is there a way fro me to know which demuxer would be
> responsible for this? Identifying the demuxer is crucial since there
> are mutliple demuxers in the pipeline

GST_MESSAGE_SRC(message) should give you the object pointer of the
demuxer that posted this message.

Cheers
 -Tim

--
Tim Müller, Centricular Ltd - http://www.centricular.com
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Tracking the demuxer responsible for SEGMENT_DONE message

Baby Octopus
Administrator
Hi Tim,

Thanks for the response

SEGMENT_DONE message seems to be posted by the GstPipeline itself. So GST_ELEMENT_NAME(GST_MESSAGE_SRC(message)) is giving name of the pipeline and not the demuxer

Kindly let me know if my understanding is wrong

~BO
Reply | Threaded
Open this post in threaded view
|

Re: Tracking the demuxer responsible for SEGMENT_DONE message

Nicolas Dufresne-5
Le lundi 20 février 2017 à 02:52 -0800, Baby Octopus a écrit :
> Hi Tim,
>
> Thanks for the response
>
> SEGMENT_DONE message seems to be posted by the GstPipeline itself. So
> GST_ELEMENT_NAME(GST_MESSAGE_SRC(message)) is giving name of the
> pipeline
> and not the demuxer
>

GstBin (your pipeline), will watch for all GST_MESSAGE_SEGMENT_START
and will forward to the application a single message when the same
number of GST_MESSAGE_SEGMENT_DONE has been received.

So technically, this message is from all the elements driving (handling
seeks) your pipeline (demuxers, parsers or sources). It is sent once to
the application so you should not have to care.

You can of course implement GstBin::handle_message() in one of your own
bin, and handle those messages yourself for a subset of your pipeline.

Nicolas
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

signature.asc (188 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Tracking the demuxer responsible for SEGMENT_DONE message

Baby Octopus
Administrator
Aah, I understand. Thank you very much for your valuable info :)
Reply | Threaded
Open this post in threaded view
|

Re: Tracking the demuxer responsible for SEGMENT_DONE message

Tim Müller
In reply to this post by Nicolas Dufresne-5
On Mon, 2017-02-20 at 14:25 -0500, Nicolas Dufresne wrote:

> GstBin (your pipeline), will watch for all GST_MESSAGE_SEGMENT_START
> and will forward to the application a single message when the same
> number of GST_MESSAGE_SEGMENT_DONE has been received.
>
> So technically, this message is from all the elements driving
> (handling seeks) your pipeline (demuxers, parsers or sources). It is
> sent once to the application so you should not have to care.
>
> You can of course implement GstBin::handle_message() in one of your
> own bin, and handle those messages yourself for a subset of your
> pipeline.

You *should* also be a able to set the message-forward=true property
and then get the individual SEGMENT_DONE messages forwarded wrapped
inside an ELEMENT message, bypassing the aggregation done by GstBin.

Cheers
 -Tim
--
Tim Müller, Centricular Ltd - http://www.centricular.com
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel