1 #ifndef __ComplexFourierTransform_h__
2 #define __ComplexFourierTransform_h__
7 #include "arm_const_structs.h"
11 arm_cfft_instance_f32 instance;
18 ASSERT(len==32 || len ==64 || len==128 || len==256 || len==512 || len==1024 || len==2048 || len==4096,
"Unsupported FFT size");
19 void* args[] = {(
void*)&instance, (
void*)&len};
20 getProgramVector()->serviceCall(OWL_SERVICE_ARM_CFFT_INIT_F32, args, 2);
25 arm_cfft_f32(&instance, (
float*)inout.
getData(), 0, 1);
29 arm_cfft_f32(&instance, (
float*)inout.
getData(), 1, 1);
32 return instance.fftLen;
53 ASSERT(len==32 || len ==64 || len==128 || len==256 || len==512 || len==1024 || len==2048 || len==4096,
"Unsupported FFT size");
54 cfgfft = kiss_fft_alloc(len, 0 , 0, 0);
55 cfgifft = kiss_fft_alloc(len, 1,0, 0);
60 kiss_fft(cfgfft, (kiss_fft_cpx*)(
float*)inout.
getData(), (kiss_fft_cpx*)(
float*)temp.
getData());
65 kiss_fft(cfgifft, (kiss_fft_cpx*)(
float*)inout.
getData(), (kiss_fft_cpx*)(
float*)temp.
getData());
static void destroy(ComplexFloatArray)
Destroys a ComplexFloatArray created with the create() method.
void scale(float factor)
Array by scalar multiplication.
static ComplexFloatArray create(size_t size)
Creates a new ComplexFloatArray.
void copyFrom(FloatArray real, FloatArray imag)
Merge two channels of audio containing real and imaginary axis data into this array.
T * getData()
Get the data stored in the Array.
#define ASSERT(cond, msg)