[gst-devel] Dynamic pipelines

Martin Rubli martin_rubli at logitech.com
Fri May 26 01:44:07 CEST 2006


Hi all,

I've been doing some tests with dynamic insertion and removal of plug-ins.

The program I've been using is based on section 17.3 of the Application  
Development Manual. (BTW: The sample given on that page needs a few  
changes to work with GStreamer 0.10.)

I have tried different scenarios. In each case the pipeline looks  
something like this and is automatically created. (Using an .ogg file here  
but the same thing happens with other audio sources.)

filesrc ! oggdemux ! vorbisdec ! audioresample ! audioconvert ! FilterBin  
! alsasink

The FilterBin is a bin that contains one of the following (defined at  
compile time):
a) identity
b) audioresample ! audio/x-raw-int ! identity
c) audioresample ! audio/x-raw-int, rate=48000 ! identity
d) audioresample ! audio/x-raw-int, rate=8000 ! identity

Every 5 seconds the FilterBin is taken out of the pipeline or put back in,  
so that e.g. in case d) the audio should toggle between normal and pretty  
bad quality.

The problem is that the behavior is somewhat random for some of the cases.  
For cases a and b it works consistently well (audioresample should be a  
no-op). In cases c and d, however, I sometimes get interruptions of a  
couple of seconds and the debug log gives lines like:

<AlsaSink> resync after discont with previous sample of diff: 425761

My questions now: Where do these discontinuities come from and what can I  
do about it? Are there any more programs out there that do the same thing?

Different variations of changing the pipeline state during the  
insertion/removal phase didn't help either. The test code is attached.

I'd be grateful for any tips ... Cheers,
Martin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: dynpipe.c
Type: application/octet-stream
Size: 14042 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20060526/8e190c66/attachment.obj>


More information about the gstreamer-devel mailing list