1
0
mirror of https://github.com/mpv-player/mpv synced 2025-02-19 22:36:55 +00:00
mpv/player
wm4 76276c9210 video: rewrite filtering glue code
Get rid of the old vf.c code. Replace it with a generic filtering
framework, which can potentially handle more than just --vf. At least
reimplementing --af with this code is planned.

This changes some --vf semantics (including runtime behavior and the
"vf" command). The most important ones are listed in interface-changes.

vf_convert.c is renamed to f_swscale.c. It is now an internal filter
that can not be inserted by the user manually.

f_lavfi.c is a refactor of player/lavfi.c. The latter will be removed
once --lavfi-complex is reimplemented on top of f_lavfi.c. (which is
conceptually easy, but a big mess due to the data flow changes).

The existing filters are all changed heavily. The data flow of the new
filter framework is different. Especially EOF handling changes - EOF is
now a "frame" rather than a state, and must be passed through exactly
once.

Another major thing is that all filters must support dynamic format
changes. The filter reconfig() function goes away. (This sounds complex,
but since all filters need to handle EOF draining anyway, they can use
the same code, and it removes the mess with reconfig() having to predict
the output format, which completely breaks with libavfilter anyway.)

In addition, there is no automatic format negotiation or conversion.
libavfilter's primitive and insufficient API simply doesn't allow us to
do this in a reasonable way. Instead, filters can use f_autoconvert as
sub-filter, and tell it which formats they support. This filter will in
turn add actual conversion filters, such as f_swscale, to perform
necessary format changes.

vf_vapoursynth.c uses the same basic principle of operation as before,
but with worryingly different details in data flow. Still appears to
work.

The hardware deint filters (vf_vavpp.c, vf_d3d11vpp.c, vf_vdpaupp.c) are
heavily changed. Fortunately, they all used refqueue.c, which is for
sharing the data flow logic (especially for managing future/past
surfaces and such). It turns out it can be used to factor out most of
the data flow. Some of these filters accepted software input. Instead of
having ad-hoc upload code in each filter, surface upload is now
delegated to f_autoconvert, which can use f_hwupload to perform this.

Exporting VO capabilities is still a big mess (mp_stream_info stuff).

The D3D11 code drops the redundant image formats, and all code uses the
hw_subfmt (sw_format in FFmpeg) instead. Although that too seems to be a
big mess for now.

f_async_queue is unused.
2018-01-30 03:10:27 -08:00
..
javascript js: implement mp.msg.trace() 2017-12-16 02:25:24 -08:00
lua ytdl_hook: pre-append id-only playlist items with shortened youtube URL 2018-01-29 21:39:12 +00:00
audio.c player: redo hack for video keyframe seeks with external audio 2018-01-18 01:25:53 -08:00
client.c client: Allow "C.UTF-8" as LC_NUMERIC locale 2017-11-30 21:06:37 +02:00
client.h client API: turn mpv_suspend() and mpv_resume() into stubs 2016-11-22 15:54:44 +01:00
command.c video: rewrite filtering glue code 2018-01-30 03:10:27 -08:00
command.h player: update duration based on highest timestamp demuxed 2017-12-24 21:49:12 +01:00
configfiles.c player: silence config file loading message on resuming 2018-01-13 03:26:45 -08:00
core.h video: rewrite filtering glue code 2018-01-30 03:10:27 -08:00
external_files.c player: make track language matching case insensitive 2017-12-23 15:14:13 -07:00
external_files.h external_files: change license to LGPL 2017-06-20 14:22:10 +02:00
javascript.c lua+js: implement utils.file_info() 2017-12-13 21:55:28 +02:00
lavfi.c lavfi: fix warnings with newer libavfilter versions 2017-10-27 18:09:08 +02:00
lavfi.h audio: introduce a new type to hold audio frames 2017-08-16 21:10:54 +02:00
loadfile.c video: rewrite filtering glue code 2018-01-30 03:10:27 -08:00
lua.c msg: reinterpret a bunch of message levels 2017-12-15 22:28:47 -08:00
main.c build: move copyright statement to a shared location 2018-01-01 21:05:09 +00:00
misc.c options: move most subtitle and OSD rendering options to sub structs 2018-01-02 14:27:37 -08:00
osd.c osd: treat user provided term-status-msg the same as the default 2018-01-14 00:31:47 -08:00
playloop.c video: rewrite filtering glue code 2018-01-30 03:10:27 -08:00
screenshot.c screenshot: create directories from template 2017-11-02 17:07:35 +01:00
screenshot.h player: make screenshot commands honor the async flag 2017-04-01 20:47:23 +02:00
scripting.c msg: reinterpret a bunch of message levels 2017-12-15 22:28:47 -08:00
sub.c video: rewrite filtering glue code 2018-01-30 03:10:27 -08:00
video.c video: rewrite filtering glue code 2018-01-30 03:10:27 -08:00