f89229282f
Introduce chain width propagation (mono=1 / stereo=2, capped at 2), represented as a pair of mono buses to reuse existing infrastructure. - Pedal: width-parameterized build() with channelKind (mono / widener / stereoNative); effect() runs per channel for auto-stereoize, shared knobs. - PedalBoard: width tracking, add() dispatch, mergeToMono(), splitStereo()/ collectStereo() with four route modes (stereo / leftOnly / rightOnly / bypass), centered solo, click-free lagged gains. - BoardOutputMaster: width-aware (Pan2 mono, direct L/R stereo). - New routing nodes: StereoSplitter, StereoRouteCollector, StereoSplitSection. - Reference pedals: OctaveUpSplitterPedal (widener), PingPongDelayPedal (stereo-native). - 12 stereo-routing tests; full suite 108/108. Design: docs/stereo-routing-design.md Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
33 lines
1.2 KiB
Swift
33 lines
1.2 KiB
Swift
// StereoRoute.swift
|
|
// Lyrebird
|
|
//
|
|
// Copyright (c) 2026 Joshua Parmenter / realizedsound
|
|
// SPDX-License-Identifier: MIT
|
|
|
|
/// Output routing mode for a stereo split region (see ``StereoSplitSection``).
|
|
///
|
|
/// Selects how the left chain, right chain, and the clean pre-split signal map to the
|
|
/// final stereo output pair. Transitions between modes are click-free — the
|
|
/// ``StereoRouteCollector`` lags each mode gain over 20 ms.
|
|
///
|
|
/// - `stereo`: normal operation — left chain → left output, right chain → right output.
|
|
/// - `leftOnly`: **centered** solo of the left chain — the left chain is sent to *both*
|
|
/// output channels, so it plays full and centered rather than only in the left speaker.
|
|
/// - `rightOnly`: centered solo of the right chain (both output channels).
|
|
/// - `bypass`: the clean pre-split signal passes to both output channels; both branch
|
|
/// chains are muted.
|
|
public enum StereoRoute: String, Codable, CaseIterable {
|
|
|
|
/// Left chain → left, right chain → right.
|
|
case stereo
|
|
|
|
/// Centered solo of the left chain (both speakers).
|
|
case leftOnly
|
|
|
|
/// Centered solo of the right chain (both speakers).
|
|
case rightOnly
|
|
|
|
/// Clean pre-split signal through both channels; branches muted.
|
|
case bypass
|
|
}
|