Struct synth_utils::glide_processor::GlideProcessor
source · pub struct GlideProcessor { /* private fields */ }Expand description
A glide processor for implementing portamento is represented here.
Implementations§
source§impl GlideProcessor
impl GlideProcessor
sourcepub fn new(sample_rate_hz: f32) -> Self
pub fn new(sample_rate_hz: f32) -> Self
GlideProcessor::new(sr) is a new glide processor with sample rate sr
sourcepub fn set_time(&mut self, t: f32)
pub fn set_time(&mut self, t: f32)
gp.set_time(t) sets the portamento time for the glide processor to the new time t
Arguments:
t- the new value for the glide control time, in[0.0, 10.0]
Times that would be faster than sample_rate/2 are clamped.
This function can be somewhat costly, so don’t call it more than necessary