Struct hexodsp::shared_feedback::SharedFeedbackWriter
source · [−]pub struct SharedFeedbackWriter {
buffer: Arc<Vec<AtomicFloat>>,
write_ptr: usize,
delay_sample_count: usize,
}
Expand description
This instance writes into the SharedFeedback buffer.
Even though it’s safe to have multiple writers of this will not work
or produce any meaningful results. The goal is really, that one FbWr
DSP node
in the audio thread writes the buffer, and one (or multiple) FbRd
DSP nodes
read from that SharedFeedback buffer via a SharedFeedbackReader.
Fields
buffer: Arc<Vec<AtomicFloat>>
write_ptr: usize
delay_sample_count: usize
Implementations
pub fn new(sfb: &SharedFeedback) -> Self
sourcepub fn write(&mut self, s: f32)
pub fn write(&mut self, s: f32)
Write the next sample in to the feedback buffer.
Even though it’s safe to have multiple writers of this will not work
or produce any meaningful results. The goal is really, that one FbWr
DSP node
on the audio thread writing the buffer per buffer iteration. And then one or more
FbRd
DSP node reading from that buffer.
Trait Implementations
sourcefn clone(&self) -> SharedFeedbackWriter
fn clone(&self) -> SharedFeedbackWriter
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations
Blanket Implementations
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more