feat: add Anvil sub anchor and Crucible resampler
Check and Windows preview / check (anvil) (push) Successful in 2m41s
Check and Windows preview / check (crucible) (push) Successful in 2m7s
Check and Windows preview / check (patina) (push) Successful in 2m5s
Check and Windows preview / check (rivet) (push) Successful in 1m33s
Check and Windows preview / previews (push) Successful in 1m10s
Check and Windows preview / windows (push) Successful in 2m2s
Independent plugin release / publish (push) Successful in 8s
Independent plugin release / plan (push) Successful in 7s
Independent plugin release / build (push) Successful in 3m3s

Two new CLAP effects aimed at riddim and dubstep production, plus shared
crates so all four plugins keep one look and reuse DSP.

Anvil 0.1.0 (io.storyboard.sub-anchor):
- Replaces the band below Split with a clean mono sine. Every note gets
  the same peak level and restarts at the same phase, so switch-ups keep
  their weight and kick hits line up.
- Pitch and note starts come from the audio (YIN, 80 ms lookahead
  reported to the host) or from MIDI notes sent to the effect.
- Dynamics, Drive, Octave, Glide, Phase, Gate and Keep; Solo sub monitor,
  note readout, level meters and a low-band oscilloscope.

Crucible 0.1.0 (io.storyboard.resampler):
- Records its input continuously in a lock-free ring with host transport
  markers. Capture takes the newest 1-16 complete bars on the bar grid,
  following tempo changes, or the newest audio when stopped.
- Grid (straight and triplet) or transient slicing, manual cuts, slice
  audition without audio-thread allocation.
- Export writes the loop, trimmed, declicked and normalised slices named
  and tagged with their root note, and an optional 2048-sample wavetable
  for Serum and Vital.

Shared:
- common-ui holds the palette, fonts, knobs and panels taken from Patina;
  Patina renders identically. Rotary knobs at their minimum no longer
  tessellate a zero-length arc into NaN vertices.
- common-dsp holds biquads, a Linkwitz-Riley crossover, YIN, note helpers
  and a float WAV writer with sampler root and Serum frame chunks.
- Catalog, CI matrix, release tags, editor previews and docs cover both
  plugins; a script test keeps the catalog and workflows in step.
This commit is contained in:
nvrl committed 2026-11-06 03:22:00 +01:00
1 parent f1366280ff
commit f36ff0780c
57 files changed
+10373 -285

No files matched your search

+108 -5
View File
@@ -10,13 +10,19 @@ fn main() {
.find(|a| a[0] == "--plugin")
.map(|a| a[1].as_str())
.unwrap_or("rivet");
if !["rivet", "patina"].contains(&plugin) {
eprintln!("Use --plugin rivet or --plugin patina");
if !["rivet", "patina", "anvil", "crucible"].contains(&plugin) {
eprintln!("Use --plugin rivet, patina, anvil or crucible");
std::process::exit(2);
}
let patina = plugin == "patina" || args.iter().any(|arg| arg == "--resonance");
let compact = std::env::args().any(|arg| arg == "--compact");
let (width, height) = if patina {
let anvil = plugin == "anvil";
let crucible = plugin == "crucible";
let (width, height) = if crucible {
(crucible_ui::WIDTH, crucible_ui::HEIGHT)
} else if anvil {
(anvil_ui::WIDTH, anvil_ui::HEIGHT)
} else if patina {
if compact {
(1040, 700)
} else {
@@ -63,6 +69,90 @@ fn main() {
}
}
}
let mut anvil_settings = anvil_core::Settings::default();
let mut anvil_state = anvil_ui::State::default();
if anvil {
let mut engine = anvil_core::Engine::new(48000., 2).unwrap();
engine.set_settings(anvil_settings).unwrap();
let mut saw = common_dsp::Saw::new(48000., 43.65);
for i in 0..36000 {
// A distorted F1 bass whose own sub drifts in phase and level.
let x = (saw.sample() * 1.6 + 0.3 * (i as f32 * 0.0009).sin()).tanh() * 0.4;
engine.process_sample([x, x], anvil_core::Monitor::default());
if i % 1600 == 0 {
anvil_state.accept_frame(engine.take_analyzer());
}
}
anvil_state.accept_frame(engine.take_analyzer());
}
let mut crucible_settings = crucible_core::Settings {
folder: "C:\\Users\\you\\Documents\\Crucible".into(),
..Default::default()
};
let mut crucible_state = crucible_ui::State::default();
let crucible_link = crucible_ui::Link {
ring: Some(Arc::new(crucible_core::Ring::new(
48000.,
crucible_core::HISTORY,
))),
queues: Arc::new(crucible_core::Queues::default()),
};
if crucible {
// Four bars of a 150 BPM riddim pattern: square-ish bass hits on varied notes.
let rate = 48000.;
let beat = 60. / 150. * rate;
let frames = (16. * beat) as usize;
let mut audio = vec![0f32; frames * 2];
let pattern = [
(0., 29),
(1.5, 29),
(2.75, 32),
(4., 27),
(5.5, 29),
(6.5, 34),
(8., 29),
(9.5, 29),
(10.75, 36),
(12., 27),
(13.5, 32),
(14.5, 29),
];
for (at, note) in pattern {
let start = (at * beat) as usize;
let hz = common_dsp::midi_to_hz(note as f32);
let mut saw = common_dsp::Saw::new(rate, hz);
for i in 0..(0.6 * beat) as usize {
let f = start + i;
if f >= frames {
break;
}
let env = (1. - i as f32 / (0.6 * beat)).powf(0.4);
let v = (saw.sample() * 2.5).tanh() * 0.6 * env;
audio[2 * f] += v;
audio[2 * f + 1] += v;
}
}
let transport = crucible_core::Transport {
playing: true,
tempo: 150.,
beats: 0.,
numerator: 4,
denominator: 4,
};
let segments = vec![crucible_core::Segment {
frame: 0.,
quarters: 0.,
tempo: 150.,
}];
let take = crucible_core::Take::from_audio(rate, audio, 4, transport, segments, true);
crucible_settings.mode = crucible_core::Mode::Transient;
crucible_state.add(take.clone(), &crucible_settings);
crucible_state.add(take, &crucible_settings);
crucible_state.slice = Some(2);
crucible_state.takes[0].slices[5].enabled = false;
crucible_state.transport = Some(transport);
crucible_state.status = "Captured 4 bars on the bar grid.".into();
}
let shared = Arc::new(rivet_app::Shared::default());
let mut session = rivet_core::Session::demo();
session.motifs[0].phrase.notes[0].locked = true;
@@ -83,7 +173,11 @@ fn main() {
let session_motif = session.motifs[0].id;
shared.replace(session).unwrap();
let ctx = egui::Context::default();
if patina {
if crucible {
crucible_ui::style(&ctx);
} else if anvil {
anvil_ui::style(&ctx);
} else if patina {
patina_ui::style(&ctx);
} else {
editor::style(&ctx);
@@ -108,7 +202,16 @@ fn main() {
},
|ui| {
egui::CentralPanel::default().show(ui, |ui| {
if patina {
if crucible {
crucible_ui::show(
ui,
&mut crucible_settings,
&mut crucible_state,
&crucible_link,
);
} else if anvil {
anvil_ui::show(ui, &mut anvil_settings, &mut anvil_state);
} else if patina {
patina_ui::show(ui, &mut patina_settings, &mut patina_state);
} else {
editor::show(ui, &shared, &mut state);