pub struct ChannelMap { /* private fields */ }Expand description
Ordered channel identities, including unnamed wire channels.
Implementations§
Source§impl ChannelMap
impl ChannelMap
Sourcepub fn from_positions(
positions: Vec<ChannelPosition>,
) -> Result<Self, CaptureError>
pub fn from_positions( positions: Vec<ChannelPosition>, ) -> Result<Self, CaptureError>
Preserve an explicitly ordered map, including unknown positions. Indices on unnamed channels must match their zero-based position on the wire.
Sourcepub fn uac1(channels: u16, mask: u16) -> Result<Self, CaptureError>
pub fn uac1(channels: u16, mask: u16) -> Result<Self, CaptureError>
Decode UAC1’s wChannelConfig (Audio 1.0 section 3.7.2.3).
Sourcepub fn uac2(channels: u16, mask: u32) -> Result<Self, CaptureError>
pub fn uac2(channels: u16, mask: u32) -> Result<Self, CaptureError>
Decode UAC2’s bmChannelConfig (Audio 2.0 section 3.7.2.1). Bit 31 indicates non-predefined positions, rather than another speaker.
pub fn positions(&self) -> &[ChannelPosition]
Trait Implementations§
Source§impl Clone for ChannelMap
impl Clone for ChannelMap
Source§impl Debug for ChannelMap
impl Debug for ChannelMap
impl Eq for ChannelMap
Source§impl PartialEq for ChannelMap
impl PartialEq for ChannelMap
impl StructuralPartialEq for ChannelMap
Auto Trait Implementations§
impl Forget for ChannelMap
impl Freeze for ChannelMap
impl Move for ChannelMap
impl RefUnwindSafe for ChannelMap
impl Send for ChannelMapwhere
RawVecInner: Send,
impl Sync for ChannelMapwhere
RawVecInner: Sync,
impl Unpin for ChannelMap
impl UnsafeUnpin for ChannelMap
impl UnwindSafe for ChannelMapwhere
RawVecInner: UnwindSafe,
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