Two fixes from the guitar-input analysis:
- Mono board output no longer loses 3 dB. BoardOutputMaster panned a mono
board to stereo centre with an equal-power Pan2 (×0.707 per channel). A
mono rig should come out at the level it went in, so the signal is now
written to both hardware buses directly at unity.
- Noise Gate gains a Peak/RMS detector switch (defaults to RMS). The peak
follower (|x|) rides the waveform's peaks, so the gate's threshold decision
tracked instantaneous peaks rather than loudness; the RMS detector
(√ symmetric-average of x²) follows perceived level, so the gate opens and
closes where the note actually is. Implemented as a rebuildsOnChange switch
that builds only the chosen follower. Serialization-safe: a gate saved
before the switch (empty switchValues) loads with the RMS default.
Tests cover the detector switch, RMS default (incl. legacy load), state
round-trip, and RMS closing earlier than Peak on a sustained tail.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Volume is a CC-mappable [0,1] gain applied after every board's output; mute
is a separate hard gate (not the existing dry bypass), togglable via
Program Change. Both are lagged to avoid clicks and fan out across all
boards from a single ShoeGaze-level setter.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Headline: MIDI control for a Behringer FCB1010 (four phases).
- MIDIController (Lyrebird MIDI client): connection indicator via source
polling, background-queue->main-actor hop, MIDI Learn.
- Volume and Wah pedals (Wah reuses the SVF bandpass sweep, driven by
pedal position instead of an envelope follower).
- CC -> any pedal knob (0-127 mapped across the knob range).
- Program Change -> pedal/board/rig toggles: software latch for booleans,
exclusive radio for board solo. Positional addressing with display-name
hints; stale/out-of-range bindings are skipped, not fired.
- Per-rig MIDIMap embedded in ShoeGazeState as an optional field (old rigs
decode to nil; no preset version bump). Central MIDI Mapping sheet with
Learn/Clear per control.
Also included (same working branch):
- Full board bypass and rig bypass (dry passthrough via cascaded
crossfades in BoardOutputMaster), with UI toggles.
- Horizontal pedal picker grouped by category in filter order.
- Drag a palette pedal onto a chain card to insert before it
(ShoeGaze.insertPedal); tap still appends.
- iOS: guard macOS-only .menuStyle(.borderlessButton) to silence the
_UIReparentingView warning; iCloud-unavailable alert; keep the device
awake while audio runs.
Tests: 24 added (Volume/Wah, MIDIMap Codable incl. legacy decode,
CC and PC controller behavior, insert/bypass API). Full suite green;
macOS and iOS app targets build.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>