FFmpeg recently got a hardware accelerated decoder for FFv1.
The decoder has been tested on all major vendors and operating systems.
Intel support is currently disabled as all of their drivers have issues
with buffer device addresses.
Since its a software-defined implementation, internal issues can be fixed
and the overall implementation optimized further.
With that, I think it should be safe to enable it by default.
Terminal multiplexers like (screen, tmux, ...) do not support the kitty
image protocol (as of yet), to go around this DCS escape sequences are
used (`\ePtmux;...\e\` for tmux, `\eP...\e\` for screen). This option
allows passing thorugh the kitty image escape sequences.
`\033\\` suffixes from `KITTY_ESC_IMG_SHM` and `KITTY_ESC_DELETE_ALL`
have been removed. This makes it easier to wrap the escape sequences in
a DCS control sequence since there will be no `\033` in them to escape
(as multiplexers require escaping the escapes within the DCS data
string). `DCS_GUARD_WRITE` and `DCS_GUARD_APPEND` macros have been added
to wrap escape sequences in DCS control sequence based on the
availability of the `priv->dcs_prefix` property.
The messages referred to "no" prefixes like --no-audio not working with
the client API. The language was removed in
b1ee92ad4a.
Remove the messages which are bogus and incorrect now.
It can be too easy to change the video position without a single way to
undo the change. Also, this is mostly useful for images. Binding can be
brought back in a better way with an image profile or another method
that is more resistant to accidental clicks.
This reverts commit e98d3b62ec.
Currently --osd-font is the default for select, and a monospace font is
the default for free-form text mode. We can also default to the
proportional --osd-font for mp.input.get clients that don't specify
completions and thus don't need alignment, which is most clients.
In builtin scripts, this is the case for filtering stats key bindings.
It was suggested by CogentRedTester in
https://github.com/mpv-player/mpv/pull/10282#issuecomment-1858727729 and
https://github.com/mpv-player/mpv/pull/10282#issuecomment-1858809580 and
by avih that making running commands an mp.input client is a better
architecture.
A practical advantage is that completions are calculated in a different
thread, which prevents hanging when completing slow/network filesystems.
script-binding console/enable becomes script-binding commands/open,
though the console one is kept as an alias. I took the opportunity to
rename this because open makes more sense for a graphical modal, and it
is the word used in mp.input and user-data.
script-message-to console type becomes script-message-to commands type,
though the console one is kept as an alias. It is also changed to
automatically close on submit without having to append '; keypress ESC'
as you don't need to keep the console open after running prefilled
commands.
Also convert to double quotes like other scripts and rename some
inconsistent functions.
Let the complete callback return the character to append to the selected
completion.
I didn't want to document this because it's specifically meant for
properties and unlikely to be needed by other scripts, but silently
interpreting the 3rd return value can screw you over if you do something
like
return candidates, code:find('[%w_]*$')
I was doing this in my lua-repl script, and find() returns the end
position as the 2rd argument, this becomes the 3rd return value and gets
appended to completions. So you have to do
return candidates, code:find('[%w_]*$'), nil
Needed to split running commands out of console.lua.
This is useful to run mpv from URL handler. Can be used to start mpv
from you web browser or anything that would trigger url handler for
given protocol. Only safe protocols are allowed.
Current solutions to run mpv in such context are to spawn IPC proxy and
run mpv when requested, but this is in most cases not necessary.
Currently the protocol is added in mpv.desktop. Windows related
registration will follow in future changes.
The documentation does not mention that using add/cycle to change
the property is subject to --chapter-seek-threshold option,
and the fact that a chapter number of -1 indicates a playback
position before the start of the first chapter.
With input.select this allows building nested submenus without the
flicker of console quickly closing and reopening, and also doing
multiple selections, to e.g. cycle through different values of a
property, or increase a property multiple times.
With input.get this is used to change the default behavior to closing by
default on submit. It was argued by avih that this is more useful, and
indeed Github code search shows that everybody is calling
input.terminate() unconditionally on submit, so the impact of the change
should be low, and restoring the old behavior is as easy as passing
keep_open = true, which is just ignored in older mpv versions.
fzy returns which characters matched the search for every item, so use
this to highlight them.
This defaults to a light blue color that is readable with both black and
white (selected) backgrounds.
The returned positions are just bytes, so we can't put ASS tags or
escape sequences around each byte because that would break displaying
multibyte UTF-8 characters. Only put them around sequences of matched
positions, and only when the sequences start and end at actual character
positions.
--prefetch-playlist improves performance by starting to read the next
file in the last second or playback or while viewing an image. This is
obviously noticeable with playlists of direct media URLs, but can also
make a difference on local slow hardware, mainly large (in bytes) images
on HDDs. You can easily see the difference with 10+ MB images.
Since e7a253614c and 24db17d10f fixed niche issues, and it's known not
to cause other issues by users using since 2017 who haven't reported
issues, enable it by default to improve performance.
The only flaw is that it doesn't support ytdl-hook URLs, so in Youtube
playlist, it does a web request with ffmpeg that is doomed to fail since
the last second of playback, though this doesn't cause practical
disadvantages.
There is no known issue with --prefetch-playlist and file-local-options.
It works just fine with them, and people have been using it since 2017
and haven't reported related issues. So ease the warnings to not scare
users away from using a useful option.
Also when --prefetch-playlist was implemented it also prefetched the
stream cache until 559a400ac3 removed it - see #6753. So if such issues
ever existed, they were fixed by not making it prefill the stream cache.
Now it doesn't do much, it only opens a connection to the next file, and
the cache of the next video starts empty.
An alternative is to bind to right click only for images, but since we
will likely bind right click to the context menu once it works on
platforms other than Windows, bind to ctrl+left click to not have to
change it later.
This ensures a clear separation between public and private headers. It
also makes it clear in Meson and prevents the accidental use of private
headers.
This reverts part of PR #15899 (commit dd6e3a0ece).
"Why is this even useful?": It's very useful for multi-disc playlists. Compare:
`mpv bd:///DISC{1..4}`
`mpv -\{ bd:// --bluray-device=DISC1 -\} -\{ bd:// --bluray-device=DISC2 -\} -\{ bd:// --bluray-device=DISC3 -\} -\{ bd:// --bluray-device=DISC4 -\}`
Need to shuffle some stuff around but it's pretty simple. Mute the
audio stream before the frame step and then unmute it when we're done.
It's exactly the same as the default play mode otherwise.
This is allowed but it's pretty weird. You'd end up typing something
like dvd:////dev/sr0 or cdda:///dev/sr0 (notice the differing amount of
/). Why is this even useful? Just use the matching --cdda-device option.
There's no need to have two ways to do the same thing here.
This adds --video-aspect-method=ignore to replace --video-aspect-override=0.
--video-aspect-override=0 and --video-aspect-override=-1 will no longer be
handled specially. For compatibility, 0 is mapped to always use ignore
and -1 is always mapped to always use container.
"no" is now the replacement for --video-aspect-override=-1, which is
internally remapped to -2 to avoid using a deprecated value.