audiowsinclimit

audiowsinclimit — Low pass and high pass windowed sinc filter

Synopsis

struct              GstAudioWSincLimit;

Object Hierarchy

  GObject
   +----GInitiallyUnowned
         +----GstObject
               +----GstElement
                     +----GstBaseTransform
                           +----GstAudioFilter
                                 +----GstAudioFXBaseFIRFilter
                                       +----GstAudioWSincLimit

Properties

  "frequency"                gdouble               : Read / Write
  "length"                   gint                  : Read / Write
  "mode"                     GstAudioWSincLimitMode  : Read / Write
  "window"                   GstAudioWSincLimitWindow  : Read / Write
  "cutoff"                   gfloat                : Read / Write

Description

Attenuates all frequencies above the cutoff frequency (low-pass) or all frequencies below the cutoff frequency (high-pass). The length parameter controls the rolloff, the window parameter controls rolloff and stopband attenuation. The Hamming window provides a faster rolloff but a bit worse stopband attenuation, the other way around for the Blackman window.

This element has the advantage over the Chebyshev lowpass and highpass filter that it has a much better rolloff when using a larger kernel size and almost linear phase. The only disadvantage is the much slower execution time with larger kernels.

Example launch line

1
2
3
gst-launch-1.0 audiotestsrc freq=1500 ! audioconvert ! audiowsinclimit mode=low-pass cutoff=1000 length=501 ! audioconvert ! alsasink
gst-launch-1.0 filesrc location="melo1.ogg" ! oggdemux ! vorbisdec ! audioconvert ! audiowsinclimit mode=high-pass cutoff=15000 length=501 ! audioconvert ! alsasink
gst-launch-1.0 audiotestsrc wave=white-noise ! audioconvert ! audiowsinclimit mode=low-pass cutoff=1000 length=10001 window=blackman ! audioconvert ! alsasink

Synopsis

Element Information

plugin

audiofx

author

Thomas Vander Stichele <thomas at apestaart dot org>, Steven W. Smith, Dreamlab Technologies Ltd. <mathis.hofer@dreamlab.net>, Sebastian Dröge <sebastian.droege@collabora.co.uk>

class

Filter/Effect/Audio

Element Pads

name

sink

direction

sink

presence

always

details

audio/x-raw, format=(string){ F32LE, F64LE }, rate=(int)[ 1, 2147483647 ], channels=(int)[ 1, 2147483647 ], layout=(string)interleaved

name

src

direction

source

presence

always

details

audio/x-raw, format=(string){ F32LE, F64LE }, rate=(int)[ 1, 2147483647 ], channels=(int)[ 1, 2147483647 ], layout=(string)interleaved

Details

struct GstAudioWSincLimit

struct GstAudioWSincLimit;

Opaque data structure.

Property Details

The "frequency" property

  "frequency"                gdouble               : Read / Write

Cut-off Frequency (Hz).

Allowed values: >= 0

Default value: 0


The "length" property

  "length"                   gint                  : Read / Write

Filter kernel length, will be rounded to the next odd number.

Allowed values: [3,256000]

Default value: 101


The "mode" property

  "mode"                     GstAudioWSincLimitMode  : Read / Write

Low pass or high pass mode.

Default value: Low pass (default)


The "window" property

  "window"                   GstAudioWSincLimitWindow  : Read / Write

Window function to use.

Default value: Hamming window (default)


The "cutoff" property

  "cutoff"                   gfloat                : Read / Write

Cut-off Frequency (Hz).

Allowed values: [0,100000]

Default value: 0