/* FreqSpec.h -*- objc -*- */ #ifndef ELC_FREQSPEC_H #define ELC_FREQSPEC_H #include #include "drfftw.h" @interface FreqSpec : Object { size_t N, n_spectra; rfftw_plan plan; fftw_real *spectrum, *in, *out; BOOL use_hanning; BOOL normalize; float normalize_scale; } + newWithN: (size_t) N; - (void)N: (size_t) n; - analyze; // called internally - shortAnalyze: (short *) samples; - intAnalyze: (int *) samples; - (BOOL) freqs: (fftw_real *) frequencies withBaseFreq: (fftw_real) freq_spacing intoBands: (fftw_real *) bands; - destroy; - use_hanning: (BOOL) yesno; @end #endif