Expand description
Platform-independent, real-time-safe audio DSP primitives and graph.
Structs§
- Audio
Graph - Clip chain -> track bus -> master bus graph with deterministic latency aggregation.
- Audio
Graph State - Complete graph history captured between offline chunks.
- Automated
Gain - Sample-accurate gain driven by an immutable automation curve.
- Automation
Curve - Immutable piecewise-linear automation prepared off the realtime thread.
- Automation
Point - One sample-addressed automation point.
- Biquad
- Two-channel transposed-direct-form-II biquad.
- Chain
State Error - Where a
ProcessorChainrefused a saved state, and why. The chain is left as it was. - Compressor
- Linked-channel compressor with deterministic lookahead and soft attack/release.
- Ducker
- Sidechain ducker. Inputs are program channels followed by matching sidechain channels.
- Envelope
Follower - Reusable peak envelope follower.
- Equal
Power Crossfade - Equal-power crossfade between two planar input buses.
- Gain
- Stateless linear amplitude multiplier.
- Interpolator
- The band-limited interpolation a clip played at another speed reads its
source through: the same Kaiser-windowed sinc as
Resampler(16 taps a side at unity, cutoff 0.97 of the Nyquist frequency, beta 9), at any real source position. Played faster than unity, the cutoff falls to the output’s Nyquist frequency and the filter widens in proportion, as a falling rate does, so what the speed raises past the output’s Nyquist frequency is removed rather than folded back. Slower, the source’s Nyquist frequency bounds it, so no image of the source’s spectrum is heard. - Linear
Fade - Sample-addressed linear fade independent of host block size.
- Loudness
Meter - A streaming BS.1770-4 / EBU R128 loudness meter.
- Loudness
Normalization - A static gain that brings a measured mix to a loudness target without letting its true peak exceed a ceiling, or its sample peak reach a master limiter after it.
- Loudness
Report - What a
LoudnessMeterhas measured. - Peak
Limiter - Linked-channel peak limiter with instantaneous attack and exponential release.
- Process
Ctx - Immutable information for one DSP invocation.
- Processor
Chain - Ordered processor chain with all realtime scratch allocated by
prepare. - Resample
Error - Why a converter could not be made.
- Resampler
- A band-limited converter from one sample rate to another.
- Schroeder
Reverb - Allocation-free prepared Schroeder reverb with four combs and two allpasses.
- State
Blob - Opaque processor state saved outside the real-time process path.
- Time
Stretch Processor - Deterministic two-tap delay-line pitch shifter with a fixed prepared window (20 ms).
- Waveform
- A finished waveform summary: its levels, finest first.
- Waveform
Bucket - The extremes and RMS of one run of samples of one channel.
- Waveform
Level - One zoom level of a
Waveform. - Waveform
Summary - Builds a
Waveformfrom planar samples streamed in blocks.
Enums§
- Biquad
Kind - Common parametric equalizer shapes.
- Chain
Error - Why a
ProcessorChainrefuses a processor. - Channel
Layout - Validated channel organization used at every host boundary.
- Fade
Direction - Direction of a linear amplitude fade.
- Graph
State Error - Where an
AudioGraphrefused a saved state, and why. The graph is left as it was. - Loudness
Error - Why a meter cannot be configured or fed.
- State
Error - Why a processor, a
crate::ProcessorChainor ancrate::AudioGraphrefuses a saved state. A refused state changes nothing: what refuses it is left as it was. - Transport
State - Current host transport state supplied without consulting a platform clock.
- Waveform
Error - Why a waveform summary cannot be configured or fed.
Constants§
- ABSOLUTE_
GATE_ LUFS - The level below which a block never counts, in LUFS.
- LIMITER_
MARGIN_ DB - How far below a master limiter’s threshold a normalized mix keeps its sample peak, in dB, so the limiter (which acts only on a sample above its threshold) leaves it alone. It covers the rounding of the 32-bit gain and of each sample multiplied by it (a few parts in 10^7, about 2e-6 dB) a thousand times over, and is far below an audible level change.
- MAX_
DOWNSAMPLE_ FACTOR - The most the rate may fall: a source rate at most this many times the target rate. A falling rate widens the filter in proportion (16 taps a side per factor), and past this fall the filter alone would not fit the table. 768 kHz converts down to 94 Hz.
- MAX_
FILTERED_ SPEED - The fastest playback whose filter narrows with its speed. Faster clips
keep this filter, so one output sample weighs at most
2 * HALF_TAPS * MAX_FILTERED_SPEEDsource samples. - MAX_
FREQUENCY_ FRACTION - Highest frequency a filter renders, as a fraction of the sample rate.
- MAX_
PEAKING_ GAIN_ DB - Largest peaking gain a filter renders, in decibels either way.
- MAX_
RATIO - Largest ratio a compressor renders.
- MAX_
RESAMPLE_ RATE - The highest rate either side may have.
- MAX_
WAVEFORM_ LEVELS - Most zoom levels: a 1-sample base reaches 4^15 samples, over six hours at 48 kHz, which is coarser than any timeline shows.
- MIN_
FREQUENCY_ HZ - Lowest frequency a filter renders, in hertz.
- Q_RANGE
- The resonances a filter renders.
Traits§
- Processor
- Stateful DSP unit whose process method performs no allocation or locking.