From e25beb3e0c2531b09d8efd70e858396dcc631dd2 Mon Sep 17 00:00:00 2001 From: metamuffin Date: Mon, 2 Oct 2023 20:02:06 +0200 Subject: add profiles to jhls --- common/src/jhls.rs | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'common/src/jhls.rs') diff --git a/common/src/jhls.rs b/common/src/jhls.rs index 306161f..e3ef23c 100644 --- a/common/src/jhls.rs +++ b/common/src/jhls.rs @@ -5,6 +5,7 @@ use std::ops::Range; #[derive(Debug, Clone, Deserialize, Serialize)] pub struct JhlsMetadata { pub duration: f64, + pub extra_profiles: Vec, pub tracks: Vec, } @@ -13,3 +14,22 @@ pub struct JhlsTrack { pub info: SourceTrack, pub segments: Vec>, } + +#[derive(Debug, Clone, Deserialize, Serialize)] +#[serde(rename_all = "snake_case")] +pub enum EncodingProfile { + Video { + codec: String, + preset: u8, + bitrate: usize, + width: usize, + }, + Audio { + codec: String, + bitrate: usize, + sample_rate: Option, + }, + Subtitles { + codec: String, + }, +} -- cgit v1.2.3-70-g09d2