From 69d062ce373be7884bbde85e2b03f5c0f5789e05 Mon Sep 17 00:00:00 2001 From: wm4 Date: Thu, 11 Jan 2018 23:36:07 +0100 Subject: client API: remove ytdl=no default With the recent changes to the script it does not incur a startup delay by default due to starting youtube-dl and waiting for it. This was the main reason for making libmpv have a different default. Starting sub processes from a library can still be a bit fishy, but I think it's ok. Still mention it in the libmpv header. There were already other cases where libmpv would start its own processes, such as the X11 backend calling xdg-screensaver. (The reason why this is fishy is because UNIX process management sucks: SIGCHLD and the wait() syscall make sub processes non-transparent and could potentially introduce conflicts with code trying to use them.) --- DOCS/interface-changes.rst | 1 + DOCS/man/options.rst | 3 +-- etc/builtin.conf | 1 - libmpv/client.h | 2 ++ 4 files changed, 4 insertions(+), 3 deletions(-) diff --git a/DOCS/interface-changes.rst b/DOCS/interface-changes.rst index c252a57f82..7960ea95ec 100644 --- a/DOCS/interface-changes.rst +++ b/DOCS/interface-changes.rst @@ -24,6 +24,7 @@ Interface changes --ad-spdif-dtshd, --softvol options - fix --external-files: strictly never select any tracks from them, unless explicitly selected (this may or may not be expected) + - --ytdl is now always enabled, even for libmpv --- mpv 0.28.0 --- - rename --hwdec=mediacodec option to mediacodec-copy, to reflect conventions followed by other hardware video decoding APIs diff --git a/DOCS/man/options.rst b/DOCS/man/options.rst index b6813494a6..2f7baf92ff 100644 --- a/DOCS/man/options.rst +++ b/DOCS/man/options.rst @@ -547,8 +547,7 @@ Program Behavior Enable the youtube-dl hook-script. It will look at the input URL, and will play the video located on the website. This works with many streaming sites, not just the one that the script is named after. This requires a recent - version of youtube-dl to be installed on the system. (Enabled by default, - except when the client API / libmpv is used.) + version of youtube-dl to be installed on the system. (Enabled by default.) If the script can't do anything with an URL, it will do nothing. diff --git a/etc/builtin.conf b/etc/builtin.conf index 8e954b90d2..0f53b3974c 100644 --- a/etc/builtin.conf +++ b/etc/builtin.conf @@ -17,7 +17,6 @@ idle=yes terminal=no input-terminal=no osc=no -ytdl=no input-default-bindings=no input-vo-keyboard=no # OSX/Cocoa global input hooks diff --git a/libmpv/client.h b/libmpv/client.h index 91a8e81cbb..41bf4e0c5c 100644 --- a/libmpv/client.h +++ b/libmpv/client.h @@ -134,6 +134,8 @@ extern "C" { * - The FPU precision must be set at least to double precision. * - On Windows, mpv will call timeBeginPeriod(1). * - On memory exhaustion, mpv will kill the process. + * - In certain cases, mpv may start sub processes (such as with the ytdl + * wrapper script). * * Encoding of filenames * --------------------- -- cgit v1.2.3