pub enum CacheCapsStereo {
Mono,
Stereo,
}Expand description
§4.3.3 stereo-axis selector.
The stereo axis of CACHE_CAPS50 is binary: mono = 0, stereo
= 1. Modelled as a typed enum so the caller can’t confuse it with
the channel-count multiplier of init_caps (which is 1 or
2, not 0 or 1).
Variants§
Implementations§
Source§impl CacheCapsStereo
impl CacheCapsStereo
Sourcepub const fn axis_index(self) -> usize
pub const fn axis_index(self) -> usize
Stereo-axis index into the §4.3.3 row-stride 2*LM + stereo.
Sourcepub const fn channels(self) -> u32
pub const fn channels(self) -> u32
channels multiplier consumed by the §4.3.3 init_caps()
conversion (1 for mono, 2 for stereo).
Sourcepub const fn from_is_stereo(is_stereo: bool) -> Self
pub const fn from_is_stereo(is_stereo: bool) -> Self
Decode a raw bool channel-count signal (false = mono, true = stereo) into a selector. Use this when the upstream
signal is the TOC stereo-flag boolean from §3.1.
Trait Implementations§
Source§impl Clone for CacheCapsStereo
impl Clone for CacheCapsStereo
Source§fn clone(&self) -> CacheCapsStereo
fn clone(&self) -> CacheCapsStereo
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for CacheCapsStereo
Source§impl Debug for CacheCapsStereo
impl Debug for CacheCapsStereo
impl Eq for CacheCapsStereo
Source§impl PartialEq for CacheCapsStereo
impl PartialEq for CacheCapsStereo
Source§fn eq(&self, other: &CacheCapsStereo) -> bool
fn eq(&self, other: &CacheCapsStereo) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for CacheCapsStereo
Auto Trait Implementations§
impl Freeze for CacheCapsStereo
impl RefUnwindSafe for CacheCapsStereo
impl Send for CacheCapsStereo
impl Sync for CacheCapsStereo
impl Unpin for CacheCapsStereo
impl UnsafeUnpin for CacheCapsStereo
impl UnwindSafe for CacheCapsStereo
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