feat(amps): Chime Top Boost — full Vox-style control surface
Full-surface counterpart to the basic Chime voice, modeling the AC-style top-boost combo. Reuses the AmpVoicePedal hooks: - inputShaping: Brilliant switch (pre-preamp treble shelf, identity when off). - onboardEffects: tremolo (Speed/Intensity), gated by a Tremolo footswitch. No onboard reverb (always outboard on these amps). - shapeVoice: the Cut control (post-power-amp low-pass swept 9k→2.5k). ChimeTopBoostAmpPedal (.vox): Gain/Bass/Mid/Treble + Cut/Speed/Intensity knobs, Brilliant + Tremolo switches, Cab selector (defaults to Bright 1×12); widthUnits 3. Registered across registry/type/category/palette/enclosure; Help acknowledgment lists its tone stack. 10 tests (Cut, tremolo intensity/speed, brilliant, tremolo footswitch bit-exact bypass, ceiling with FX, control surface, round-trip, registry). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -49,6 +49,7 @@ public extension PedalType {
|
||||
static let chime = PedalType("Chime")
|
||||
static let fullertonReverb = PedalType("Fullerton Reverb")
|
||||
static let jazzClean = PedalType("Jazz Clean")
|
||||
static let chimeTopBoost = PedalType("Chime Top Boost")
|
||||
static let neuralAmp = PedalType("Neural Amp")
|
||||
static let overdrive = PedalType("Overdrive")
|
||||
static let distortion = PedalType("Distortion")
|
||||
|
||||
@@ -0,0 +1,140 @@
|
||||
// ChimeTopBoostAmpPedal.swift
|
||||
// Lyrebird
|
||||
//
|
||||
// Copyright (c) 2026 Joshua Parmenter / realizedsound
|
||||
// SPDX-License-Identifier: MIT
|
||||
|
||||
import LyrebirdSynth
|
||||
import LyrebirdUI
|
||||
|
||||
/// British-invasion "top boost" combo with a full control surface: the chimey top-boost EQ, a
|
||||
/// **Cut** control that tames the highs, onboard **tremolo** (Speed / Intensity), and a
|
||||
/// **Brilliant** switch — the jangly clean-to-edge-of-breakup voice.
|
||||
///
|
||||
/// A ``AmpVoicePedal`` fixed to the chime tone stack that fills both subclass hooks:
|
||||
/// - ``inputShaping(_:)`` applies the Brilliant switch as a pre-preamp treble shelf.
|
||||
/// - ``onboardEffects(_:)`` inserts the tremolo between the tone stack and the power amp.
|
||||
///
|
||||
/// Unlike the American blackface combo this amp has no built-in reverb (that was always outboard),
|
||||
/// so the onboard-effects slot holds only the tremolo. Tremolo defaults off (`Intensity = 0`).
|
||||
public final class ChimeTopBoostAmpPedal: AmpVoicePedal {
|
||||
|
||||
// MARK: - Signature / onboard-effect parameters
|
||||
|
||||
/// Cut amount in [0, 1]: `0` = fully open/bright, `1` = darkest (the top-boost "Cut" control,
|
||||
/// which rolls off the highs as it's turned up).
|
||||
@UIParam public var cut: Double = 0.2
|
||||
/// Tremolo LFO rate in Hz. Range [0.5, 12].
|
||||
@UIParam public var speed: Double = 4.0
|
||||
/// Tremolo depth in [0, 1]. `0` = off, `1` = full swing.
|
||||
@UIParam public var intensity: Double = 0.0
|
||||
/// Brilliant switch: `0` = flat, `1` = treble shelf engaged (the brilliant/top-boost sparkle).
|
||||
@UIParam public var brilliant: Double = 0.0
|
||||
/// Tremolo footswitch: `1` = engaged, `0` = bypassed (`Speed`/`Intensity` preserved).
|
||||
@UIParam public var tremoloEnabled: Double = 1.0
|
||||
|
||||
// MARK: - Constants
|
||||
|
||||
/// Cut low-pass cutoff when fully open (`cut = 0`), in Hz.
|
||||
private let cutOpenHz: Double = 9000.0
|
||||
/// Cut low-pass cutoff when fully dark (`cut = 1`), in Hz.
|
||||
private let cutDarkHz: Double = 2500.0
|
||||
/// Cut low-pass Q (Butterworth).
|
||||
private let cutQ: Double = 0.707
|
||||
/// Brilliant-switch shelf corner in Hz.
|
||||
private let brilliantFreqHz: Double = 4000.0
|
||||
/// Brilliant-switch shelf lift in dB when engaged.
|
||||
private let brilliantMaxGainDb: Double = 6.0
|
||||
/// Brilliant-switch shelf slope.
|
||||
private let brilliantSlope: Double = 0.7
|
||||
/// Tremolo depth scaling — at full `intensity` the LFO swings over half the normalised range so
|
||||
/// the peak gain is 1.0 and the trough is `1 − intensity`.
|
||||
private let tremoloDepthScale: Double = 0.5
|
||||
|
||||
private let cutRange: ClosedRange<Double> = 0.0 ... 1.0
|
||||
private let speedRange: ClosedRange<Double> = 0.5 ... 12.0
|
||||
private let intensityRange: ClosedRange<Double> = 0.0 ... 1.0
|
||||
private let switchOffValue: Double = 0.0
|
||||
private let switchOnValue: Double = 1.0
|
||||
|
||||
// MARK: - Voice configuration
|
||||
|
||||
public override var toneStackModel: ToneStackModel { .vox }
|
||||
public override var summaryText: String {
|
||||
"Chimey top-boost jangle — Cut control, tremolo, and a Brilliant switch."
|
||||
}
|
||||
public override var signatureKnobs: [PedalKnob] {
|
||||
[
|
||||
PedalKnob(label: "Cut", node: $cut, range: cutRange),
|
||||
PedalKnob(label: "Speed", node: $speed, range: speedRange),
|
||||
PedalKnob(label: "Intensity", node: $intensity, range: intensityRange),
|
||||
]
|
||||
}
|
||||
|
||||
/// Wider card for the extra Cut/tremolo knobs plus the Brilliant and Tremolo switches.
|
||||
public override var widthUnits: Int { 3 }
|
||||
|
||||
// MARK: - Init
|
||||
|
||||
/// Creates a Chime Top Boost amp.
|
||||
///
|
||||
/// - Parameters:
|
||||
/// - inputBus: Audio bus index to read the dry input from. Defaults to `0`.
|
||||
/// - outputBus: Audio bus index to write the processed output to. Defaults to `0`.
|
||||
public init(inputBus: Int = 0, outputBus: Int = 0) {
|
||||
super.init(name: "Chime Top Boost", inputBus: inputBus, outputBus: outputBus)
|
||||
gain = 5.0
|
||||
cab = 5.0 // Bright 1×12 — the chimey, top-end-forward cab voice
|
||||
}
|
||||
|
||||
// MARK: - Switches
|
||||
|
||||
public override var effectSwitches: [PedalSwitch] {
|
||||
[
|
||||
PedalSwitch(
|
||||
label: "Brilliant",
|
||||
node: $brilliant,
|
||||
options: [
|
||||
PedalSwitch.Option(title: "Off", value: switchOffValue),
|
||||
PedalSwitch.Option(title: "On", value: switchOnValue),
|
||||
]
|
||||
),
|
||||
PedalSwitch(
|
||||
label: "Tremolo",
|
||||
node: $tremoloEnabled,
|
||||
options: [
|
||||
PedalSwitch.Option(title: "Off", value: switchOffValue),
|
||||
PedalSwitch.Option(title: "On", value: switchOnValue),
|
||||
]
|
||||
),
|
||||
]
|
||||
}
|
||||
|
||||
// MARK: - Hooks
|
||||
|
||||
/// Brilliant switch: a high-shelf lift ahead of the preamp (identity when off, live, no rebuild).
|
||||
public override func inputShaping(_ signal: any ValidGeneratorInput) -> any ValidGeneratorInput {
|
||||
let shelfGainDb: any ValidGeneratorInput = $brilliant * brilliantMaxGainDb
|
||||
return RBJHighShelf.Audio(
|
||||
input: signal, freq: brilliantFreqHz, gain: shelfGainDb, slope: brilliantSlope)
|
||||
}
|
||||
|
||||
/// Tremolo (gated by the Tremolo footswitch), inserted after the tone stack. No onboard reverb.
|
||||
public override func onboardEffects(_ signal: any ValidGeneratorInput) -> any ValidGeneratorInput {
|
||||
// Footswitch gates depth to 0 → LFO is a constant 1.0 (identity). Unipolar sine over
|
||||
// [1 − depth, 1]: peak gain 1.0, trough 1 − depth.
|
||||
let depth: any ValidGeneratorInput = $intensity * $tremoloEnabled
|
||||
let lfoScale: any ValidGeneratorInput = depth * tremoloDepthScale
|
||||
let lfoOffset: any ValidGeneratorInput = 1.0 - (depth * tremoloDepthScale)
|
||||
let lfo: OscSin.Audio = OscSin.Audio(freq: $speed, mul: lfoScale, add: lfoOffset)
|
||||
return signal * lfo
|
||||
}
|
||||
|
||||
/// Cut control: a low-pass whose cutoff sweeps from `cutOpenHz` (bright) down to `cutDarkHz`
|
||||
/// (dark) as `cut` rises — the top-boost "Cut" behaviour, applied post-power-amp.
|
||||
public override func shapeVoice(_ signal: any ValidGeneratorInput) -> any ValidGeneratorInput {
|
||||
let cutoff: LinLin.Audio = LinLin.Audio(
|
||||
$cut, inLo: 0.0, inHi: 1.0, outLo: cutOpenHz, outHi: cutDarkHz)
|
||||
return RBJLowPass.Audio(input: signal, freq: cutoff, q: cutQ)
|
||||
}
|
||||
}
|
||||
@@ -36,6 +36,7 @@ public enum PedalRegistry {
|
||||
"Chime": { ChimeAmpPedal() },
|
||||
"Fullerton Reverb": { FullertonReverbAmpPedal() },
|
||||
"Jazz Clean": { JazzCleanAmpPedal() },
|
||||
"Chime Top Boost": { ChimeTopBoostAmpPedal() },
|
||||
"Neural Amp": { NeuralAmpPedal() },
|
||||
"Overdrive": { OverdrivePedal() },
|
||||
"Distortion": { DistortionPedal() },
|
||||
|
||||
@@ -178,7 +178,7 @@ public struct HelpView: View {
|
||||
+ "built-in speaker impulse responses.",
|
||||
"The Cabinet pedal's built-in cab voicings are original impulse responses generated in "
|
||||
+ "code — not captures of any third-party hardware or IR pack.",
|
||||
"The California, British, Chime, Fullerton Reverb, and Jazz Clean amp pedals' tone stacks "
|
||||
"The California, British, Chime, Fullerton Reverb, Jazz Clean, and Chime Top Boost amp pedals' tone stacks "
|
||||
+ "follow the Yeh & Smith analysis of the classic passive tone-stack circuit (\"Discretization "
|
||||
+ "of the '59 Fender Bassman Tone Stack\", DAFx-06); their models are original code, not "
|
||||
+ "captures of specific hardware.",
|
||||
|
||||
@@ -42,7 +42,7 @@ public enum PedalCategory: String, CaseIterable, Identifiable, Sendable {
|
||||
}
|
||||
|
||||
private static let mapping: [String: PedalCategory] = [
|
||||
"California": .gain, "British": .gain, "Chime": .gain, "Fullerton Reverb": .gain, "Jazz Clean": .gain, "Neural Amp": .gain, "Overdrive": .gain, "Distortion": .gain, "Fuzz": .gain, "Volume": .gain,
|
||||
"California": .gain, "British": .gain, "Chime": .gain, "Fullerton Reverb": .gain, "Jazz Clean": .gain, "Chime Top Boost": .gain, "Neural Amp": .gain, "Overdrive": .gain, "Distortion": .gain, "Fuzz": .gain, "Volume": .gain,
|
||||
"Compressor": .dynamics, "Sustainer": .dynamics, "Limiter": .dynamics, "Noise Gate": .dynamics,
|
||||
"Graphic EQ": .filter, "Auto-Wah": .filter, "Wah": .filter, "Mutant": .filter,
|
||||
"Cabinet": .filter,
|
||||
|
||||
@@ -54,7 +54,7 @@ public struct PedalPaletteView: View {
|
||||
/// Preferred display order for the built-in pedals. Any registered pedal not listed here is
|
||||
/// appended afterwards (sorted) so the palette never silently drops a newly added pedal.
|
||||
private static let preferredOrder: [String] = [
|
||||
"California", "British", "Chime", "Fullerton Reverb", "Jazz Clean", "Neural Amp", "Overdrive", "Distortion", "Compressor", "Sustainer", "Limiter", "Noise Gate", "Fuzz",
|
||||
"California", "British", "Chime", "Fullerton Reverb", "Jazz Clean", "Chime Top Boost", "Neural Amp", "Overdrive", "Distortion", "Compressor", "Sustainer", "Limiter", "Noise Gate", "Fuzz",
|
||||
"Volume",
|
||||
"Graphic EQ", "Tremolo", "Phaser", "Modulation", "Chorus", "Flanger", "Vibrato", "Rotary",
|
||||
"Auto-Wah", "Wah", "Mutant", "Cabinet", "Ring Modulator", "Diffuser", "Bitcrusher", "Granulator",
|
||||
|
||||
@@ -22,6 +22,7 @@ private func enclosureColor(for displayName: String) -> Color {
|
||||
case "Chime": return Color(red: 0.16, green: 0.24, blue: 0.22) // vintage green
|
||||
case "Fullerton Reverb": return Color(red: 0.15, green: 0.22, blue: 0.30) // blackface panel
|
||||
case "Jazz Clean": return Color(red: 0.14, green: 0.30, blue: 0.34) // solid-state silver-teal
|
||||
case "Chime Top Boost": return Color(red: 0.20, green: 0.32, blue: 0.20) // vox-green tolex
|
||||
case "Neural Amp": return Color(red: 0.22, green: 0.16, blue: 0.30) // deep neural violet
|
||||
case "Overdrive": return Color(red: 0.85, green: 0.42, blue: 0.08) // warm orange
|
||||
case "Distortion": return Color(red: 0.80, green: 0.26, blue: 0.12) // hot rust
|
||||
|
||||
Reference in New Issue
Block a user