pub struct Packet {
pub data: Buffer,
pub pts: i64,
pub dts: i64,
pub duration: i64,
pub stream_index: usize,
pub flags: PacketFlags,
pub pos: i64,
pub side_data: Vec<PacketSideData>,
pub trim_start: u32,
pub trim_end: u32,
}Expand description
Encoded packet, matching FFmpeg’s AVPacket concept.
Fields§
§data: BufferCompressed data buffer.
pts: i64Presentation timestamp in time_base units.
dts: i64Decompression timestamp in time_base units.
duration: i64Duration in time_base units.
stream_index: usizeStream index this packet belongs to.
flags: PacketFlags§pos: i64Position in the stream (byte offset), or -1 if unknown.
side_data: Vec<PacketSideData>§trim_start: u32Number of decoded samples to trim from the start of the decoded packet (encoder delay / priming). Used for gapless playback.
trim_end: u32Number of decoded samples to trim from the end of the decoded packet (encoder padding). Used for gapless playback.
Implementations§
Trait Implementations§
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