aboutsummaryrefslogtreecommitdiff
path: root/common/src/lib.rs
diff options
context:
space:
mode:
Diffstat (limited to 'common/src/lib.rs')
-rw-r--r--common/src/lib.rs28
1 files changed, 1 insertions, 27 deletions
diff --git a/common/src/lib.rs b/common/src/lib.rs
index d57d2c0..ec6e0df 100644
--- a/common/src/lib.rs
+++ b/common/src/lib.rs
@@ -7,8 +7,8 @@ pub mod config;
pub mod helpers;
pub mod r#impl;
pub mod stream;
+pub mod seek_index;
-use bincode::{Decode, Encode};
#[cfg(feature = "rocket")]
use rocket::{FromFormField, UriDisplayQuery};
use serde::{Deserialize, Serialize};
@@ -139,29 +139,3 @@ 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)]
-pub struct BlockIndex {
- pub pts: u64,
- 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(),
- }
- }
-}