command: allow setting per-file options at runtime

The intended use-case is for doing this at load time, after the load
command was issued. (See following commit.)
command: add a mechanism to allow scripts to intercept file loads

A vague idea to get something similar what libquvi did.

Undocumented because it might change a lot, or even be removed. To give
an idea what it does, a Lua script could do the following:

--                      type       ID priority
mp.commandv("hook_add", "on_load", 0, 0)
mp.register_script_message("hook_run", function(param, param2)
    -- param is "0", the user-chosen ID from the hook_add command
    -- param2 is the magic value that has to be passed to finish
    -- the hook
    mp.resume_all()
    -- do something, maybe set options that are reset on end:
    mp.set_property("file-local-options/name", "value")
    -- or change the URL that's being opened:
    local url = mp.get_property("stream-open-filename")
    mp.set_property("stream-open-filename", url .. ".png")
    -- let the player (or the next script) continue
    mp.commandv("hook_ack", param2)
end)
player: free subtitle renderer on exit

This was probably commented as an oversight. Since the subtitle renderer
was uninitialized on reinitialization anyway, this had no negative
consequences, except a memory on exit.
player: fix crash on early audio uninit

Could crash when exiting playback in very early stages of
initialization.

CC: @mpv-player/stable
manpage: fix reference to a defunct option

The change was made with faad40aad92d51290ef2fc4d94277eca89863873.
TOOLS/vf_dlopen/ildetect.sh: remove duplicated assigment
common: fix \x-style escaping

This was rejecting correct escapes and accepting incorrect ones.
player: quote %-starting strings

Leading percent sign is a quote indicator so it needs to be quoted
itself.
DOCS/client_api_examples: qtexample: embedding works on Cocoa
DOCS/client_api_examples: qtexample: set a magic Qt flag

Otherwise, other magic Qt stuff can be magically broken.

(No, I don't know the real reasons for this.)
cocoa: perform init and uninit synchronously

This is slightly safer and without the resize redraw, should not cause any
deadlock.
vo_opengl: fix theoretical format mismatch issue

This would have been wrong for hw decoders which pass us NV12 or NV21.
The format the GL shader filter chain gets is stored in p->image_desc,
while p->image_format still contains the "real" input format (which in
case of hw decoding is an opsque hw accel format). Since no hw decoder
did this, this is really just a theoretical fix and doesn't fix any
actual bugs.
vo_opengl: fix wrong comments

The previous commit was actually incorrect, and the change had
absolutely no effect. The two formats are (fortunately) the same. I'm
probably too tired.
stream: better error message for unmatched protocol

See #1187.
terminal: recognize ^h

Fixes #1185.

CC: @mpv-player/stable
input: don't add weird padding when formatting keycode

No idea what this was for. It has no purpose and looks weird.
audio: don't go to sleep after audio reinit

It possibly goes to sleep without actually starting to decode audio.
Possibly fixes a problem with --no-osc --no-video reported on IRC.

CC: @mpv-player/stable
sub: adjustments to --ass-style-override option

Now requires newest libass git. Since this feature wasn't part of a
libass release yet, I'm not bothering making the mpv code compatible
with as how it was previously implemented (it will just be disabled
with any older libass).

CC: @mpv-player/stable (because mpv-build uses libass git, and this
                        breaks the feature)
options: don't load per-file config files by default

Generally useless feature, and might be slightly dangerous if paths
can "escape" from the profile dir. (Normally this shouldn't be
possible, though.)
demux: print a warning if stream is not seekable