Multi-board playback was all-or-one: selectBoard soloed exclusively,
selectAllBoards summed. There was no way to play an arbitrary subset, and
the builder only exposed a dropdown that picked which board to *edit*.
ShoeGaze API:
- setBoard(_:audible:crossfadeSeconds:) toggles one board's select-gain in
place without disturbing the others (Blend mixing); clears activeBoardIndex.
- soloBoard(_:crossfadeSeconds:) — the "Solo" verb (wraps selectBoard).
- isBoardAudible(_:) reports a board's live select-gain target.
UI — BoardBarView (shared macOS/iOS):
- Horizontal board-mixer strip. Each board is a channel cell: audible LED,
Solo button, and a master-gain fader. Tapping a cell name sets the edit
target (independent of what's audible); context menu silences/deletes.
- Solo | Blend mode switch + an All button + a crossfade slider.
- Replaces the builder's board dropdown and Add Board button; the cell's +
adds a board.
Tests: solo/blend/all audibility transitions and activeBoardIndex tracking;
setBoard no-op for a board owned by another manager.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Three new pedals:
- LimiterPedal: linear boost gain stage into a LookAheadLimiter brick-wall
ceiling. Reads engine sampleRate injected by PedalBoard.add at build time.
- NoiseGatePedal: AmplitudeFollower -> hysteretic Schmidt gate -> LinLin floor
map -> Lag smoothing. Tuneable residual floor when the gate is closed.
- GraphicEQPedal: five cascaded RBJ filters (low/high shelf + three peaking
mids) with per-band dB gains and a linear master output gain.
New UI control:
- PedalSlider descriptor and Pedal.effectSliders hook, alongside effectKnobs
and effectSwitches.
- VerticalParameterSlider: a vertical fader bound to a UIParamNode.
- PedalView renders the fader bank and widens the enclosure to fit it.
Persistence/registry:
- PedalState.sliderValues (decodeIfPresent for backward compatibility); capture
and apply in Pedal+Preset.
- Registry entries and palette ordering for all three pedals.
Tests: non-silent builds, limiter ceiling enforcement, gate open/closed/unity
floor power ratios, EQ flat output, global-gain scaling, and 6-slider preset
round-trip.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Live input was silent on macOS because the apps ran under hardened runtime
without the microphone entitlement, so AUHAL input received silent zeros and
the OS never prompted. Fixes:
- Add com.apple.security.device.audio-input entitlement to the macOS Builder
and Demo apps (CODE_SIGN_ENTITLEMENTS wired in both targets).
- Add MicrophonePermission helper (AVCaptureDevice.requestAccess) and gate
live-input selection through it in the Builder view and Demo controller;
deny falls back to the test loop with an explanatory alert.
- Fix ShoeGazeDemo inputChannels 6 -> 1 (built-in mics are mono; 6 made
CoreAudio deliver silence).
Engine-config review fixes:
- installScopeTap now requires the engine stopped (precondition) and
reconfigureEngine reinstalls the tap on every exit path via defer, so
engine.scopeTap never points at a stale channel layout.
- EngineConfigView stops the engine on a post-start (iOS) sample-rate
mismatch instead of running pitch-shifted, and surfaces non-mismatch
start errors through the alert.
- Remove redundant installScopeTap call in the demo controller (ShoeGaze.init
already installs it).
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
TestLoopSource now plays a repeating pluck arpeggio over the open lower
four guitar strings (E2, A2, D3, G3) in E minor: one Impulse drives both
the KarplusStrong excitation and a Demand/DemandSequence that steps the
pitch per pluck. Fixed-seed WhiteNoise exciter keeps the tone deterministic
(so two source renders match, e.g. the overdrive bypass-equals-dry test).
Adds a sampleRate init param (default 48k) sizing the KS delay line;
ShoeGaze.addBoard passes the engine's actual rate.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Wires the existing ShoeGaze recording engine into the builder:
- macOS: a Record menu (Choose Recording Folder…; Start/Stop Recording,
⇧⌘R) in the app shell's AppDelegate. validateMenuItem gates Start on a
chosen folder and flips the title; the title is also set directly in
the toggle action so it never goes stale.
- iOS: an in-view recording row in ShoeGazeBuilderView — folder picker
(.fileImporter with security-scoped access) + Record/Stop button,
gated on a chosen folder.
- Both: a red REC indicator in the transport header bound to isRecording.
Reuses startRecording/stopRecording/recordingFolder/isRecording (already
covered by RecordingTests); no core or RT changes.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
A stereo-output pedal (Ping-Pong, Octave Splitter) now shows a
"Stereo flow / Split L/R" toggle on its card:
- Stereo flow (default): unchanged broadcast behavior — following pedals
process both channels as one stereo flow.
- Split L/R: inserts a Stereo Unzip region right after the pedal, routing
the L channel into one lane and R into the other for independent
processing, then recombining to stereo with the same route/solo/bypass
control as the stereo split.
Engine/core:
- StereoUnzipSplitter: 2-in -> 3-out node (L->lane L, R->lane R, and a
centered 0.5*L+0.5*R dry tap for the bypass route).
- PedalBoard.unzipStereo() mirrors splitStereo() but reads both tails and
requires width 2; reuses collectStereo / StereoSplitSection /
StereoRouteCollector. New stereoUnzipSections (cleared on teardown).
- BoardSegment/.stereoUnzip + StereoUnzipState round-trip via preset
capture/rebuild/applyState.
- ShoeGaze.insertStereoUnzip(afterSegment:)/isStereoUnzip(afterSegment:)
drive the toggle; invalid insert (mono tail) throws
cannotUnzipMonoChain and the atomic rebuild keeps the board intact.
- StereoSplitSection.splitter relaxed to `any Synthesizer` (stored only)
so it can hold either splitter type.
UI: per-pedal toggle + STEREO UNZIP region rendering in BoardFlowView.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
- Info.plists: "Realized Sound" -> "realizedsound" in the copyright string
(all four demo apps).
- macOS: Save/Load now live in a File menu (Save Rig… ⌘S, Load Rig… ⌘O)
and a Board menu (Add Board ⌘B, Start ⌘R, Stop ⌘.) in the app shell's
AppDelegate; the in-view Save…/Load… buttons and their NSPanel code are
now iOS-only (#if !os(macOS)), with iOS keeping fileExporter/Importer.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Interactive builder views in LyrebirdShoeGazeUI:
- PedalPaletteView: vertical sidebar listing every pedal (tap to append
to the main chain, drag "add:<type>" onto a lane) plus routing actions
(Stereo Split / Parallel Split / Merge to Mono).
- BoardFlowView: left-to-right signal-flow board driven by
board.orderedSegments. Pedal cards joined by pink connector lines
(double for stereo width); split regions render as two stacked L/R
(A/B) lanes you fill independently by dropping pedals; per-card trash,
drag-to-reorder within a lane, region route/mode controls, and a
region trash. Reads shoeGaze.boards[index] fresh each body (index is
the stable anchor across rebuilds).
- ShoeGazeBuilderView: sidebar + vertically-centered flow board, with
transport, input picker, board picker, and JSON save/load (NSSavePanel
/ NSOpenPanel on macOS, fileExporter/Importer on iOS via
RigFileDocument).
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Core support for interactively building and editing a board, all via the
existing capture-BoardState -> mutate -> rebuildBoard path (no RT-graph
surgery):
- PedalLane addresses the main chain or a stereo/parallel branch.
- appendPedal/removePedal/movePedal gain a `lane:` parameter (default
.main, so existing call sites are unchanged).
- appendStereoSplit/appendParallelSplit/appendMergeToMono/removeSegment
insert and remove branch regions; split/merge guarded by tail width.
- setInputSource preserves the rig across an input-source change.
- rebuildAllBoards / loadRig(from:Data) / rigData added; loadRig is now
atomic (teardown-on-failure) so a failed load leaves an empty rig.
- Expose PedalBoard.orderedSegments and BoardSegment publicly so a UI can
walk live board structure; index aligns with captureState().segments.
- InputSource: Equatable. New errors: unknownPedalType,
pedalIndexOutOfRange, cannotSplitStereoChain, cannotMergeMonoChain,
notABranchRegion.
Tests cover append/remove/move on main and branch lanes, region
add/remove, width guards, move-to-end before trailing regions, input
switch, and knob/bypass/branch value persistence through save/load.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Monophonic octave-down pedal with OCT1/OCT2/Direct knobs and a Mode
switch between two algorithms:
- Flip-flop (default): a hysteresis comparator clocks a T flip-flop
divider chain (new SubOctaveDivider generator) to produce square
sub-octaves one and two octaves down, amplitude-followed off the dry
signal. Time-domain — tracks low bass with no detection floor.
- Tracking: FreqTracker drives square oscillators at half and quarter
the detected frequency. Cleaner, but limited by the tracker's ~90 Hz
floor; flip-flop is the bass mode.
SubOctaveDivider classifies its input as generator-or-scalar at init to
keep _computeSamples allocation-free, uses a shared file-scope zero
block, bounds-checks the input read, and traps on divisor < 2.
Tests: BassOctaverPedal integration (both modes non-silent, modes
differ, sub-octaves change output, knobs/switch/preset/registry) and
SubOctaveDivider deterministic frequency-division (divisor 2 -> /2,
divisor 4 -> /4, /4 one octave below /2). 127 tests pass.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Add Octave Splitter and Ping-Pong to PedalRegistry so rigs containing
them reconstruct on loadRig — board.add replays the mono→stereo width
transition automatically. Document that split-section topology (parallel
and stereo) remains outside the captured linear chain, as before.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Mu-Tron plum, Auto-Wah gold, Feedback Delay tape sepia, Multi-Tap Delay
cyan — distinct from the existing eight so they no longer fall through to
the default steel gray.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Move the Mix knob out of the knob grid into the bottom control row, to the
right of the bypass footswitch, mirroring Level on the left. Every pedal
now shares a consistent knob-switch-knob footer. The knob grid drops the
trailing Mix and Level entries (was just Level).
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Introduces a discrete multi-position switch control alongside the rotary
knobs, and uses it to expose the Mu-Tron's sweep direction and filter mode.
- PedalSwitch: UI-agnostic descriptor (label, node, ordered options of
caption + value), parallel to PedalKnob. Two options make a two-state
switch, three a three-state switch.
- PedalSwitchView: segmented SwiftUI control bound to a UIParamNode. Lit
segment is the option nearest the node's value; tapping writes that
option's value. Serves both two- and three-state switches.
- Pedal gains an effectSwitches hook; PedalView renders a switch row
between the knob grid and the footswitch.
- MuTronPedal: sweep direction is now a two-state switch (Down/Up) and
filter mode a three-state switch (LP/BP/HP). The effect builds six
MuTronIII instances (three modes x two directions) selected by a nested
Select so every filter state stays warmed for click-free switching.
- Presets: PedalState gains a backward-compatible switchValues array
(decodes to empty for older presets); captureState/applyState persist
and restore switch positions.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Two envelope filters and two delays, registered in PedalRegistry and
showcased on demo Board 3.
- Mu-Tron: wraps the MuTronIII generator; three parallel LP/BP/HP
instances switched live by a Select on the mode knob so filter state
stays warmed across mode changes. Knobs: Mode, Sensitivity, Resonance.
- Auto-Wah: explicit amplitude-tracking chain — AmplitudeFollower scaled
by sensitivity, clamped, mapped through LinExp to a swept SVF bandpass.
Knobs: Sensitivity, Resonance, Range.
- Feedback Delay: DelayLineFeedback (cubic) into an RBJ lowpass for a
darker, tape-style multi-repeat echo. Knobs: Time, Feedback, Tone.
- Multi-Tap Delay: three non-feedback DelayLine taps summed, per-tap
volume folded into each tap's mul. Six knobs in two rows of three.
Bumps the Lyrebird dependency to 1.2.0 for the MuTronIII/SVF generators.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>