Struct Phaser
pub struct Phaser { /* private fields */ }Expand description
Multi-stage all-pass phaser.
Cascades multiple all-pass filters and mixes with dry signal to create the classic phaser comb-filter effect.
Implementations§
§impl Phaser
impl Phaser
pub fn new(num_stages: usize, sample_rate: f64) -> Phaser
pub fn new(num_stages: usize, sample_rate: f64) -> Phaser
Create a new phaser with given number of stages.
Classic Phase 90 uses 4 stages. More stages = deeper effect.
pub fn set_modulation(&mut self, mod_value: f64)
pub fn set_modulation(&mut self, mod_value: f64)
Set the modulation value (typically from LFO, range -1 to +1).
This sweeps the cutoff frequency of all stages together.
pub fn set_base_freq(&mut self, freq: f64)
pub fn set_base_freq(&mut self, freq: f64)
Set the base center frequency (Hz).
pub fn set_mod_depth(&mut self, depth: f64)
pub fn set_mod_depth(&mut self, depth: f64)
Set the modulation depth (frequency sweep range).
pub fn set_feedback(&mut self, feedback: f64)
pub fn set_feedback(&mut self, feedback: f64)
Set feedback amount (0.0 to 0.9).
pub fn reset(&mut self)
pub fn reset(&mut self)
Reset all filter states.
pub fn set_sample_rate(&mut self, sample_rate: f64)
pub fn set_sample_rate(&mut self, sample_rate: f64)
Update sample rate.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Phaser
impl RefUnwindSafe for Phaser
impl Send for Phaser
impl Sync for Phaser
impl Unpin for Phaser
impl UnsafeUnpin for Phaser
impl UnwindSafe for Phaser
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more