[Bug 788200] New element: gstproxy that proxies buffers, events, and caps to separate pipeline

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Thu Oct 12 18:30:10 UTC 2017


https://bugzilla.gnome.org/show_bug.cgi?id=788200

--- Comment #6 from Nirbheek Chauhan <nirbheek.chauhan at gmail.com> ---
(In reply to Nicolas Dufresne (stormer) from comment #2)
> Review of attachment 360468 [details] [review]:
> 
> Whys is this mixed BSD and LGPLv2 (gstproxy.c) lisenced ?

It's based on the owr_inter_sink/src elements written by slomo for OpenWebRTC:

https://github.com/EricssonResearch/openwebrtc/blob/master/owr/owr_inter_sink.c
https://github.com/EricssonResearch/openwebrtc/blob/master/owr/owr_inter_src.c

These were BSD clause-2 licensed. I can relicense the whole as LGPL-2 if it is
appropriate.

(In reply to Nicolas Dufresne (stormer) from comment #3)
> Review of attachment 360468 [details] [review]:
> 
> ::: gst/proxy/gstproxysrc.c
> @@ +35,3 @@
> + *
> + * The element queues buffers from the matching proxysink to an internal
> queue,
> + * so everything downstream is properly decoupled from the upstream
> pipeline.
> 
> Ho do we use this element ?

Sorry, I'll update the comment with documentation on how to use it. Will also
ensure that a test accompanies it before it goes in-tree.

(In reply to Nicolas Dufresne (stormer) from comment #4)
> Review of attachment 360468 [details] [review]:
> 
> ::: gst/proxy/gstproxysrc.h
> @@ +1,2 @@
> +/*
> + * Copyright (C) 2015 Centricular Ltd.
> 
> Did you really wrote this in 2015, or is this copy paste error ?

I modified the code in 2015, and haven't had to make any changes since. I've
been meaning to post it for a while, but I forgot. I posted it now because dv_
(CCed) needed it for his use-case of 1 producer feeding N pipelines which he is
currently hacking with rtsp-server.

(In reply to Olivier CrĂȘte from comment #5)
> Review of attachment 360468 [details] [review]:
> 
> How does this work with clocks? Timing? Latency queries? Seeks ? State
> changes? You need to start the sink side before the src side ?
> 
> It feels like something is missing to make it a generic element. You should
> try to document a lot of caveats if we want to merge this.

All queries, events, buffers, and buffer lists are proxied. State changes are
independent since the upstream and downstreams are different pipelines.

You should ideally start the producer side before the consumer side, and there
is a queue on the consumer end to buffer in-band data if needed. If you start
downstream first, the state change will wait till the first buffer gets
proxied, but there shouldn't be any issues. :)

I'm not sure what you mean by clocks, are you worried that the upstream and
downstream might have, for instance, an audio clock and a system clock and go
out of sync? I think that would have to be handled manually with get_clock and
set_clock. Will document that.

Is there anything else you can see that might need to be documented?

My approach to this is that it has worked swimmingly for OWRTC and a few other
projects I've worked on, and I think it is ready for general consumption. I'm
sure people will find things to improve in this, and that's what -bad is for ;)

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.


More information about the gstreamer-bugs mailing list