Skip to main content

PluginContextReadF32

Trait PluginContextReadF32 

Source
pub trait PluginContextReadF32 {
    // Required methods
    fn get_param(&self, id: impl Into<u32>) -> f32;
    fn get_param_plain(&self, id: impl Into<u32>) -> f32;
}
Expand description

f32-precision parameter reads on PluginContext. Brought into scope by truce::prelude / truce::prelude32 / truce::prelude64m (the f32-buffer preludes). GUI binding crates (slint, egui, iced) take f32 natively, so this is the common case.

Required Methods§

Source

fn get_param(&self, id: impl Into<u32>) -> f32

Normalized [0, 1] value of the parameter, narrowed to f32.

Source

fn get_param_plain(&self, id: impl Into<u32>) -> f32

Plain (denormalized) value of the parameter, narrowed to f32.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§