You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

47 lines
858B

  1. #ifndef KISS_FTR_H
  2. #define KISS_FTR_H
  3. #include "kiss_fft.h"
  4. #ifdef __cplusplus
  5. extern "C" {
  6. #endif
  7. /*
  8. Real optimized version can save about 45% cpu time vs. complex fft of a real seq.
  9. */
  10. typedef struct kiss_fftr_state *kiss_fftr_cfg;
  11. kiss_fftr_cfg kiss_fftr_alloc(int nfft,int inverse_fft,void * mem, size_t * lenmem);
  12. /*
  13. nfft must be even
  14. If you don't care to allocate space, use mem = lenmem = NULL
  15. */
  16. void kiss_fftr(kiss_fftr_cfg cfg,const kiss_fft_scalar *timedata,kiss_fft_cpx *freqdata);
  17. /*
  18. input timedata has nfft scalar points
  19. output freqdata has nfft/2+1 complex points
  20. */
  21. void kiss_fftri(kiss_fftr_cfg cfg,const kiss_fft_cpx *freqdata,kiss_fft_scalar *timedata);
  22. /*
  23. input freqdata has nfft/2+1 complex points
  24. output timedata has nfft scalar points
  25. */
  26. #define kiss_fftr_free free
  27. #ifdef __cplusplus
  28. }
  29. #endif
  30. #endif