select.lua: support extracting ytdl_hook subtitles

They don't work because they have EDL URLs, but we can attempt to
extract their real URLs.
This commit is contained in:
Guido Cella authored and Kacper Michajłow committed 2024-06-07 22:45:41 +02:00
1 parent 5657cd65b7
commit 75645263dd
1 file changed
+5
+5
View File
@@ -195,6 +195,11 @@ mp.add_forced_key_binding(nil, "select-subtitle-line", function ()
return
end
if sub.external and sub["external-filename"]:find("^edl://") then
sub["external-filename"] = sub["external-filename"]:match('https?://.*')
or sub["external-filename"]
end
local r = mp.command_native({
name = "subprocess",
capture_stdout = true,