pub struct AtomicEqParams { /* private fields */ }Expand description
EQ parameters published as complete immutable snapshots.
Implementations§
Source§impl AtomicEqParams
impl AtomicEqParams
Sourcepub fn write(&self, gains: &[f64; 10], enabled: bool)
pub fn write(&self, gains: &[f64; 10], enabled: bool)
Publish all EQ parameters as a complete snapshot.
Sourcepub fn read(&self) -> EqParamsSnapshot
pub fn read(&self) -> EqParamsSnapshot
Read the current EQ parameter snapshot.
pub fn load(&self) -> Arc<EqParamsSnapshot>
pub fn load_with_generation(&self) -> (Arc<EqParamsSnapshot>, u64)
pub fn load_if_changed( &self, cached: &Arc<EqParamsSnapshot>, ) -> Option<Arc<EqParamsSnapshot>>
pub fn load_if_changed_since( &self, cached_generation: u64, ) -> Option<(Arc<EqParamsSnapshot>, u64)>
Sourcepub fn set_band_gain(&self, band: usize, gain_db: f64)
pub fn set_band_gain(&self, band: usize, gain_db: f64)
Update a single band gain by patching and publishing a new snapshot.
Sourcepub fn set_enabled(&self, enabled: bool)
pub fn set_enabled(&self, enabled: bool)
Set enabled state (main thread)
pub fn is_enabled(&self) -> bool
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for AtomicEqParams
impl RefUnwindSafe for AtomicEqParams
impl Send for AtomicEqParams
impl Sync for AtomicEqParams
impl Unpin for AtomicEqParams
impl UnsafeUnpin for AtomicEqParams
impl UnwindSafe for AtomicEqParams
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
impl<S, T> Duplex<S> for Twhere
T: FromSample<S> + ToSample<S>,
Source§impl<S> FromSample<S> for S
impl<S> FromSample<S> for S
fn from_sample_(s: S) -> S
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more