Why is wav file mixed by soundmixer plugin truncated?
Nicolas Dufresne
nicolas at ndufresne.ca
Mon Dec 4 15:25:04 UTC 2017
Le lundi 04 décembre 2017 à 01:53 -0700, toub a écrit :
> I develop in C an application relying on soundmixer plugin. My aim is to
> trigger sounds on events. As reactivity is critical, I wish to keep
> gstreamer pipeline alive, and dynamically plug new sounds on the audiomixer
> element (after applying an offset on the new sink of the mixer).
> It works pretty well, except that each time if plug a new sound in, the
> first 200msec (more or less) of the sound get truncated.
> I've been looking into the code, everything looks fine as far as I can see
> (no mistake on sound plugin, neither on running time/offset applied).
> So I made a try on a simple pipeline with gst-launch, with an offset applied
> on the mixer sink:
I do that same in one of my application. You need to substract (using
pad offsets) some of the latency, otherwise the data will be late,
hence dropped. It won't be a surprise if I tell you that alsasink
default configured latency (see buffer-time property) is 200ms.
Nicolas
More information about the gstreamer-devel
mailing list