pub trait SimpleFFGLInstance: FFGLInstance {
// Required methods
fn new(inst_data: &FFGLData) -> Self;
fn plugin_info() -> PluginInfo;
fn draw(&mut self, inst_data: &FFGLData, frame_data: GLInput<'_>);
// Provided methods
fn num_params() -> usize { ... }
fn param_info(_index: usize) -> &'static dyn ParamInfo { ... }
fn get_param(&self, _index: usize) -> f32 { ... }
fn set_param(&mut self, _index: usize, _value: f32) { ... }
}Expand description
Implement this trait for a plugin without any static state
Required Methods§
fn new(inst_data: &FFGLData) -> Self
fn plugin_info() -> PluginInfo
Sourcefn draw(&mut self, inst_data: &FFGLData, frame_data: GLInput<'_>)
fn draw(&mut self, inst_data: &FFGLData, frame_data: GLInput<'_>)
Called by crate::conversions::Op::ProcessOpenGL to draw the plugin
Provided Methods§
fn num_params() -> usize
fn param_info(_index: usize) -> &'static dyn ParamInfo
fn get_param(&self, _index: usize) -> f32
fn set_param(&mut self, _index: usize, _value: f32)
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.