pub struct Pcm {
pub fourcc: FourCC,
pub audio: Audio,
pub pcmc: Option<PcmC>,
pub chnl: Option<Chnl>,
pub btrt: Option<Btrt>,
}Fields§
§fourcc: FourCC§audio: Audio§pcmc: Option<PcmC>§chnl: Option<Chnl>§btrt: Option<Btrt>Implementations§
Source§impl Pcm
impl Pcm
pub fn decode_with_fourcc<B: Buf>(fourcc: FourCC, buf: &mut B) -> Result<Self>
pub fn encode_with_fourcc<B: BufMut>(&self, buf: &mut B) -> Result<()>
Sourcepub fn format(&self) -> Option<PcmFormat>
pub fn format(&self) -> Option<PcmFormat>
Returns the resolved sample format of this entry.
The pcmC box wins when present. Otherwise the format implied by the
fourcc is used:
twos: big-endian integer,sample_sizebits (8 or 16 per QTFF-2001)sowt: little-endian integer,sample_sizebits (8 or 16 per QTFF-2001)in24/in32: big-endian integer, 24 / 32 bitsfl32/fl64: big-endian float, 32 / 64 bitss16l: little-endian integer, 16 bitslpcm: QTFF format flags are only defined for version 2 sound sample descriptions, which are not decoded here; defaults to big-endian integer,sample_sizebits
Returns None for an unknown fourcc, or for an ipcm/fpcm entry
missing its mandatory pcmC box (which
decode_with_fourcc never produces).
Trait Implementations§
impl Eq for Pcm
impl StructuralPartialEq for Pcm
Auto Trait Implementations§
impl Freeze for Pcm
impl RefUnwindSafe for Pcm
impl Send for Pcm
impl Sync for Pcm
impl Unpin for Pcm
impl UnsafeUnpin for Pcm
impl UnwindSafe for Pcm
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