database support

This commit is contained in:
Simon
2025-06-05 18:50:26 +00:00
parent 52081698e9
commit 6d08362937

View File

@@ -157,14 +157,15 @@ pub struct Video_Format {
video_ext: Option<String>,
resolution: Option<String>,
http_headers: Option<HashMap<String, String>>,
}
impl Video_Format {
pub fn new(url: String, quality: String, format: String) -> Self {
Video_Format {
url,
quality,
format,
format_id: None,
format: "mp4".to_string(), // Default format
format_id: Some("mp4-1080".to_string()),
format_note: None,
filesize: None,
asr: None,
@@ -174,16 +175,16 @@ impl Video_Format {
tbr: None,
language: None,
language_preference: None,
ext: None,
ext: Some("mp4".to_string()),
vcodec: None,
acodec: None,
dynamic_range: None,
abr: None,
vbr: None,
container: None,
protocol: None,
audio_ext: None,
video_ext: None,
protocol: Some("m3u8_native".to_string()),
audio_ext: Some("none".to_string()),
video_ext: Some("mp4".to_string()),
resolution: None,
http_headers: None,
}