summaryrefslogtreecommitdiffstats
path: root/player
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2014-11-19 18:51:53 +0100
committerwm4 <wm4@nowhere>2014-11-19 18:59:38 +0100
commit079ecd7f017be7528ab597e5db36042a0eecee0d (patch)
tree2518efcadb7d06971ef26b4de1636bfa1206b850 /player
parent0f7df894688d7d2d4b5745944d9b84aeb512f1ae (diff)
downloadmpv-079ecd7f017be7528ab597e5db36042a0eecee0d.tar.bz2
mpv-079ecd7f017be7528ab597e5db36042a0eecee0d.tar.xz
player: integrate ytdl_hook.lua
Diffstat (limited to 'player')
-rw-r--r--player/lua.c3
-rw-r--r--player/scripting.c2
2 files changed, 5 insertions, 0 deletions
diff --git a/player/lua.c b/player/lua.c
index 699c928e87..8a2e3ec925 100644
--- a/player/lua.c
+++ b/player/lua.c
@@ -65,6 +65,9 @@ static const char * const builtin_lua_scripts[][2] = {
{"@osc.lua",
# include "player/lua/osc.inc"
},
+ {"@ytdl_hook.lua",
+# include "player/lua/ytdl_hook.inc"
+ },
{0}
};
diff --git a/player/scripting.c b/player/scripting.c
index 982d64a3cd..f2ddcec2aa 100644
--- a/player/scripting.c
+++ b/player/scripting.c
@@ -177,6 +177,8 @@ void mp_load_scripts(struct MPContext *mpctx)
// Load scripts from options
if (mpctx->opts->lua_load_osc)
mp_load_script(mpctx, "@osc.lua");
+ if (mpctx->opts->lua_load_ytdl)
+ mp_load_script(mpctx, "@ytdl_hook.lua");
char **files = mpctx->opts->lua_files;
for (int n = 0; files && files[n]; n++) {
if (files[n][0])