mirror of
https://github.com/truewhile/MeBox.git
synced 2026-10-10 23:36:37 +08:00
feat: improve cloud media playback and Emby compatibility
Based on nowen-video and MoviePilot implementations: - Mark STRM media as IsRemote=true in Emby MediaSource - Improve cloud media identification using STRMURL field - Clean up unused cloud play service scaffolding - Ensure third-party players (Infuse/Emby) recognize cloud media correctly
This commit is contained in:
@@ -1493,6 +1493,7 @@ func (e *EmbyService) mediaSource(m *model.Media, asEmbedded, directOnly bool) m
|
||||
if container == "" && strings.TrimSpace(m.STRMURL) != "" {
|
||||
container = "strm"
|
||||
}
|
||||
isCloud := strings.TrimSpace(m.STRMURL) != ""
|
||||
src := map[string]any{
|
||||
"Id": m.ID,
|
||||
"Name": m.Title,
|
||||
@@ -1501,7 +1502,7 @@ func (e *EmbyService) mediaSource(m *model.Media, asEmbedded, directOnly bool) m
|
||||
"Size": m.SizeBytes,
|
||||
"Protocol": "Http",
|
||||
"Type": "Default",
|
||||
"IsRemote": false,
|
||||
"IsRemote": isCloud,
|
||||
"RequiresOpening": false,
|
||||
"RequiresClosing": false,
|
||||
"ReadAtNativeFramerate": false,
|
||||
@@ -1670,3 +1671,5 @@ func intToStr(v int) string {
|
||||
}
|
||||
return strconv.Itoa(v)
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user