fft: fix headers

More fft structure into .c file
indent headers
This commit is contained in:
Wim Taymans 2011-11-11 18:23:22 +01:00
parent b645287775
commit 40be2eec9f
8 changed files with 58 additions and 93 deletions

View file

@ -57,6 +57,13 @@
* *
*/ */
struct _GstFFTF32
{
void *cfg;
gboolean inverse;
gint len;
};
/** /**
* gst_fft_f32_new: * gst_fft_f32_new:
* @len: Length of the FFT in the time domain * @len: Length of the FFT in the time domain

View file

@ -28,23 +28,6 @@
typedef struct _GstFFTF32 GstFFTF32; typedef struct _GstFFTF32 GstFFTF32;
typedef struct _GstFFTF32Complex GstFFTF32Complex; 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 {
/* <private> */
void * cfg;
gboolean inverse;
gint len;
gpointer _padding[GST_PADDING];
};
/* Copy of kiss_fft_f32_cpx for documentation reasons, /* Copy of kiss_fft_f32_cpx for documentation reasons,
* do NOT change! */ * do NOT change! */
@ -55,7 +38,6 @@ struct _GstFFTF32 {
* *
* Data type for complex numbers composed of * Data type for complex numbers composed of
* 32 bit float. * 32 bit float.
*
*/ */
struct _GstFFTF32Complex struct _GstFFTF32Complex
{ {
@ -64,12 +46,14 @@ struct _GstFFTF32Complex
}; };
/* Functions */ /* 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,
void gst_fft_f32_fft (GstFFTF32 *self, const gfloat *timedata, GstFFTF32Complex *freqdata); GstFFTF32Complex *freqdata);
void gst_fft_f32_inverse_fft (GstFFTF32 *self, const GstFFTF32Complex *freqdata, gfloat *timedata); void gst_fft_f32_inverse_fft (GstFFTF32 *self, const GstFFTF32Complex *freqdata,
void gst_fft_f32_free (GstFFTF32 *self); 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__ */ #endif /* __GST_FFT_F32_H__ */

View file

@ -57,6 +57,13 @@
* *
*/ */
struct _GstFFTF64
{
void *cfg;
gboolean inverse;
gint len;
};
/** /**
* gst_fft_f64_new: * gst_fft_f64_new:
* @len: Length of the FFT in the time domain * @len: Length of the FFT in the time domain

View file

@ -28,23 +28,6 @@
typedef struct _GstFFTF64 GstFFTF64; typedef struct _GstFFTF64 GstFFTF64;
typedef struct _GstFFTF64Complex GstFFTF64Complex; 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 {
/* <private> */
void * cfg;
gboolean inverse;
gint len;
gpointer _padding[GST_PADDING];
};
/* Copy of kiss_fft_f64_cpx for documentation reasons, /* Copy of kiss_fft_f64_cpx for documentation reasons,
* do NOT change! */ * do NOT change! */
@ -55,7 +38,6 @@ struct _GstFFTF64 {
* *
* Data type for complex numbers composed of * Data type for complex numbers composed of
* 64 bit float. * 64 bit float.
*
*/ */
struct _GstFFTF64Complex struct _GstFFTF64Complex
{ {
@ -64,12 +46,14 @@ struct _GstFFTF64Complex
}; };
/* Functions */ /* 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,
void gst_fft_f64_fft (GstFFTF64 *self, const gdouble *timedata, GstFFTF64Complex *freqdata); GstFFTF64Complex *freqdata);
void gst_fft_f64_inverse_fft (GstFFTF64 *self, const GstFFTF64Complex *freqdata, gdouble *timedata); void gst_fft_f64_inverse_fft (GstFFTF64 *self, const GstFFTF64Complex *freqdata,
void gst_fft_f64_free (GstFFTF64 *self); 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__ */ #endif /* __GST_FFT_F64_H__ */

View file

@ -54,9 +54,16 @@
* The relation between them is iFFT (FFT (x)) = x / nfft where nfft is the * 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 * length of the FFT. This also has to be taken into account when calculation
* the magnitude of the frequency data. * the magnitude of the frequency data.
* *
*/ */
struct _GstFFTS16
{
void *cfg;
gboolean inverse;
gint len;
};
/** /**
* gst_fft_s16_new: * gst_fft_s16_new:
* @len: Length of the FFT in the time domain * @len: Length of the FFT in the time domain

View file

@ -28,23 +28,6 @@
typedef struct _GstFFTS16 GstFFTS16; typedef struct _GstFFTS16 GstFFTS16;
typedef struct _GstFFTS16Complex GstFFTS16Complex; 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 {
/* <private> */
void *cfg;
gboolean inverse;
gint len;
gpointer _padding[GST_PADDING];
};
/* Copy of kiss_fft_s16_cpx for documentation reasons, /* Copy of kiss_fft_s16_cpx for documentation reasons,
* do NOT change! */ * do NOT change! */
@ -55,7 +38,6 @@ struct _GstFFTS16 {
* *
* Data type for complex numbers composed of * Data type for complex numbers composed of
* signed 16 bit integers. * signed 16 bit integers.
*
*/ */
struct _GstFFTS16Complex struct _GstFFTS16Complex
{ {
@ -64,11 +46,14 @@ struct _GstFFTS16Complex
}; };
/* Functions */ /* 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,
void gst_fft_s16_fft (GstFFTS16 *self, const gint16 *timedata, GstFFTS16Complex *freqdata); GstFFTS16Complex *freqdata);
void gst_fft_s16_inverse_fft (GstFFTS16 *self, const GstFFTS16Complex *freqdata, gint16 *timedata); void gst_fft_s16_inverse_fft (GstFFTS16 *self, const GstFFTS16Complex *freqdata,
void gst_fft_s16_free (GstFFTS16 *self); 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__ */ #endif /* __GST_FFT_S16_H__ */

View file

@ -56,6 +56,13 @@
* the magnitude of the frequency data. * the magnitude of the frequency data.
*/ */
struct _GstFFTS32
{
void *cfg;
gboolean inverse;
gint len;
};
/** /**
* gst_fft_s32_new: * gst_fft_s32_new:
* @len: Length of the FFT in the time domain * @len: Length of the FFT in the time domain

View file

@ -28,23 +28,6 @@
typedef struct _GstFFTS32 GstFFTS32; typedef struct _GstFFTS32 GstFFTS32;
typedef struct _GstFFTS32Complex GstFFTS32Complex; 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 {
/* <private> */
void * cfg;
gboolean inverse;
gint len;
gpointer _padding[GST_PADDING];
};
/* Copy of kiss_fft_s32_cpx for documentation reasons, /* Copy of kiss_fft_s32_cpx for documentation reasons,
* do NOT change! */ * do NOT change! */
@ -55,7 +38,6 @@ struct _GstFFTS32 {
* *
* Data type for complex numbers composed of * Data type for complex numbers composed of
* signed 32 bit integers. * signed 32 bit integers.
*
*/ */
struct _GstFFTS32Complex struct _GstFFTS32Complex
{ {
@ -64,12 +46,14 @@ struct _GstFFTS32Complex
}; };
/* Functions */ /* 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,
void gst_fft_s32_fft (GstFFTS32 *self, const gint32 *timedata, GstFFTS32Complex *freqdata); GstFFTS32Complex *freqdata);
void gst_fft_s32_inverse_fft (GstFFTS32 *self, const GstFFTS32Complex *freqdata, gint32 *timedata); void gst_fft_s32_inverse_fft (GstFFTS32 *self, const GstFFTS32Complex *freqdata,
void gst_fft_s32_free (GstFFTS32 *self); 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__ */ #endif /* __GST_FFT_S32_H__ */