|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object be.hogent.tarsos.dsp.util.FFT
public final class FFT
Wrapper for calling a hopefully Fast Fourier transform. Makes it easy to switch FFT algorithm with minimal overhead.
Constructor Summary | |
---|---|
FFT(int size)
|
Method Summary | |
---|---|
void |
backwardsTransform(float[] data)
Computes inverse DFT. |
double |
binToHz(int binIndex,
float sampleRate)
|
void |
forwardTransform(float[] data)
Computes forward DFT. |
void |
modulus(float[] data,
float[] amplitudes)
Calculates the the modulus for each element in data and stores the result in amplitudes. |
float |
modulus(float[] data,
int index)
Returns the modulus of the element at index bufferCount. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FFT(int size)
Method Detail |
---|
public void forwardTransform(float[] data)
data
- data to transform.public void backwardsTransform(float[] data)
data
- data to transformpublic double binToHz(int binIndex, float sampleRate)
public float modulus(float[] data, int index)
data
- The FFT transformed data.index
- The index of the element.
public void modulus(float[] data, float[] amplitudes)
data
- The input data.amplitudes
- The output modulus info or amplitude.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |