diff options
author | Sebastian Dröge <slomo@circular-chaos.org> | 2007-08-09 18:08:05 +0000 |
---|---|---|
committer | Sebastian Dröge <slomo@circular-chaos.org> | 2007-08-09 18:08:05 +0000 |
commit | de3d1d62ab4f5d2078526ccaeb3d0db76ba35721 (patch) | |
tree | db6a8b74ab88a599994de878704a0667d5814351 /gst/audiofx/audiowsinclimit.h | |
parent | 488e0e236802311e94f39e6c07e2e9b46834403e (diff) |
gst/filter/gstlpwsinc.*: Add double support, replace "this" with "self" as the former is a C++ keyword.
Original commit message from CVS:
* gst/filter/gstlpwsinc.c: (gst_lpwsinc_dispose),
(gst_lpwsinc_class_init), (gst_lpwsinc_init), (process_32),
(process_64), (lpwsinc_build_kernel), (lpwsinc_setup),
(lpwsinc_get_unit_size), (lpwsinc_transform),
(lpwsinc_set_property), (lpwsinc_get_property):
* gst/filter/gstlpwsinc.h:
Add double support, replace "this" with "self" as the former
is a C++ keyword.
Implement the frequency property in Hz instead of fraction
of sampling frequency.
Remove some unecessary FIXMEs and add some TODOs, add some
required locking and refactor the kernel generation into a
separate function that is also called when the properties
change now.
And use BaseTransform::transform instead of transform_ip
as the convolution is done out of place anyway. Should
be done in place later.
Diffstat (limited to 'gst/audiofx/audiowsinclimit.h')
-rw-r--r-- | gst/audiofx/audiowsinclimit.h | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/gst/audiofx/audiowsinclimit.h b/gst/audiofx/audiowsinclimit.h index 14791b51..afb7e9c7 100644 --- a/gst/audiofx/audiowsinclimit.h +++ b/gst/audiofx/audiowsinclimit.h @@ -54,6 +54,8 @@ G_BEGIN_DECLS typedef struct _GstLPWSinc GstLPWSinc; typedef struct _GstLPWSincClass GstLPWSincClass; +typedef void (*GstLPWSincProcessFunc) (GstLPWSinc *, guint8 *, guint8 *, guint); + /** * GstLPWSinc: * @@ -62,14 +64,15 @@ typedef struct _GstLPWSincClass GstLPWSincClass; struct _GstLPWSinc { GstAudioFilter element; - void (*process)(GstLPWSinc*, gpointer, gint); + GstLPWSincProcessFunc process; - double frequency; - int wing_size; /* length of a "wing" of the filter; + gdouble frequency; + gint wing_size; /* length of a "wing" of the filter; actual length is 2 * wing_size + 1 */ - gfloat *residue; /* buffer for left-over samples from previous buffer */ - double *kernel; + gdouble *residue; /* buffer for left-over samples from previous buffer */ + gdouble *kernel; /* filter kernel */ + gboolean have_kernel; }; struct _GstLPWSincClass { |