Build with this node

Start with a prompt in Studio, or copy it into your own coding agent.

Ask Studio

@maruaudio/dsp/dynamics/stereo-transient-shaper ports Gin's full-band TransientShaper (after MGA TranShaper). A mid/side detector max(|M·wM|, |S·wS|) + 1e−5 feeds one-pole amplitude envelopes at 10, 100 and 1 Hz, each read through a square root. The gain (att/env)^attack · (rel/env)^sustain (ratios at least 1) is smoothed, capped at the target and at 64, and applied to mid and side with the processing balance as exponents. All arithmetic is f32.

Parameters

Each setter replaces a non-finite value with the default, clamps and rounds to f32.

SetterRange the setter enforcesDefaultUnit
setStereoTransientShaperAttack−4 to 4; positive sharpens attacks0exponent
setStereoTransientShaperSustain−8 to 8; positive lengthens sustain0exponent
…DetectorBalance / …ProcessBalance0 (mid) to 1 (side); 0.5 both0.5 / 0.5balance
setStereoTransientShaperSmoothing0 (10 kHz) to 1 (0.1 Hz) gain smoother0.5normalized
setStereoTransientShaperOutputDb−60 to +240dB

Lifecycle

initStereoTransientShaper(sampleRate) (8 to 384 kHz, NaN gives 48 kHz) → setters → stereoTransientShaperTick(state, left, right) → resetStereoTransientShaper, which clears envelopes, gain and outputs and keeps the controls. The gain starts at zero after init and reset, as in Gin, so audio ramps in through the smoother. There is no prepare step.

When to use it

Bringing the hit of a drum loop forward or pushing it back, or shortening and lengthening room tails, on a stereo source without a threshold to set.

Limits

  • Stereo, no lookahead or latency; Gin's optional band split is not included.
  • Each lane is bounded to ±1,000,000 (non-finite read as 0). The 1e−5 detector floor matters at very quiet levels.

Algorithm properties and proofs

No Lean 4 proof is mapped to this node.

Explore proofs alongside performance

Parameters

ParameterTypeSetter
Stereo transient shaper attack stereoTransientShaperAttack

Set signed transient attack shaping. Positive values sharpen attacks.

floatsetStereoTransientShaperAttack
Stereo transient shaper sustain stereoTransientShaperSustain

Set signed tail shaping. Positive values lengthen sustain.

floatsetStereoTransientShaperSustain
Stereo transient shaper detector balance stereoTransientShaperDetectorBalance

0 selects Mid, 0.5 listens to both, and 1 selects Side detection.

floatsetStereoTransientShaperDetectorBalance
Stereo transient shaper process balance stereoTransientShaperProcessBalance

0 applies to Mid, 0.5 to both, and 1 applies to Side processing.

floatsetStereoTransientShaperProcessBalance
Stereo transient shaper smoothing stereoTransientShaperSmoothing

Gin's 0 (10 kHz) through 1 (0.1 Hz) gain-smoothing curve.

floatsetStereoTransientShaperSmoothing
Stereo transient shaper output db stereoTransientShaperOutputDb

Bounded output trim for the portable public leaf; product defaults to 0 dB.

floatsetStereoTransientShaperOutputDb

Dependencies

Dependents

Used by