diff options
author | metamuffin <metamuffin@disroot.org> | 2023-09-30 15:21:57 +0200 |
---|---|---|
committer | metamuffin <metamuffin@disroot.org> | 2023-09-30 15:21:57 +0200 |
commit | 30e3d18c6ec50572365baaaaa3542769e82e763a (patch) | |
tree | 3eade459fe488729bbe61dd85ac49948d5e24ef7 /common/src/lib.rs | |
parent | d0d8316a015fa0434c2871541b83ea0aca781a99 (diff) | |
download | jellything-30e3d18c6ec50572365baaaaa3542769e82e763a.tar jellything-30e3d18c6ec50572365baaaaa3542769e82e763a.tar.bz2 jellything-30e3d18c6ec50572365baaaaa3542769e82e763a.tar.zst |
move some files around for new remuxer + small changes
Diffstat (limited to 'common/src/lib.rs')
-rw-r--r-- | common/src/lib.rs | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/common/src/lib.rs b/common/src/lib.rs index b7f975a..d57d2c0 100644 --- a/common/src/lib.rs +++ b/common/src/lib.rs @@ -140,9 +140,13 @@ pub enum SourceTrackKind { Subtitles, } +pub const SEEK_INDEX_VERSION: u32 = 0x5eef1de4; + #[derive(Debug, Clone, Decode, Encode)] pub struct SeekIndex { + pub version: u32, pub blocks: Vec<BlockIndex>, + pub keyframes: Vec<usize>, } #[derive(Debug, Clone, Decode, Encode)] @@ -151,3 +155,13 @@ pub struct BlockIndex { pub source_off: usize, pub size: usize, } + +impl Default for SeekIndex { + fn default() -> Self { + Self { + version: SEEK_INDEX_VERSION, + blocks: Vec::new(), + keyframes: Vec::new(), + } + } +} |