Lines Matching refs:table

86    struct drft_lookup *table;
87 table = speex_alloc(sizeof(struct drft_lookup));
88 spx_drft_init((struct drft_lookup *)table, size);
89 return (void*)table;
92 void spx_fft_destroy(void *table)
94 spx_drft_clear(table);
95 speex_free(table);
98 void spx_fft(void *table, float *in, float *out)
103 float scale = 1./((struct drft_lookup *)table)->n;
105 for (i=0;i<((struct drft_lookup *)table)->n;i++)
109 float scale = 1./((struct drft_lookup *)table)->n;
110 for (i=0;i<((struct drft_lookup *)table)->n;i++)
113 spx_drft_forward((struct drft_lookup *)table, out);
116 void spx_ifft(void *table, float *in, float *out)
123 for (i=0;i<((struct drft_lookup *)table)->n;i++)
126 spx_drft_backward((struct drft_lookup *)table, out);
139 struct mkl_config *table = (struct mkl_config *) speex_alloc(sizeof(struct mkl_config));
140 table->N = size;
141 DftiCreateDescriptor(&table->desc, DFTI_SINGLE, DFTI_REAL, 1, size);
142 DftiSetValue(table->desc, DFTI_PACKED_FORMAT, DFTI_PACK_FORMAT);
143 DftiSetValue(table->desc, DFTI_PLACEMENT, DFTI_NOT_INPLACE);
144 DftiSetValue(table->desc, DFTI_FORWARD_SCALE, 1.0f / size);
145 DftiCommitDescriptor(table->desc);
146 return table;
149 void spx_fft_destroy(void *table)
151 struct mkl_config *t = (struct mkl_config *) table;
153 speex_free(table);
156 void spx_fft(void *table, spx_word16_t *in, spx_word16_t *out)
158 struct mkl_config *t = (struct mkl_config *) table;
162 void spx_ifft(void *table, spx_word16_t *in, spx_word16_t *out)
164 struct mkl_config *t = (struct mkl_config *) table;
182 struct ipp_fft_config *table;
184 table = (struct ipp_fft_config *)speex_alloc(sizeof(struct ipp_fft_config));
191 ippsDFTInitAlloc_R_32f(&table->dftSpec, size, IPP_FFT_DIV_FWD_BY_N, hint);
193 ippsDFTGetBufSize_R_32f(table->dftSpec, &bufferSize);
194 table->buffer = ippsMalloc_8u(bufferSize);
196 return table;
199 void spx_fft_destroy(void *table)
201 struct ipp_fft_config *t = (struct ipp_fft_config *)table;
207 void spx_fft(void *table, spx_word16_t *in, spx_word16_t *out)
209 struct ipp_fft_config *t = (struct ipp_fft_config *)table;
213 void spx_ifft(void *table, spx_word16_t *in, spx_word16_t *out)
215 struct ipp_fft_config *t = (struct ipp_fft_config *)table;
233 struct fftw_config *table = (struct fftw_config *) speex_alloc(sizeof(struct fftw_config));
234 table->in = fftwf_malloc(sizeof(float) * (size+2));
235 table->out = fftwf_malloc(sizeof(float) * (size+2));
237 table->fft = fftwf_plan_dft_r2c_1d(size, table->in, (fftwf_complex *) table->out, FFTW_PATIENT);
238 table->ifft = fftwf_plan_dft_c2r_1d(size, (fftwf_complex *) table->in, table->out, FFTW_PATIENT);
240 table->N = size;
241 return table;
244 void spx_fft_destroy(void *table)
246 struct fftw_config *t = (struct fftw_config *) table;
251 speex_free(table);
255 void spx_fft(void *table, spx_word16_t *in, spx_word16_t *out)
258 struct fftw_config *t = (struct fftw_config *) table;
273 void spx_ifft(void *table, spx_word16_t *in, spx_word16_t *out)
276 struct fftw_config *t = (struct fftw_config *) table;
306 struct kiss_config *table;
307 table = (struct kiss_config*)speex_alloc(sizeof(struct kiss_config));
308 table->forward = kiss_fftr_alloc(size,0,NULL,NULL);
309 table->backward = kiss_fftr_alloc(size,1,NULL,NULL);
310 table->N = size;
311 return table;
314 void spx_fft_destroy(void *table)
316 struct kiss_config *t = (struct kiss_config *)table;
319 speex_free(table);
324 void spx_fft(void *table, spx_word16_t *in, spx_word16_t *out)
327 struct kiss_config *t = (struct kiss_config *)table;
336 void spx_fft(void *table, spx_word16_t *in, spx_word16_t *out)
340 struct kiss_config *t = (struct kiss_config *)table;
348 void spx_ifft(void *table, spx_word16_t *in, spx_word16_t *out)
350 struct kiss_config *t = (struct kiss_config *)table;
366 void spx_fft_float(void *table, float *in, float *out)
370 int N = ((struct drft_lookup *)table)->n;
372 int N = ((struct kiss_config *)table)->N;
384 spx_fft(table, _in, _out);
392 spx_drft_init(&t, ((struct kiss_config *)table)->N);
393 scale = 1./((struct kiss_config *)table)->N;
394 for (i=0;i<((struct kiss_config *)table)->N;i++)
402 void spx_ifft_float(void *table, float *in, float *out)
406 int N = ((struct drft_lookup *)table)->n;
408 int N = ((struct kiss_config *)table)->N;
420 spx_ifft(table, _in, _out);
428 spx_drft_init(&t, ((struct kiss_config *)table)->N);
429 for (i=0;i<((struct kiss_config *)table)->N;i++)
439 void spx_fft_float(void *table, float *in, float *out)
441 spx_fft(table, in, out);
443 void spx_ifft_float(void *table, float *in, float *out)
445 spx_ifft(table, in, out);