pub struct ChunkPosition {
pub source_byte_offset: Option<u64>,
pub sample_rate: u32,
pub end_position_ns: u64,
pub frame_offset: u64,
pub frames: u64,
pub source_bytes: u64,
}Expand description
Decoder-reported chunk position used to advance the timeline.
This struct is the kithara-stream-local mirror of the fields
Timeline::advance_committed_chunk needs from a decoder’s
per-chunk metadata. It exists because PcmMeta lives in
kithara-decode (which depends on kithara-stream); a tiny mirror
avoids the circular dep without forcing decoders to fragment their
existing meta type.
Decoder backends fill it from their own meta — see
From<&PcmMeta> for ChunkPosition in kithara-decode.
Fields§
§source_byte_offset: Option<u64>Absolute byte offset of the chunk’s source data when the
decoder reports it (Apple mStartOffset, Android API 28+).
sample_rate: u32§end_position_ns: u64Decoder-reported wall-clock position after the chunk has
been emitted (or, for Timeline::commit_seek_landed, the
landed position). Authoritative — derived from the decoder’s
own frame counter inside its own arithmetic, so the timeline
never recomputes frames * 1e9 / sample_rate. Always strictly
greater than (or equal to, for seek landings) the chunk start.
frame_offset: u64Absolute frame offset of the first frame in the chunk.
frames: u64Number of frames the chunk covers.
source_bytes: u64Source bytes the chunk decoded from (decoder ground truth).
Trait Implementations§
Source§impl Clone for ChunkPosition
impl Clone for ChunkPosition
Source§fn clone(&self) -> ChunkPosition
fn clone(&self) -> ChunkPosition
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more