Two pipelines - link them - merge them - easy handling...

Maurer, Martin martin2.maurer at zeiss.com
Thu Apr 12 15:39:55 UTC 2018


Hello,

I have two (sub-) pipelines, which I create via two gst_parse_launch calls.

pipe1 = gst_parse_launch("...");
pipe2 = gst_parse_launch("...");

I have different pipe2 pipelines, which I create for different use cases.

Now I want to dynamically link them together, so I get a big pipeline out of the two smaller ones.
Just link the end of the first pipeline with the beginning of the second pipeline.

I assume this is only possible if all my elements are inside one pipeline? Not distributed over two pipelines. Is this correct?
So is there perhaps some function to merge pipe2 into pipe1 (and all link info also taken over)?
Some enumeration over all elements of pipe2 and calling add/link for pipe1?
(ok, problem could be, if and how I can remove the added part, how to identify what was pipe2 inside pipe1,
but this is a secondary problem, perhaps I can live without it)

Or some function call similar to gst_parse_launch, where I can insert an already existing pipeline?

A solution, which could perhaps be possible, to use appsink at end of pipe 1 and appsrc in the beginning of pipe2.
But then I must forward the buffers (and more) by hand...

Or gst-interpipe? https://github.com/RidgeRun/gst-interpipe

But in my opinion these last both are (too) heavy things for just the problem of basic (easy?) pipeline/element handling.

I know it is possible to use gst_element_factory_make, gst_bin_add_many, gst_element_link_many, ...
but this is not as comfortable and easy to use like the pipeline strings in gst_parse_launch.
(reading what element was added, which were linked in which order,
and modifying it: e.g. adding/removing a new element doesn't affect multiple places)

Best regards,

Marie




-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20180412/fe27ecf3/attachment.html>


More information about the gstreamer-devel mailing list