Skip to main content

fft_radix2

Function fft_radix2 

Source
pub fn fft_radix2(data: &mut [f32], inverse: bool) -> Result<(), AudioError>
Expand description

Forward (inverse == false) or inverse (inverse == true) radix-2 FFT, in place, over interleaved complex samples.

data.len() must equal 2 * N where N is a power of two. The inverse transform is normalised by 1/N, so fft_radix2(x, false) followed by fft_radix2(x, true) reproduces the original x.

Returns AudioError::InvalidParameter if the length is odd, zero, or the implied N is not a power of two.