Skip to content
Русский

The [spectrum] table

The spectrum system is the one whose figure is the analysis rather than a generator’s geometry, so what it draws is chosen structurally rather than through [params]:

system = "spectrum"
[spectrum]
elements = 26 # 2..=64, default 24
layout = "bars" # bars | polyline | radial_ring
smoothing = { attack = 0.025, release = 0.22 } # seconds; default: instant
KeyValuesNotes
elementsinteger 2..=64How many elements the frequency axis is divided into. Default 24.
layoutbars, polyline, radial_ringDefault bars.
smoothingseconds, or { attack, release }Per-element easing, in the same vocabulary as [smoothing].

Every key is optional and so is the table itself. An out-of-range elements or an unknown layout is a surfaced load error naming what it expected, like every other structural table — never a silent fallback.

Element 0 is the bottom of the spectrum and the last is the top, so no expression maps audio to position; that mapping is the scene. Three things follow that are worth knowing before you tune one:

  • 64 is the ceiling because 64 is the data. The engine analyses 64 log-spaced bands and the scene averages each element’s own contiguous slice of them — a real partition, nothing dropped or double-counted. A readout finer than its own data would be a lie rather than a feature.
  • The axis is only half logarithmic, and the low end is the coarse end. Band edges follow a log curve, but each band is floored at one FFT bin (23.4 Hz at 48 kHz), which binds all the way up to ~750 Hz — so the bottom 31 of the 64 bands are linear. Element 0 therefore covers about an octave while an element near the middle of the figure covers a semitone or two. This is the opposite of what a log axis suggests, and it is the same caveat bin(x) carries — the measured mapping is tabulated there.
  • smoothing here is the one easing an expression cannot reach. The element levels are scene state computed from the band array, not a binding, so [smoothing] has no name to attach to them. Asymmetric values earn their keep: the bands are the rawest signal in the engine, so a fast attack keeps a transient’s shape while a slow release lets the elements fall like a meter instead of strobing on every analysis hop. It eases the level after the curve param has shaped it — the value you see — so a release means the same duration whatever curve is set to (ADR-0040).

This is also the one system that reads per-element bindings: a [params] expression naming index is evaluated once for each element, so the relationship between a frequency region and what is drawn there is preset content rather than scene code.

Full parameter notes are in Parameter roster, including which composite controls this system honors, the layout-specific parameters (radius on the ring; span and baseline on bars/polyline), and the curve↔scale retune a level curve costs — a 5.8x amplitude change at curve = 0.5 against measured typical band levels, which is the reason the default is exactly linear.

Built from 13c7582 at version 0.158.0. This site tracks main and is not versioned per release.