pub struct PacketCopy { /* private fields */ }Expand description
One or more copy runs written back to back into one output.
Implementations§
Source§impl PacketCopy
impl PacketCopy
Sourcepub fn join(segments: Vec<PacketCopyPlan>) -> Result<Self, String>
pub fn join(segments: Vec<PacketCopyPlan>) -> Result<Self, String>
Joins runs, in output order, into one copy.
Each run is already a self-contained stretch of its stream starting at an IDR picture, so a decoder restarts at every join. What a join adds is that one sample description must describe every run (the same codec, size, pixel format, parameter sets, and time base), and that decode times keep increasing across it, which fails when the runs reorder pictures differently.
§Errors
Names the join that breaks either, or a run that copies audio in a join (copied audio travels only with one whole file).
Sourcepub fn video_packets(&self) -> u64
pub fn video_packets(&self) -> u64
Video packets the copy writes: one per output frame.
Sourcepub fn copies_audio(&self) -> bool
pub fn copies_audio(&self) -> bool
Whether the source’s audio is copied too.
Sourcepub fn audio_copy_refusal(&self) -> Option<&str>
pub fn audio_copy_refusal(&self) -> Option<&str>
Why the source’s audio, which the request offered to copy, is not.