Skip to content

Use a Plugin

Effect(slot, name) names an effect plugin and Instrument(name) an instrument plugin. Placing it on a track with set_effects or set_instrument loads it. Every method is in the audio reference. The Plugin Database explains scanning.

Name the plugin, place it, then dial it:

use "std/instruments" { Sampler, Kit };
let drums = AudioTrack("drums");
drums.set_instrument(Sampler(Kit("CR-78")));
drums << [bd sd bd sd];
let reverb = Effect("reverb", "resonon-reverb");
drums.set_effects(#[reverb]);
reverb.set_parameter("Room", 0.8);
PLAY;

resonon-reverb and resonon-reverb-plate ship with resonon and need no scan.

A plugin can be named by display name, by filename in your plugin folders, or by full path. When one bundle holds several plugins, or you have a CLAP and a VST3 build of the same plugin, add the plugin ID to say which one:

let shimmer = Effect("shimmer", "Valhalla Shimmer");
let custom = Effect("custom", "/path/to/plugin.clap");
let chorus = Effect("chorus", "Multi-FX", "com.vendor.multi-fx.chorus");

A plugin instrument goes on a track like any other instrument:

let lead = AudioTrack("lead");
lead.set_instrument(Instrument("Surge XT"));
lead << [C4 E4 G4 C5];

plugin_scan() sweeps your plugin folders and returns what it found:

let plugins = plugin_scan();
print(plugins); // a table
print(plugins.filter("reverb")); // by name

In VSCode, run RESONON: Rescan Plugins; in a terminal, resonon plugin scan. To add a folder of your own, run resonon config plugins add <path>, then reload_preferences().

.parameters() returns every parameter with its range, default and current value, and print shows it as a table; a substring filters the list. set_parameter sets a value and chains, and parameter hands back the parameter itself: read it with .get(), set it as 0–1 across its range with .set_norm(), or modulate it with <<:

use "std/signals" { Sine };
let reverb = Effect("reverb", "resonon-reverb");
master.set_effects(#[reverb]);
print(reverb.parameters("room"));
reverb.set_parameter("Room", 0.8)
.set_parameter("Damp", 0.4);
show(reverb.parameter("Room").get());
reverb.parameter("Mix") << 0.4;
reverb.parameter("Room") << Sine(0.2).range(0.3, 0.9);

Values set before set_effects are applied when the plugin is built; reading needs it on a track.

let lead = AudioTrack("lead");
let synth = Instrument("Surge XT");
lead.set_instrument(synth);
if synth.supports_gui() {
synth.show_gui();
}

.hide_gui() closes it. The bundled reverbs have no editor.

.save_state(path) writes the plugin’s full state to a file; .load_state(path) reads it into another instance. Saving needs the plugin on a track. Loading can come before placement:

let lead = AudioTrack("lead");
let synth = Instrument("Surge XT");
lead.set_instrument(synth);
synth.save_state("presets/my_lead.preset");
let backing = AudioTrack("backing");
let synth2 = Instrument("Surge XT");
synth2.load_state("presets/my_lead.preset");
backing.set_instrument(synth2);

A state file only loads into the plugin that wrote it.

A plugin that crashed or timed out while being scanned is skipped. Updating or reinstalling it brings it back by itself. To retry the same build:

  • Run the constructor that failed, and take the Retry quick fix on its line.
  • Or run RESONON: Retry Skipped Plugins… in VSCode to see every skipped plugin and pick what to retry.
  • Or retry one bundle in code or from a terminal:
plugin_rescan("~/Library/Audio/Plug-Ins/VST3/Whatever.vst3");
Terminal window
resonon plugin rescan ~/Library/Audio/Plug-Ins/VST3/Whatever.vst3
resonon plugin list # what is skipped, and why

plugin_scan(force: true) — RESONON: Rescan Plugins (Full), resonon plugin scan --force — re-opens every bundle, which takes as long as a first scan.

Uncheck resonon.plugins.autoScan in VSCode, pass --plugin-auto-scan=false, or set RESONON_PLUGIN_AUTO_SCAN=0 (environment variables). Plugins named by path or filename still load.