SuperCollider's FFT UGens enable real-time spectral processing in the frequency domain
SuperCollider provides a set of phase vocoder UGens (PV_ prefix) that perform real-time FFT analysis, spectral manipulation, and inverse FFT synthesis. The chain is: FFT(buf, signal) → PV_*(buf) chain → IFFT(buf). Processing options include bin-by-bin magnitude and phase operations: PV_MagSmear blurs spectra, PV_BinScramble shuffles bins, PV_Morph crossfades between two spectra, PV_LocalMax extracts peaks. Typical applications are spectral freeze, pitch shifting via bin stretching, convolution, and vocoding. Because FFT blocks data in frames, there is inherent latency equal to the FFT window size divided by sample rate. Choosing window size (512–4096) trades frequency resolution against time resolution.
Examples
b = Buffer.alloc(s, 512);
{IFFT(PV_MagSmear(FFT(b, SoundIn.ar(0)), 1.0))}.play;
Assessment
Build a spectral freeze patch using FFT and PV_Freeze: trigger the freeze on a key press and describe what you hear vs. the original signal. Then chain PV_BinScramble after the freeze and compare.