From 40be2eec9fb02579b5e881a0dfd79598808b57a9 Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Fri, 11 Nov 2011 18:23:22 +0100 Subject: [PATCH] fft: fix headers More fft structure into .c file indent headers --- gst-libs/gst/fft/gstfftf32.c | 7 +++++++ gst-libs/gst/fft/gstfftf32.h | 30 +++++++----------------------- gst-libs/gst/fft/gstfftf64.c | 7 +++++++ gst-libs/gst/fft/gstfftf64.h | 30 +++++++----------------------- gst-libs/gst/fft/gstffts16.c | 9 ++++++++- gst-libs/gst/fft/gstffts16.h | 31 ++++++++----------------------- gst-libs/gst/fft/gstffts32.c | 7 +++++++ gst-libs/gst/fft/gstffts32.h | 30 +++++++----------------------- 8 files changed, 58 insertions(+), 93 deletions(-) diff --git a/gst-libs/gst/fft/gstfftf32.c b/gst-libs/gst/fft/gstfftf32.c index fd574e0b1c..8c93dec26b 100644 --- a/gst-libs/gst/fft/gstfftf32.c +++ b/gst-libs/gst/fft/gstfftf32.c @@ -57,6 +57,13 @@ * */ +struct _GstFFTF32 +{ + void *cfg; + gboolean inverse; + gint len; +}; + /** * gst_fft_f32_new: * @len: Length of the FFT in the time domain diff --git a/gst-libs/gst/fft/gstfftf32.h b/gst-libs/gst/fft/gstfftf32.h index 3b56b48394..fcd31748a7 100644 --- a/gst-libs/gst/fft/gstfftf32.h +++ b/gst-libs/gst/fft/gstfftf32.h @@ -28,23 +28,6 @@ typedef struct _GstFFTF32 GstFFTF32; typedef struct _GstFFTF32Complex GstFFTF32Complex; -/* FIXME 0.11: Move the struct definition to the sources, - * there's no reason to have it public. - */ -/** - * GstFFTF32: - * - * Instance structure for #GstFFTF32. - * - */ -struct _GstFFTF32 { - /* */ - void * cfg; - gboolean inverse; - gint len; - gpointer _padding[GST_PADDING]; -}; - /* Copy of kiss_fft_f32_cpx for documentation reasons, * do NOT change! */ @@ -55,7 +38,6 @@ struct _GstFFTF32 { * * Data type for complex numbers composed of * 32 bit float. - * */ struct _GstFFTF32Complex { @@ -64,12 +46,14 @@ struct _GstFFTF32Complex }; /* Functions */ +GstFFTF32 * gst_fft_f32_new (gint len, gboolean inverse); +void gst_fft_f32_free (GstFFTF32 *self); -GstFFTF32 * gst_fft_f32_new (gint len, gboolean inverse); -void gst_fft_f32_fft (GstFFTF32 *self, const gfloat *timedata, GstFFTF32Complex *freqdata); -void gst_fft_f32_inverse_fft (GstFFTF32 *self, const GstFFTF32Complex *freqdata, gfloat *timedata); -void gst_fft_f32_free (GstFFTF32 *self); +void gst_fft_f32_fft (GstFFTF32 *self, const gfloat *timedata, + GstFFTF32Complex *freqdata); +void gst_fft_f32_inverse_fft (GstFFTF32 *self, const GstFFTF32Complex *freqdata, + gfloat *timedata); -void gst_fft_f32_window (GstFFTF32 *self, gfloat *timedata, GstFFTWindow window); +void gst_fft_f32_window (GstFFTF32 *self, gfloat *timedata, GstFFTWindow window); #endif /* __GST_FFT_F32_H__ */ diff --git a/gst-libs/gst/fft/gstfftf64.c b/gst-libs/gst/fft/gstfftf64.c index e737854be9..520788d000 100644 --- a/gst-libs/gst/fft/gstfftf64.c +++ b/gst-libs/gst/fft/gstfftf64.c @@ -57,6 +57,13 @@ * */ +struct _GstFFTF64 +{ + void *cfg; + gboolean inverse; + gint len; +}; + /** * gst_fft_f64_new: * @len: Length of the FFT in the time domain diff --git a/gst-libs/gst/fft/gstfftf64.h b/gst-libs/gst/fft/gstfftf64.h index 8ebbee49ab..7bb42cae3b 100644 --- a/gst-libs/gst/fft/gstfftf64.h +++ b/gst-libs/gst/fft/gstfftf64.h @@ -28,23 +28,6 @@ typedef struct _GstFFTF64 GstFFTF64; typedef struct _GstFFTF64Complex GstFFTF64Complex; -/* FIXME 0.11: Move the struct definition to the sources, - * there's no reason to have it public. - */ -/** - * GstFFTF64: - * - * Instance structure for #GstFFTF64. - * - */ -struct _GstFFTF64 { - /* */ - void * cfg; - gboolean inverse; - gint len; - gpointer _padding[GST_PADDING]; -}; - /* Copy of kiss_fft_f64_cpx for documentation reasons, * do NOT change! */ @@ -55,7 +38,6 @@ struct _GstFFTF64 { * * Data type for complex numbers composed of * 64 bit float. - * */ struct _GstFFTF64Complex { @@ -64,12 +46,14 @@ struct _GstFFTF64Complex }; /* Functions */ +GstFFTF64 * gst_fft_f64_new (gint len, gboolean inverse); +void gst_fft_f64_free (GstFFTF64 *self); -GstFFTF64 * gst_fft_f64_new (gint len, gboolean inverse); -void gst_fft_f64_fft (GstFFTF64 *self, const gdouble *timedata, GstFFTF64Complex *freqdata); -void gst_fft_f64_inverse_fft (GstFFTF64 *self, const GstFFTF64Complex *freqdata, gdouble *timedata); -void gst_fft_f64_free (GstFFTF64 *self); +void gst_fft_f64_fft (GstFFTF64 *self, const gdouble *timedata, + GstFFTF64Complex *freqdata); +void gst_fft_f64_inverse_fft (GstFFTF64 *self, const GstFFTF64Complex *freqdata, + gdouble *timedata); -void gst_fft_f64_window (GstFFTF64 *self, gdouble *timedata, GstFFTWindow window); +void gst_fft_f64_window (GstFFTF64 *self, gdouble *timedata, GstFFTWindow window); #endif /* __GST_FFT_F64_H__ */ diff --git a/gst-libs/gst/fft/gstffts16.c b/gst-libs/gst/fft/gstffts16.c index 212e93f1d5..729e354229 100644 --- a/gst-libs/gst/fft/gstffts16.c +++ b/gst-libs/gst/fft/gstffts16.c @@ -54,9 +54,16 @@ * The relation between them is iFFT (FFT (x)) = x / nfft where nfft is the * length of the FFT. This also has to be taken into account when calculation * the magnitude of the frequency data. - * + * */ +struct _GstFFTS16 +{ + void *cfg; + gboolean inverse; + gint len; +}; + /** * gst_fft_s16_new: * @len: Length of the FFT in the time domain diff --git a/gst-libs/gst/fft/gstffts16.h b/gst-libs/gst/fft/gstffts16.h index 9a752f1ffd..30cbdeea89 100644 --- a/gst-libs/gst/fft/gstffts16.h +++ b/gst-libs/gst/fft/gstffts16.h @@ -28,23 +28,6 @@ typedef struct _GstFFTS16 GstFFTS16; typedef struct _GstFFTS16Complex GstFFTS16Complex; -/* FIXME 0.11: Move the struct definition to the sources, - * there's no reason to have it public. - */ -/** - * GstFFTS16: - * - * Instance structure for #GstFFTS16. - * - */ -struct _GstFFTS16 { - /* */ - void *cfg; - gboolean inverse; - gint len; - gpointer _padding[GST_PADDING]; -}; - /* Copy of kiss_fft_s16_cpx for documentation reasons, * do NOT change! */ @@ -55,7 +38,6 @@ struct _GstFFTS16 { * * Data type for complex numbers composed of * signed 16 bit integers. - * */ struct _GstFFTS16Complex { @@ -64,11 +46,14 @@ struct _GstFFTS16Complex }; /* Functions */ +GstFFTS16 * gst_fft_s16_new (gint len, gboolean inverse); +void gst_fft_s16_free (GstFFTS16 *self); -GstFFTS16 * gst_fft_s16_new (gint len, gboolean inverse); -void gst_fft_s16_fft (GstFFTS16 *self, const gint16 *timedata, GstFFTS16Complex *freqdata); -void gst_fft_s16_inverse_fft (GstFFTS16 *self, const GstFFTS16Complex *freqdata, gint16 *timedata); -void gst_fft_s16_free (GstFFTS16 *self); +void gst_fft_s16_fft (GstFFTS16 *self, const gint16 *timedata, + GstFFTS16Complex *freqdata); +void gst_fft_s16_inverse_fft (GstFFTS16 *self, const GstFFTS16Complex *freqdata, + gint16 *timedata); + +void gst_fft_s16_window (GstFFTS16 *self, gint16 *timedata, GstFFTWindow window); -void gst_fft_s16_window (GstFFTS16 *self, gint16 *timedata, GstFFTWindow window); #endif /* __GST_FFT_S16_H__ */ diff --git a/gst-libs/gst/fft/gstffts32.c b/gst-libs/gst/fft/gstffts32.c index 56ea543b84..a135786260 100644 --- a/gst-libs/gst/fft/gstffts32.c +++ b/gst-libs/gst/fft/gstffts32.c @@ -56,6 +56,13 @@ * the magnitude of the frequency data. */ +struct _GstFFTS32 +{ + void *cfg; + gboolean inverse; + gint len; +}; + /** * gst_fft_s32_new: * @len: Length of the FFT in the time domain diff --git a/gst-libs/gst/fft/gstffts32.h b/gst-libs/gst/fft/gstffts32.h index fd3b2798e4..f73ad9609d 100644 --- a/gst-libs/gst/fft/gstffts32.h +++ b/gst-libs/gst/fft/gstffts32.h @@ -28,23 +28,6 @@ typedef struct _GstFFTS32 GstFFTS32; typedef struct _GstFFTS32Complex GstFFTS32Complex; -/* FIXME 0.11: Move the struct definition to the sources, - * there's no reason to have it public. - */ -/** - * GstFFTS32: - * - * Instance structure for #GstFFTS32. - * - */ -struct _GstFFTS32 { - /* */ - void * cfg; - gboolean inverse; - gint len; - gpointer _padding[GST_PADDING]; -}; - /* Copy of kiss_fft_s32_cpx for documentation reasons, * do NOT change! */ @@ -55,7 +38,6 @@ struct _GstFFTS32 { * * Data type for complex numbers composed of * signed 32 bit integers. - * */ struct _GstFFTS32Complex { @@ -64,12 +46,14 @@ struct _GstFFTS32Complex }; /* Functions */ +GstFFTS32 * gst_fft_s32_new (gint len, gboolean inverse); +void gst_fft_s32_free (GstFFTS32 *self); -GstFFTS32 * gst_fft_s32_new (gint len, gboolean inverse); -void gst_fft_s32_fft (GstFFTS32 *self, const gint32 *timedata, GstFFTS32Complex *freqdata); -void gst_fft_s32_inverse_fft (GstFFTS32 *self, const GstFFTS32Complex *freqdata, gint32 *timedata); -void gst_fft_s32_free (GstFFTS32 *self); +void gst_fft_s32_fft (GstFFTS32 *self, const gint32 *timedata, + GstFFTS32Complex *freqdata); +void gst_fft_s32_inverse_fft (GstFFTS32 *self, const GstFFTS32Complex *freqdata, + gint32 *timedata); -void gst_fft_s32_window (GstFFTS32 *self, gint32 *timedata, GstFFTWindow window); +void gst_fft_s32_window (GstFFTS32 *self, gint32 *timedata, GstFFTWindow window); #endif /* __GST_FFT_S32_H__ */