pub struct I24_4LJ_BE(/* private fields */);Expand description
24 bit signed integer, big endian. Stored as 4 bytes left justified. The 24 data bits are stored in the three most significant bytes, while the least significant byte is unused padding.
Trait Implementations§
Source§impl BytesSample for I24_4LJ_BE
24 bit signed integer, big endian, stored as 4 bytes left justified.
The data is in the upper 3 bytes and the least significant byte is padding.
impl BytesSample for I24_4LJ_BE
24 bit signed integer, big endian, stored as 4 bytes left justified. The data is in the upper 3 bytes and the least significant byte is padding.
Source§const BYTES_PER_SAMPLE: usize
const BYTES_PER_SAMPLE: usize
The number of bytes making up each sample value.
Source§type NumericType = i32
type NumericType = i32
The closest matching numeric type.
Source§fn from_slice(bytes: &[u8]) -> Self
fn from_slice(bytes: &[u8]) -> Self
Create a new ByteSample from a slice of raw bytes.
The slice length must be at least the number of bytes
for a sample value.
Source§fn as_mut_slice(&mut self) -> &mut [u8] ⓘ
fn as_mut_slice(&mut self) -> &mut [u8] ⓘ
Return the raw bytes as a mutable slice.
Source§fn to_number(&self) -> Self::NumericType
fn to_number(&self) -> Self::NumericType
Convert the raw bytes to a numerical value.
Source§fn from_number(value: Self::NumericType) -> Self
fn from_number(value: Self::NumericType) -> Self
Convert a numerical value to raw bytes.
Source§impl Clone for I24_4LJ_BE
impl Clone for I24_4LJ_BE
Source§fn clone(&self) -> I24_4LJ_BE
fn clone(&self) -> I24_4LJ_BE
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for I24_4LJ_BE
impl Debug for I24_4LJ_BE
Source§impl Sample for I24_4LJ_BE
impl Sample for I24_4LJ_BE
Source§const ZERO: I24_4LJ_BE
const ZERO: I24_4LJ_BE
The zero pattern for the sample.
impl Copy for I24_4LJ_BE
Auto Trait Implementations§
impl Freeze for I24_4LJ_BE
impl RefUnwindSafe for I24_4LJ_BE
impl Send for I24_4LJ_BE
impl Sync for I24_4LJ_BE
impl Unpin for I24_4LJ_BE
impl UnsafeUnpin for I24_4LJ_BE
impl UnwindSafe for I24_4LJ_BE
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<V> RawSample for V
impl<V> RawSample for V
Source§fn to_scaled_float<T>(&self) -> Twhere
T: FloatCore + ToPrimitive,
fn to_scaled_float<T>(&self) -> Twhere
T: FloatCore + ToPrimitive,
Convert the sample value to a float in the range -1.0 .. +1.0.
Source§fn from_scaled_float<T>(value: T) -> ConversionResult<V>where
T: FloatCore + ToPrimitive,
fn from_scaled_float<T>(value: T) -> ConversionResult<V>where
T: FloatCore + ToPrimitive,
Convert a float in the range -1.0 .. +1.0 to a sample value.
Values outside the allowed range are clipped to the nearest limit.