1 /* -*- c-basic-offset: 2 -*-
4 * Copyright (C) 1999-2001 Erik Walthinsen <omega@cse.ogi.edu>
5 * 2006 Dreamlab Technologies Ltd. <mathis.hofer@dreamlab.net>
6 * 2007-2009 Sebastian Dröge <sebastian.droege@collabora.co.uk>
8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Library General Public
10 * License as published by the Free Software Foundation; either
11 * version 2 of the License, or (at your option) any later version.
13 * This library is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 * Library General Public License for more details.
18 * You should have received a copy of the GNU Library General Public
19 * License along with this library; if not, write to the
20 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
21 * Boston, MA 02111-1307, USA.
24 * this windowed sinc filter is taken from the freely downloadable DSP book,
25 * "The Scientist and Engineer's Guide to Digital Signal Processing",
27 * available at http://www.dspguide.com/
31 #ifndef __GST_AUDIO_WSINC_BAND_H__
32 #define __GST_AUDIO_WSINC_BAND_H__
35 #include <gst/audio/gstaudiofilter.h>
37 #include "audiofxbasefirfilter.h"
41 #define GST_TYPE_AUDIO_WSINC_BAND \
42 (gst_audio_wsincband_get_type())
43 #define GST_AUDIO_WSINC_BAND(obj) \
44 (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_AUDIO_WSINC_BAND,GstAudioWSincBand))
45 #define GST_AUDIO_WSINC_BAND_CLASS(klass) \
46 (G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_AUDIO_WSINC_BAND,GstAudioWSincBandClass))
47 #define GST_IS_AUDIO_WSINC_BAND(obj) \
48 (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_AUDIO_WSINC_BAND))
49 #define GST_IS_AUDIO_WSINC_BAND_CLASS(klass) \
50 (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_AUDIO_WSINC_BAND))
52 typedef struct _GstAudioWSincBand GstAudioWSincBand;
53 typedef struct _GstAudioWSincBandClass GstAudioWSincBandClass;
58 * Opaque data structure.
60 struct _GstAudioWSincBand {
61 GstAudioFXBaseFIRFilter parent;
65 gfloat lower_frequency, upper_frequency;
66 gint kernel_length; /* length of the filter kernel */
72 struct _GstAudioWSincBandClass {
73 GstAudioFilterClass parent;
76 GType gst_audio_wsincband_get_type (void);
80 #endif /* __GST_AUDIO_WSINC_BAND_H__ */