On Sun, 2 Oct 2005, hard off wrote:
it'll cost me dearly in cpu power, but what about using an ftt process ???
FFT = Fast Fourier Transforms make it easy to cut frequencies. Its cost is at least two float multiplications per sample for each pass (if using complex numbers). Each pass doubles the associated block size, so for 64-sample blocks it's 6 passes, and for 1024-sample blocks it's 10 passes.
Sandwiching a pair of *~'s between a fft~ and an ifft~ will allow you to have a 32-band equalizer (or a 512-band equalizer). The number of bands is half the block size because the gains for the negative freqs should be the mirror image of the gains for the positive freqs. Also both *~'s should get the same gain values too.
If you decide to operate in "real mode" instead, then instead of negative vs positive freqs you'll have all positive freqs but with both cosine and sine values. Then again the gain values should be the same on both sides.
If you want it to take the least amount of CPU possible, then don't use a bigger blocksize than necessary, and also don't use Miller's Pd: instead use devel_0_38 or devel_0_39, and make sure the FFTW option is enabled. You will need to download FFTW 3.x if you don't have it already.
Mathieu Bouchard - tél:+1.514.383.3801 - http://artengine.ca/matju Freelance Digital Arts Engineer, Montréal QC Canada