class
SushiDSP::OutputTransformerStage
Models the output transformer: primary-inductance low-end rolloff, leakage- inductance top-end shaping, an explicit tanh core-saturation waveshaper, and a secondary that carries no mean (docs/archive/superpowers/specs/2026-09-07-grid-knee-antialiasing-design.md section 14).
- Declared in
include/SushiDSP/circuits/stages/OutputTransformerStage.hpp
Public member functions
OutputTransformerStage(double sample_rate, float low_rolloff_hz, float leakage_shelf_hz, float saturation_drive)Parameters
sample_rateThe sample rate in Hz.
low_rolloff_hzThe primary inductance's low-end rolloff corner.
leakage_shelf_hzThe leakage inductance's top-end shaping corner.
saturation_driveControls how hard the core saturates; smaller values saturate at a higher output ceiling.
float process_sample(float input)Processes one sample: rolloff, leakage shaping, core saturation, then the removal of the saturated signal's running mean.
Parameters
inputThe input sample.
Returns
The transformed, saturated output sample. Always finite.
void reset()Clears both filters' state and the secondary's running mean.

