summaryrefslogtreecommitdiffstats
path: root/DOCS/man/en/vf.rst
diff options
context:
space:
mode:
Diffstat (limited to 'DOCS/man/en/vf.rst')
-rw-r--r--DOCS/man/en/vf.rst47
1 files changed, 47 insertions, 0 deletions
diff --git a/DOCS/man/en/vf.rst b/DOCS/man/en/vf.rst
index 6f0e48056f..5cd5d205eb 100644
--- a/DOCS/man/en/vf.rst
+++ b/DOCS/man/en/vf.rst
@@ -845,6 +845,53 @@ Available filters are:
``a3=<string>``
Specify the fourth parameter to pass to the library.
+``vapoursynth=file:maxbuffer``
+ Loads a VapourSynth filter script. This is intended for streamed
+ processing: mpv actually provides a source filter, instead of using a
+ native VapourSynth video source. The mpv source will answer frame
+ requests only within a small window of frames (the size of this window
+ is controlled with the ``maxbuffer`` parameter), and requests outside of
+ that will return errors. As such, you can't use the full power of
+ VapourSynth, but you can use certain filters.
+
+ If you just want to play video generated by a VapourSynth (i.e. using
+ a native VapourSynth video source), it's better to use ``vspipe`` and a
+ FIFO to feed the video to mpv. The same applies if the filter script
+ requires random frame access (see ``maxbuffer`` parameter).
+
+ This filter is experimental. If it turns out that it works well and is
+ used, it will be ported to libavfilter. Otherwise, it will be just removed.
+
+ ``file``
+ Filename of the script source. Currently, this is always a python
+ script. The variable ``video_in`` is set to the mpv video source,
+ and it is expected that the script reads video from it. (Otherwise,
+ mpv will decode no video, and the video packet queue will overflow,
+ eventually leading to audio being stopped.) The script is also
+ expected to pass through timestamps using the ``AbsoluteTime`` frame
+ property.
+
+ .. admonition:: Example:
+
+ ::
+
+ import vapoursynth as vs
+ core = vs.get_core()
+ core.std.AddBorders(video_in, 10, 10, 20, 20).set_output()
+
+ ``maxbuffer``
+ Maximum number of decoded video frames that should be buffered before
+ the filter (default: 5). This specifies the maximum number of frames
+ the script can requests backwards. E.g. if ``maxbuffer=5``, and the
+ script just requested frame 15, it can still request frame 10, but
+ frame 9 is not available anymore. If it requests frame 30, mpv will
+ decode 15 more frames, and keep only frames 25-30.
+
+ (Normally, VapourSynth source filters must provide random access, but
+ mpv was made for playback, and does not provide frame-exact random
+ access. The way this video filter works is a compromise to make simple
+ filters work anyway.)
+
``vavpp``
VA-AP-API video post processing. Works with ``--vo=vaapi`` and ``--vo=opengl``
only. Currently deinterlaces. This filter is automatically inserted if