Upload 43 files
Browse files
src/routes/invidious_routes/videos.ts
CHANGED
|
@@ -53,6 +53,9 @@ interface AdaptiveFormat {
|
|
| 53 |
audioQuality: string;
|
| 54 |
audioSampleRate: number;
|
| 55 |
audioChannels: number;
|
|
|
|
|
|
|
|
|
|
| 56 |
}
|
| 57 |
|
| 58 |
interface FormatStream {
|
|
@@ -67,6 +70,7 @@ interface FormatStream {
|
|
| 67 |
qualityLabel: string;
|
| 68 |
container: string;
|
| 69 |
encoding: string;
|
|
|
|
| 70 |
}
|
| 71 |
|
| 72 |
interface RecommendedVideo {
|
|
@@ -163,6 +167,9 @@ function convertAdaptiveFormat(format: any): AdaptiveFormat {
|
|
| 163 |
audioQuality: format.audioQuality ?? "",
|
| 164 |
audioSampleRate: format.audioSampleRate ? parseInt(format.audioSampleRate) : 0,
|
| 165 |
audioChannels: format.audioChannels ?? 0,
|
|
|
|
|
|
|
|
|
|
| 166 |
};
|
| 167 |
}
|
| 168 |
|
|
@@ -180,6 +187,7 @@ function convertFormatStream(format: any): FormatStream {
|
|
| 180 |
qualityLabel: format.qualityLabel ?? "",
|
| 181 |
container,
|
| 182 |
encoding,
|
|
|
|
| 183 |
};
|
| 184 |
}
|
| 185 |
|
|
|
|
| 53 |
audioQuality: string;
|
| 54 |
audioSampleRate: number;
|
| 55 |
audioChannels: number;
|
| 56 |
+
resolution: string;
|
| 57 |
+
qualityLabel: string;
|
| 58 |
+
quality: string;
|
| 59 |
}
|
| 60 |
|
| 61 |
interface FormatStream {
|
|
|
|
| 70 |
qualityLabel: string;
|
| 71 |
container: string;
|
| 72 |
encoding: string;
|
| 73 |
+
clen?: string;
|
| 74 |
}
|
| 75 |
|
| 76 |
interface RecommendedVideo {
|
|
|
|
| 167 |
audioQuality: format.audioQuality ?? "",
|
| 168 |
audioSampleRate: format.audioSampleRate ? parseInt(format.audioSampleRate) : 0,
|
| 169 |
audioChannels: format.audioChannels ?? 0,
|
| 170 |
+
resolution: format.qualityLabel ?? "",
|
| 171 |
+
qualityLabel: format.qualityLabel ?? "",
|
| 172 |
+
quality: format.quality ?? "medium",
|
| 173 |
};
|
| 174 |
}
|
| 175 |
|
|
|
|
| 187 |
qualityLabel: format.qualityLabel ?? "",
|
| 188 |
container,
|
| 189 |
encoding,
|
| 190 |
+
clen: format.contentLength ? String(format.contentLength) : "",
|
| 191 |
};
|
| 192 |
}
|
| 193 |
|