[gst-devel] Dynamic pipelines

Rob Taylor robtaylor at floopily.org
Mon Jun 12 13:45:57 CEST 2006


Did you pause the pipeline before linking pads? We do this in Farsight,
and it works well for us.

Thanks,
Rob Taylor
Sébastien Moutte wrote:
> Hi Martin,
> 
> I already have this kind of discontinuities with a pipeline which has an 
> audio playback bin (queue ! decoder ! audioconvert ! directsoundsink) 
> that i was adding and removing from the main pipeline.
> after reconnections, i was getting a silence of a few seconds and next 
> the sound was coming back.
> I think your message "resync after discont with previous sample " could 
> come from the ring buffer of the audio sink base class.
> You can try to disable synchronization on the audio sink by setting the 
> "sync" property to false, it worked for me.
> 
> I hope it will help ...
> Sebastien
> 
> Martin Rubli a écrit :
>> Hi,
>>
>> Given the number of replies I have received (zero ;-), dynamically  
>> changing pipelines at play time doesn't seem very popular ...
>>
>> Has anyone tried this before and got it to work properly? If so, I'd be  
>> very grateful for sample code to compare it with mine, so that I know  
>> whether my code is wrong or whether I should file a bug against GStreamer.
>>
>> Thanks!
>> Martin
>>
>>
>> On Thu, 25 May 2006 16:02:42 -0700, Martin Rubli  
>> <martin_rubli at logitech.com> wrote:
>>
>>   
>>> 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
>>>     
>>
>> _______________________________________________
>> gstreamer-devel mailing list
>> gstreamer-devel at lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
>>
>>
>>   
> 
> 
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gstreamer-devel





More information about the gstreamer-devel mailing list