diff --git a/src/midi.rs b/src/midi.rs index 01835bd7..15279d2b 100644 --- a/src/midi.rs +++ b/src/midi.rs @@ -18,16 +18,17 @@ pub use midi_consts::channel_event::control_change; /// pub type PluginNoteEvent

= NoteEvent<

::SysExMessage>; -/// Determines which note events a plugin receives. +/// Determines which note events a plugin can send and receive. #[derive(Debug, Clone, Copy, PartialEq, Eq, PartialOrd, Ord)] pub enum MidiConfig { - /// The plugin will not have a note input port and will thus not receive any not events. + /// The plugin will not have a note input or output port and will thus not receive any not + /// events. None, /// The plugin receives note on/off/choke events, pressure, and potentially a couple /// standardized expression types depending on the plugin standard and host. If the plugin sets /// up configuration for polyphonic modulation (see [`ClapPlugin`][crate::prelude::ClapPlugin]) /// and assigns polyphonic modulation IDs to some of its parameters, then it will also receive - /// polyphonic modulation events. + /// polyphonic modulation events. This level is also needed to be able to send SysEx events. Basic, /// The plugin receives full MIDI CCs as well as pitch bend information. For VST3 plugins this /// involves adding 130*16 parameters to bind to the the 128 MIDI CCs, pitch bend, and channel diff --git a/src/plugin.rs b/src/plugin.rs index a7132391..b8093b70 100644 --- a/src/plugin.rs +++ b/src/plugin.rs @@ -120,7 +120,9 @@ pub trait Plugin: Default + Send + 'static { /// The plugin's SysEx message type if it supports sending or receiving MIDI SysEx messages, or /// `()` if it does not. This type can be a struct or enum wrapping around one or more message /// types, and the [`SysExMessage`] trait is then used to convert between this type and basic - /// byte buffers. + /// byte buffers. The [`MIDI_INPUT`][Self::MIDI_INPUT] and [`MIDI_OUTPUT`][Self::MIDI_OUTPUT] + /// fields need to be set to [`MidiConfig::Basic`] or above to be able to send and receive + /// SysEx. type SysExMessage: SysExMessage; /// A type encoding the different background tasks this plugin wants to run, or `()` if it