pub struct Packet {
pub data: Bytes,
pub granule_position: i64,
pub serial: u32,
pub bos: bool,
pub eos: bool,
}Expand description
A fully reassembled Ogg packet (continuation pages already merged).
granule_position/bos/eos are page-level fields (RFC 3533) attached here
to every packet completed while parsing that page — spec-precise only for the
last packet completed on a page; earlier packets on the same page share the
same values as an approximation (documented in crate-local ADR-0001).
Fields§
§data: BytesPacket payload (continuation pages merged).
granule_position: i64The page’s granule position (codec-defined units; e.g. sample count).
serial: u32Logical bitstream serial number.
bos: boolSet if the containing page was the first page of the logical stream.
eos: boolSet if the containing page was the last page of the logical stream.
Trait Implementations§
impl Eq for Packet
impl StructuralPartialEq for Packet
Auto Trait Implementations§
impl !Freeze for Packet
impl RefUnwindSafe for Packet
impl Send for Packet
impl Sync for Packet
impl Unpin for Packet
impl UnsafeUnpin for Packet
impl UnwindSafe for Packet
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