Add VST3 option

This commit is contained in:
Ebu
2025-12-04 12:11:29 +01:00
parent a9bd69e461
commit 74428b272d
10 changed files with 119 additions and 67 deletions

View File

@@ -4,14 +4,20 @@ version = "0.1.0"
edition = "2024"
[lib]
crate-type = ["cdylib"]
crate-type = ["cdylib", "rlib"]
[dependencies]
dsp = { version = "0.1.0", path = "../dsp" }
nih_plug = { git = "https://github.com/robbert-vdh/nih-plug", version = "0.0.0", default-features = false }
parking_lot = "0.12.5"
baseview = { git = "https://github.com/RustAudio/baseview", rev = "237d323c729f3aa99476ba3efa50129c5e86cad3", features = ["opengl"]}
baseview = { git = "https://github.com/RustAudio/baseview", rev = "237d323c729f3aa99476ba3efa50129c5e86cad3", features = [
"opengl",
] }
crossbeam = "0.8.4"
femtovg = "0.19.3"
serde = { version = "1.0.228", features = ["derive"] }
image = { version = "0.25.9", default-features = false, features = ["png"] }
image = { version = "0.25.9", default-features = false, features = ["png"] }
[target.'cfg(target_os = "linux")'.dependencies]
nih_plug = { git = "https://github.com/robbert-vdh/nih-plug", version = "0.0.0", default-features = false }
[features]
vst3 = ["nih_plug/vst3"]

View File

@@ -203,6 +203,7 @@ impl Plugin for AirFreshener {
fn deactivate(&mut self) {}
}
#[cfg(not(feature = "vst3"))]
impl ClapPlugin for AirFreshener {
const CLAP_ID: &'static str = "com.moist-plugins-gmbh.gain";
const CLAP_DESCRIPTION: Option<&'static str> = Some("A smoothed gain parameter example plugin");
@@ -215,4 +216,16 @@ impl ClapPlugin for AirFreshener {
];
}
#[cfg(feature = "vst3")]
impl Vst3Plugin for AirFreshener {
const VST3_CLASS_ID: [u8; 16] = *b"AirFreshener____";
const VST3_SUBCATEGORIES: &'static [Vst3SubCategory] =
&[Vst3SubCategory::Fx, Vst3SubCategory::Tools];
}
#[cfg(not(feature = "vst3"))]
nih_export_clap!(AirFreshener);
#[cfg(feature = "vst3")]
nih_export_vst3!(AirFreshener);