splitmuxsink arbitrary close
cottrelld
david at elarm.com
Sun Jul 26 10:24:21 PDT 2015
The sending of the EOS closes out the file if I just sent it by itself
without the block (Half way there!). But I can't get the sink in order to
place the probe and capture the callback. How do you obtain the sink pad
on the splitmuxsink? I get null back from gst_element_get_static_pad in
the code below.
>> What I would do is to place a probe on the splitmuxsink sink pad, with
the flag GST_PAD_PROBE_TYPE_EVENT_DOWNSTREAM and then verify the EOS in the
callback with
(Note, I also tried to obtain the actual sink in hopes of getting the pad
off that, but the sink property is only the provided sink. )
*void PipelineManager::stopPipeline_writerImpl()*
{
g_print("stopPipeline_writerImpl, stopping\n");
if (!gPipelineMgr->m_writeSink) {
g_critical("stopPipeline_writerImpl: m_writeSink is NULL!!\n");
exit(-1);
}
// Block all transmissions past m_queueWriterTee
GstPad* writerSinkPad =
gst_element_get_static_pad(gPipelineMgr->m_writeSink, "sink");
if (!writerSinkPad) {
g_critical("stopPipeline_writerImpl: Could not obtain the writer
sinkpad!!\n"); // <---- fails here!
exit(-1);
}
gst_pad_add_probe(writerSinkPad,
(GstPadProbeType)(GST_PAD_PROBE_TYPE_EVENT_DOWNSTREAM),
writer_eos_cb,
m_loop,
NULL);
gst_object_unref(writerSinkPad);
// Send an EOS on the queue
GstPad* queueSinkPad = gst_element_get_static_pad
(gPipelineMgr->m_queueWriterTee, "sink");
gst_pad_send_event(queueSinkPad, gst_event_new_eos ());
gst_object_unref(queueSinkPad);
g_print("stopPipeline_writerImpl, done...\n");
}
Thanks again for your help!
-David
--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/splitmuxsink-arbitrary-close-tp4672799p4672852.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20150726/fa1dc153/attachment.html>
More information about the gstreamer-devel
mailing list