[Bug 597822] Add removesilence plugin

GStreamer (bugzilla.gnome.org) bugzilla at gnome.org
Sun May 29 22:54:38 PDT 2011


https://bugzilla.gnome.org/show_bug.cgi?id=597822
  GStreamer | gst-plugins-bad | git

--- Comment #16 from Sebastian Dröge <slomo at circular-chaos.org> 2011-05-30 05:54:22 UTC ---
(In reply to comment #15)

> > Not every buffer has timestamps, it can also be GST_CLOCK_TIME_NONE (i.e. -1). Also I think this code doesn't make much sense
> 
> On the time i wrote it i didn't have idea that was possible. I'm going to fix
> that. This was made to avoid a problem that i had, the objective of the plugin
> is to remove the silence periods, but produce a continuous stream (no gaps on
> the timestamps), if a buffer is silence, it is dropped, but the drop will not
> appear on downstream elements because the plugin corrects the timestamps on the
> buffers, so it seems that no buffer was dropped and the audio is perfect, only
> without the silences. Using GstAudioFilter and returning
> GST_BASE_TRANSFORM_FLOW_DROPPED will give this same behaviour ?

No, this will only drop the buffer. You still have to adjust the timestamps
and/or durations yourself

> > You should set the DISCONT flag on the next buffer that is pushed downstream. Also you need to send filler newsegment events downstream if there's a too big duration of silence. Also, an optional mode to just set the GAP flag on silence buffers instead of dropping them would be good.
> 
> This would give me the behaviour that i described before? the idea was to
> exactly fool the downstream elements, so they think that no buffer was dropped.

Ok, then don't set that flag :)

> > Why do you keep track of the timestamps?
> 
> To create the behaviour i described before, but based on the corrections you
> proposed it seems that it is a better way to do this (i never liked this
> timestamp stuff, but i didn't think on other idea that behaved like i wanted)

I think this is how a removesilence element should work, what I've described
would be more a detectsilence element.

-- 
Configure bugmail: https://bugzilla.gnome.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the gstreamer-bugs mailing list