Time delay in setting property & audio mixer element
Marco Ballesio
gibrovacco at gmail.com
Sat May 28 10:07:49 PDT 2011
Hi,
another late reply from my famous series, bte find my comment(s) below..
On Fri, May 20, 2011 at 7:21 PM, Pietro Battiston <me at pietrobattiston.it>wrote:
..snip..
4) am I missing something else (in the end, it's been few days since I
> first programmed with gstreamer)?
>
>
latencies can come fro various places... how are you measuring it? (e.g. you
have an oscilloscope connected to the speakers). As a note, you should check
the overall latency in the whole pipeline, but most probably, if you're
using pulseaudio, it's in pulsesink that you should focus (try tweaking
buffer-time and latency-time, defaulting to about 10ms multiples).
Another influence factor is the size of the buffers wrt the sample rate
you're using in the source element: obviously, the smaller buffers the lower
latencies. audiotestsrc has default blocksize set to 4096, default sample
rate set to 44100Hz, that is about 22 ms of latency. Combined with the
default pulsesink latency of above, rounded up to the 10ms multiples, we've
pretty much the 30ms you've been measuring.
Btw I doubt you'll ever be able to get latencies lower than a few multiples
of 1/HZ (
http://www.unix.com/linux/48694-kernel-how-modify-read-tick-rate-hz.html),
especially if dealing with the CFS..
Or more in general: do you suggest that gstreamer can do what I want or
> am I using the wrong tool?
>
it depends on your target latency (see above), for sub-millisecond values
one might even argue about the opportunity to use any non-realtime
approaches ;)
>
> While I'm at it, another question: I searched for some element doing the
> inverse of "tee" for audio. I found a discussion on the argument:
>
> http://gstreamer-devel.966125.n4.nabble.com/aggregator-element-td973247.html
> which however was dropped. Dan:
>
> http://gstreamer-devel.966125.n4.nabble.com/aggregator-element-td973247.html#a973254
> proposed several "interpretations" of that request, and what I need is
> precisely the last: "For audio-only mix the inputs to one output, like a
> multi-track studio mixer? ". Is there such an element?
>
>
here you go:
http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-plugins-base-plugins/html/gst-plugins-base-plugins-adder.html
Regards
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20110528/24ab8e03/attachment.html>
More information about the gstreamer-devel
mailing list