Cortix - Perceptual Audio Spectrum Analyser
A high-performance, perceptually-accurate spectrum analysis library featuring Gammatone filterbanks, multiple frequency scales (Bark, ERB, Mel), and real-time processing capabilities.
Named after the Organ of Corti - the biological spectrum analyser in the cochlea where sound is converted to neural signals.
Quick Start
use ;
// Create analyser with builder pattern
let mut analyser = builder
.sample_rate
.bands
.scale
.build;
// Process audio and get envelope
let audio = vec!;
let envelope = analyser.process;
// Get dB values
let db = analyser.envelope_db;
Features
- Gammatone Filterbank - Auditory model with true frequency resolution
- Multiple Scales - Bark, ERB, Mel, Log, and Linear frequency spacing
- Real-time Performance - Sub-millisecond latency, efficient per-sample processing
- Perceptually Accurate - Based on auditory neuroscience research
Frequency Scales
| Scale | Description | Use Case |
|---|---|---|
| Linear | Uniform Hz spacing | Scientific analysis |
| Log | Logarithmic (octaves) | Music, harmonics |
| Bark | Critical bands | Masking, loudness |
| ERB | Equivalent rectangular bandwidth | Auditory models |
| Mel | Pitch perception | Speech recognition |