Controllable Switch 2 In is a control-selected audio switch that routes one of two audio inputs to a single output. A Channel control input chooses which input is passed through, so the selection can be automated from any control source. An output-gain parameter (-60dB..+30dB) trims the level and a leakiness parameter (0..max) bleeds a proportion of the non-selected input into the output for a crossfade rather than a hard switch; separate Mute and Stereo ganged toggles are also provided, with independent gain and leakiness for the right channel when running in stereo.
Per frame it reads the Channel control value, clamps it to the available inputs, and mixes the two inputs by the resulting gains — the selected input at full gain plus the leakiness share on the other. The switch is evaluated one sample-frame at a time, as WaveWarp's sample-per-sample engine advances.