[Flashcoders] Why 512?

2007-06-17 Thread sean
Someone asked me the other day, why the Sound class function computeSpectrum() returns specifically 512 floating point values. I know it returns 256 values for the left and right channels and that each value is a 32-bit floating point value of 4 bytes, but despite alot of Googling, I could find

Re: [Flashcoders] Why 512?

2007-06-17 Thread Glen Pike
It's quicker to do an FFT with a length that is a power of 2 Can't remember exactly why, but I think the algorithm keeps splitting the array into 2 for each iteration of the calculation... Have a look on Google. [EMAIL PROTECTED] wrote: Someone asked me the other day, why the Sound class

Re: [Flashcoders] Why 512?

2007-06-17 Thread Glen Pike
Ha, found it... http://www.dspguide.com/ch12.htm It is a while since I read this, but it hurt trying understand it a few times, then I got it, then I promptly forgot about it because I was using public domain code... Glen [EMAIL PROTECTED] wrote: Someone asked me the other day,