mirror of
https://github.com/mpv-player/mpv.git
synced 2025-12-22 10:57:08 +00:00
Revert "ytdl_hook: add option to extract chapters"
This reverts commit df1e71a7cc.
The next commit will make this unused since chapters will only be taken
from yt-dlp's JSON.
This commit is contained in:
@@ -1 +0,0 @@
|
||||
add `--ytdl-extract-chapters` option
|
||||
@@ -1036,9 +1036,6 @@ Program Behavior
|
||||
- ``--ytdl-raw-options=proxy=[http://127.0.0.1:3128]``
|
||||
- ``--ytdl-raw-options-append=proxy=http://127.0.0.1:3128``
|
||||
|
||||
``--ytdl-extract-chapters=<yes|no>``
|
||||
Enable chapter extracting from youtube-dl video description (default: yes).
|
||||
|
||||
``--js-memory-report=<yes|no>``
|
||||
Enable memory reporting for javascript scripts in the stats overlay.
|
||||
This is disabled by default because it has an overhead and increases
|
||||
|
||||
@@ -563,7 +563,6 @@ static const m_option_t mp_opts[] = {
|
||||
{"ytdl", OPT_BOOL(lua_load_ytdl), .flags = UPDATE_BUILTIN_SCRIPTS},
|
||||
{"ytdl-format", OPT_STRING(lua_ytdl_format)},
|
||||
{"ytdl-raw-options", OPT_KEYVALUELIST(lua_ytdl_raw_options)},
|
||||
{"ytdl-extract-chapters", OPT_BOOL(lua_ytdl_extract_chapters)},
|
||||
{"load-stats-overlay", OPT_BOOL(lua_load_stats),
|
||||
.flags = UPDATE_BUILTIN_SCRIPTS},
|
||||
{"load-console", OPT_BOOL(lua_load_console),
|
||||
@@ -1004,7 +1003,6 @@ static const struct MPOpts mp_default_opts = {
|
||||
.lua_load_ytdl = true,
|
||||
.lua_ytdl_format = NULL,
|
||||
.lua_ytdl_raw_options = NULL,
|
||||
.lua_ytdl_extract_chapters = true,
|
||||
.lua_load_stats = true,
|
||||
.lua_load_console = true,
|
||||
.lua_load_auto_profiles = -1,
|
||||
|
||||
@@ -185,7 +185,6 @@ typedef struct MPOpts {
|
||||
bool lua_load_ytdl;
|
||||
char *lua_ytdl_format;
|
||||
char **lua_ytdl_raw_options;
|
||||
bool lua_ytdl_extract_chapters;
|
||||
bool lua_load_stats;
|
||||
bool lua_load_console;
|
||||
int lua_load_auto_profiles;
|
||||
|
||||
@@ -829,8 +829,7 @@ local function add_single_video(json)
|
||||
end
|
||||
table.insert(chapter_list, {time=chapter.start_time, title=title})
|
||||
end
|
||||
elseif json.description ~= nil and json.duration ~= nil and
|
||||
mp.get_property_bool("ytdl-extract-chapters") then
|
||||
elseif json.description ~= nil and json.duration ~= nil then
|
||||
chapter_list = extract_chapters(json.description, json.duration)
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user