mirror of
https://github.com/streamyfin/streamyfin.git
synced 2025-08-20 18:37:18 +02:00
fix: use ts for downloads
This commit is contained in:
@@ -78,7 +78,7 @@ export const getStreamUrl = async ({
|
|||||||
|
|
||||||
if (transcodeUrl) {
|
if (transcodeUrl) {
|
||||||
if (download) {
|
if (download) {
|
||||||
transcodeUrl = transcodeUrl.replace("master.m3u8", "stream.mp4");
|
transcodeUrl = transcodeUrl.replace("master.m3u8", "stream");
|
||||||
}
|
}
|
||||||
console.log("Video is being transcoded:", transcodeUrl);
|
console.log("Video is being transcoded:", transcodeUrl);
|
||||||
return {
|
return {
|
||||||
@@ -99,11 +99,13 @@ export const getStreamUrl = async ({
|
|||||||
allowVideoStreamCopy: true,
|
allowVideoStreamCopy: true,
|
||||||
allowAudioStreamCopy: true,
|
allowAudioStreamCopy: true,
|
||||||
playSessionId: sessionId || "",
|
playSessionId: sessionId || "",
|
||||||
|
container: "ts",
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
const streamParams = new URLSearchParams({
|
const streamParams = new URLSearchParams({
|
||||||
static: "true",
|
static: "true",
|
||||||
|
container: "mp4",
|
||||||
mediaSourceId: mediaSource?.Id || "",
|
mediaSourceId: mediaSource?.Id || "",
|
||||||
subtitleStreamIndex: subtitleStreamIndex?.toString() || "",
|
subtitleStreamIndex: subtitleStreamIndex?.toString() || "",
|
||||||
audioStreamIndex: audioStreamIndex?.toString() || "",
|
audioStreamIndex: audioStreamIndex?.toString() || "",
|
||||||
@@ -117,7 +119,7 @@ export const getStreamUrl = async ({
|
|||||||
|
|
||||||
const directPlayUrl = `${
|
const directPlayUrl = `${
|
||||||
api.basePath
|
api.basePath
|
||||||
}/Videos/${item.Id}/stream.mp4?${streamParams.toString()}`;
|
}/Videos/${item.Id}/stream?${streamParams.toString()}`;
|
||||||
|
|
||||||
console.log("Video is being direct played:", directPlayUrl);
|
console.log("Video is being direct played:", directPlayUrl);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user