pub struct WavetableOscillator<T: Transcendental, const SIZE: usize> { /* private fields */ }Expand description
Wavetable oscillator built on InterpolatedReader.
The compile-time constant SIZE determines table resolution but the
underlying storage is heap-allocated, sharing the same interpolation
engine with SamplePlayer.
Implementations§
Source§impl<T: Transcendental, const SIZE: usize> WavetableOscillator<T, SIZE>
impl<T: Transcendental, const SIZE: usize> WavetableOscillator<T, SIZE>
Trait Implementations§
Source§impl<T: Transcendental, const SIZE: usize> Algorithm<T> for WavetableOscillator<T, SIZE>
impl<T: Transcendental, const SIZE: usize> Algorithm<T> for WavetableOscillator<T, SIZE>
Source§fn process(
&mut self,
_input: Option<&[T]>,
output: &mut [T],
) -> ProcessResult<()>
fn process( &mut self, _input: Option<&[T]>, output: &mut [T], ) -> ProcessResult<()>
Process one block of signal. Read more
Source§fn metadata(&self) -> AlgorithmMetadata
fn metadata(&self) -> AlgorithmMetadata
Descriptive metadata (defaults to empty).
Source§fn apply_command(&mut self, _value: T)
fn apply_command(&mut self, _value: T)
Receive a real-time command value from the control path. Read more
Source§impl<T: Transcendental, const SIZE: usize> Generator<T> for WavetableOscillator<T, SIZE>
impl<T: Transcendental, const SIZE: usize> Generator<T> for WavetableOscillator<T, SIZE>
Source§fn reset_phase(&mut self)
fn reset_phase(&mut self)
Reset phase to 0
Source§fn set_frequency(&mut self, freq: f32)
fn set_frequency(&mut self, freq: f32)
Set frequency
Source§fn set_amplitude(&mut self, amp: T)
fn set_amplitude(&mut self, amp: T)
Set amplitude
Auto Trait Implementations§
impl<T, const SIZE: usize> Freeze for WavetableOscillator<T, SIZE>where
T: Freeze,
impl<T, const SIZE: usize> RefUnwindSafe for WavetableOscillator<T, SIZE>where
T: RefUnwindSafe,
impl<T, const SIZE: usize> Send for WavetableOscillator<T, SIZE>
impl<T, const SIZE: usize> Sync for WavetableOscillator<T, SIZE>
impl<T, const SIZE: usize> Unpin for WavetableOscillator<T, SIZE>where
T: Unpin,
impl<T, const SIZE: usize> UnsafeUnpin for WavetableOscillator<T, SIZE>where
T: UnsafeUnpin,
impl<T, const SIZE: usize> UnwindSafe for WavetableOscillator<T, SIZE>where
T: UnwindSafe,
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