Skip to main content

enter_plugin

Function enter_plugin 

Source
pub fn enter_plugin<P>(plugin: &PluginCell<P>) -> PluginGuard<'_, P>
Expand description

Take ownership of the plugin for the current callback. Never blocks: the audio thread owns the plugin while active, the host thread while inactive, and the host contract keeps the two from overlapping, so there is nothing to wait on. The returned guard’s &mut is exclusive by that contract; the Acquire inside observes the previous owner’s writes.