Struct synfx_dsp_jit::engine::CodeEngineBackend
source · [−]pub struct CodeEngineBackend { /* private fields */ }
Expand description
The backend handle for a CodeEngine.
You get this from a call to CodeEngine::get_backend. Make sure to set it up properly with CodeEngineBackend::set_sample_rate and regularily call CodeEngineBackend::process_updates for receiving updated DSPFunction instances from CodeEngine::upload.
Implementations
sourceimpl CodeEngineBackend
impl CodeEngineBackend
pub fn process(
&mut self,
in1: f32,
in2: f32,
a: f32,
b: f32,
d: f32,
g: f32
) -> (f32, f32, f32)
sourcepub fn set_sample_rate(&mut self, srate: f32)
pub fn set_sample_rate(&mut self, srate: f32)
Update/set the sample rate for the DSP function. This will also reset the state of the DSP function.
sourcepub fn process_updates(&mut self)
pub fn process_updates(&mut self)
Process updates received from the thread running the CodeEngine.
Auto Trait Implementations
impl !RefUnwindSafe for CodeEngineBackend
impl Send for CodeEngineBackend
impl Sync for CodeEngineBackend
impl Unpin for CodeEngineBackend
impl !UnwindSafe for CodeEngineBackend
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more