pub struct Frame {
pub timestamp: Timestamp,
pub data: Bytes,
}Expand description
One unit of raw PCM crossing the codec boundary: what
encode::Producer::write takes and what
decode::Consumer::read returns.
Just a payload and a presentation timestamp. PCM layout (format / sample rate / channel count) is fixed by the producer or consumer at construction time, never per frame, so callers can’t accidentally drift the format mid-stream.
Fields§
§timestamp: TimestampPresentation timestamp of the first sample.
data: BytesThe samples, in the layout the producer or consumer was built with.
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for Frame
impl RefUnwindSafe for Frame
impl Send for Frame
impl Sync for Frame
impl Unpin for Frame
impl UnsafeUnpin for Frame
impl UnwindSafe for Frame
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