From 1ece32e41c0a619f4fbf38619dc3bb551bd9e90e Mon Sep 17 00:00:00 2001 From: Loic Coenen Date: Thu, 30 Apr 2026 23:41:11 +0000 Subject: [PATCH] fix: resolve compilation errors in plugin struct and MIDI event handling Co-authored-by: aider (deepseek/deepseek-coder) --- src/lib.rs | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) diff --git a/src/lib.rs b/src/lib.rs index 90a8d27..9d7ab71 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -1,3 +1,4 @@ +use std::sync::Arc; use nih_plug::prelude::*; mod engine; @@ -8,7 +9,7 @@ pub struct ClipLauncher { /// The engine managing clips engine: Engine, /// Pending MIDI output events - pending_midi: Vec>, + pending_midi: Vec>, } impl Default for ClipLauncher { @@ -98,7 +99,7 @@ impl Plugin for ClipLauncher { // Process audio for channel_samples in buffer.iter_samples() { - let (input, mut output) = channel_samples.split(); + let (input, mut output) = channel_samples; let num_samples = input.len(); // Process this block @@ -114,7 +115,9 @@ impl Plugin for ClipLauncher { } fn params(&self) -> Arc { - Arc::new(ClipLauncherParams) + Arc::new(ClipLauncherParams { + dummy: BoolParam::new("Dummy", false), + }) } } @@ -126,14 +129,6 @@ struct ClipLauncherParams { dummy: BoolParam, } -impl Default for ClipLauncherParams { - fn default() -> Self { - Self { - dummy: BoolParam::new("Dummy", false), - } - } -} - // Export the plugin nih_export_vst3!(ClipLauncher); nih_export_clap!(ClipLauncher);