[gstreamer-bugs] [Bug 340362] [PATCH] new plugin - hardlimiter

GStreamer (bugzilla.gnome.org) bugzilla-daemon at bugzilla.gnome.org
Sun Oct 1 05:07:45 PDT 2006


Do not reply to this via email (we are currently unable to handle email
responses and they get discarded).  You can add comments to this bug at
http://bugzilla.gnome.org/show_bug.cgi?id=340362

GStreamer | gst-plugins-bad | Ver: HEAD CVS





------- Comment #12 from René Stadler  2006-10-01 12:06 UTC -------
Created an attachment (id=73746)
 --> (http://bugzilla.gnome.org/attachment.cgi?id=73746&action=view)
Graphs of different transfer functions

A picture says more than thousand words:

 1. Red graph: Clipping (as originally proposed by Артём)
 2. Blue graph: Linear filter (like Stefan mentioned)
 3. Green graph: Smooth hard limiting (like I mentioned)

All filters have a threshold of 0.5 (ca. -6 dB), that is they leave values
below 0.5 (above -0.5) intact.  The picture shows clearly why for clipping, the
waveform gets irreversibly distorted if it exceeds the threshold.  I mention
this because some people seem to have the impression that clipping can somehow
be undone by reducing the volume or something.  It is not.  Clipping is also
done implicitely by audioconvert when it converts from float to integer, which
is most often done to finally send the data to the sound card.  That's the red
area on the graphs, it can never be reached in integer formats as it is beyond
what is defined as maximum.

Second one is a real signal compressor that gives good results instead of
useless distortion.  It's exactly what Stefan said: Basically a selective
volume change that only operates on values exceeding a threshold.  It is very
efficient (just a multiplication in addition to the switching), but that comes
at a price: Trained ears (which I don't claim to have) seem to be able to hear
the point of the threshold because of the rather abrupt change that exceeding
the threshold introduces.  This depends on the input data and especially the
ratio of course.

The third one avoids that by giving smooth values instead.  These come at the
price of higher computational comlexity (a tanhf in addition to the switching
plus scaling around a bit).


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




More information about the Gstreamer-bugs mailing list