pub struct CustomChannel { /* private fields */ }Expand description
One entry of a custom channel map — the AV_CHANNEL_ORDER_CUSTOM
arm of ChannelLayoutTicket.
name is FFmpeg’s inline char[16], carried as the sixteen bytes
it is. It is a NUL-padded label, not a Rust string: FFmpeg’s own
contract is “may be filled with a 0-terminated string … otherwise
it must be zeroed”, so the bytes cross verbatim and any decoding
into text is the consumer’s choice, not the mirror’s.
Implementations§
Source§impl CustomChannel
impl CustomChannel
Sourcepub const fn new(id: i32, name: [u8; 16]) -> Self
pub const fn new(id: i32, name: [u8; 16]) -> Self
Constructs a CustomChannel from a raw AVChannel id and the
sixteen name bytes.
Sourcepub const fn id(&self) -> i32
pub const fn id(&self) -> i32
The raw AVChannel id. Negative values are real: AV_CHAN_NONE
is -1.
Sourcepub const fn name_bytes(&self) -> &[u8; 16]
pub const fn name_bytes(&self) -> &[u8; 16]
The sixteen name bytes, NUL-padded, exactly as FFmpeg holds them.
Trait Implementations§
Source§impl Clone for CustomChannel
impl Clone for CustomChannel
Source§fn clone(&self) -> CustomChannel
fn clone(&self) -> CustomChannel
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 CustomChannel
Source§impl Debug for CustomChannel
impl Debug for CustomChannel
Source§impl Default for CustomChannel
impl Default for CustomChannel
Source§fn default() -> CustomChannel
fn default() -> CustomChannel
Returns the “default value” for a type. Read more
impl Eq for CustomChannel
Source§impl Hash for CustomChannel
impl Hash for CustomChannel
Source§impl PartialEq for CustomChannel
impl PartialEq for CustomChannel
impl StructuralPartialEq for CustomChannel
Auto Trait Implementations§
impl Freeze for CustomChannel
impl RefUnwindSafe for CustomChannel
impl Send for CustomChannel
impl Sync for CustomChannel
impl Unpin for CustomChannel
impl UnsafeUnpin for CustomChannel
impl UnwindSafe for CustomChannel
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