Skip to content

reference loudness

Aisjam edited this page Nov 15, 2026 · 1 revision

Instrument output calibration

Home · Section index

Working manual · 0.0.1-alpha · source snapshot 16 November 2026

All 35 registered oscillator/synth/drum models and the INST sample backend use fixed output trims targeting -3 dBFS peak (0.707945784) at unity instrument gain. This is a reference calibration, not a ceiling or loudness normalizer. Coefficients are compiled in core/audio/InstrumentLoudness.hpp; no analysis, allocation, logarithms or gain calculation is added to the callback.

Calibration multiplies the completed voice output, after its existing envelope, velocity response, filters, drive, saturation and modulation. It precedes mixer summing, dry/send routing and master processing. Polybraids' shared width/chorus is linear: applying its trim before that stage preserves both its sound and the existing per-lane dry/effect distribution. Standalone oscillator/DSP primitives and visual previews are unchanged. No new compressor, limiter or clamp is added.

Existing saved gain codes and formats are unchanged. Synth output 255 remains 0 dB; +/-6 dB remains relative to the calibrated level (within gain-code rounding). Existing songs will therefore play at different relative levels. This intentional audio-level change does not rewrite their patches or gain settings.

Measurement table

Peak is 20 * log10(max(abs(left), abs(right))), measured over the whole render. Reference peaks below are before the new trim. Every calibrated reference measured -3.000 dBFS. The sweep column records observed peaks, not an upper bound.

Engine Original reference dBFS Fixed multiplier Sweep peak dBFS Loudest tested configuration
BASIC -6.021 1.415892 -3.000 C4 default
PWM -6.021 1.415892 -3.000 C4 default
CYCLE -6.021 1.415892 -3.000 wave 3
WAVE -6.021 1.415892 -3.000 C4 default
FM2 -6.021 1.415892 -1.551 variant 2
PHASE -6.021 1.415892 -1.496 variant 2
NOISE -6.021 1.415899 -3.000 C4 default
LFSR -6.021 1.415892 -3.000 C4 default
BUZZ LEGACY -6.021 1.415892 -3.000 C4 default
QUANT -6.021 1.415892 -3.000 C4 default
CHIP -6.021 1.415892 -3.000 C4 default
SYNC -6.021 1.415892 -2.902 wave 1
SUPER -9.351 2.077538 -2.999 wave 3
ADD -10.228 2.298351 -3.000 C4 default
GRAIN -18.084 5.678175 -2.978 note 84
IMPULSE -6.021 1.415892 -3.000 C4 default
LSDW -6.021 1.415892 -3.000 C4 default
LUT -6.021 1.415892 -3.000 wave 3
FM4 -6.021 1.415892 -1.551 variant 2
PULSELINE 101 -7.690 1.715944 -2.726 note 36
ACIDLINE -13.841 3.483861 -1.997 note 36
FRACTURE-20 -10.708 2.428856 1.053 note 36
DRUM -10.495 2.369891 0.794 note 61
MACROBRAIDS -4.622 1.205257 -3.000 C4 default
Drum Eight -10.943 2.495327 1.535 note 61
Drum Six -12.034 2.829566 -1.829 note 62
Drum Seven 0.097 0.700124 -2.973 variant 1
Drum Nine -16.779 4.885897 8.370 note 61
POLYBRAIDS -6.122 1.432493 -2.696 note 36
FRAY -7.876 1.753090 -2.854 variant 2
SPELL -19.740 6.870408 2.493 note 72
Drum Tone -16.004 4.469010 0.766 note 66
Opal-2 -6.021 1.415991 -3.000 C4 default
PZAR -3.593 1.070684 -0.442 variant 1
INST 0.000 0.707946 -3.000 Full-scale mono/stereo PCM

The sweep tests MIDI 36/48/60/72/84, sine/triangle/saw/square selections, three additional configurations per engine, and all MIDI 60-75 drum keys. Variants are factory patches 1-3 for Opal/PZAR, otherwise the first matrix control at one-third/two-thirds/full range. Wave selectors do not affect engines whose dedicated matrix owns their waveforms. This is representative coverage, not an exhaustive search of every parameter combination.

Drum Nine's snare (61), SPELL at C5, Fracture at C2, and several other drum hits exceed 0 dBFS after calibration. This does not clip the floating-point instrument path. Their relative dynamics are deliberately retained; a fixed engine trim cannot both match its default C4 reference and bound every other patch/note. Positive gain and simultaneous voices can also exceed full scale. The existing master/device output remains responsible for final output range; lower the mixer or master level when needed. The legacy standalone VoicePool::render() helper still clamps its final sum; production routing uses the unclamped renderSends().

The audit found existing intentional saturation/quantization in drum, analog, Braids and Fray engines, and existing finite/output guards (including SPELL). Those stages are unchanged and receive exactly the same internal signal as before. The new trim is downstream, so it cannot introduce clipping inside them. No claim is made that all extreme sound-design patches were previously distortion-free.

What should be here

Documentation still to add
Annotated current-build screenshots and a recorded controller walkthrough for this topic.

Evidence and verification

Repository sources used for this page:

  • docs/instrument-loudness.md

This is a documentation/source review, not a new runtime or hardware test. Physical response, screenshots and listening examples still need verification on a recorded build.

Clone this wiki locally