summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--DOCS/man/en/ao.rst2
-rw-r--r--DOCS/man/en/changes.rst23
-rw-r--r--DOCS/man/en/input.rst63
-rw-r--r--DOCS/man/en/mpv.rst91
-rw-r--r--DOCS/man/en/options.rst236
-rw-r--r--DOCS/man/en/vf.rst10
-rw-r--r--DOCS/man/en/vo.rst11
-rw-r--r--DOCS/tech-overview.txt3
-rw-r--r--Makefile12
-rw-r--r--cfg-mplayer.h14
-rw-r--r--command.c3
-rw-r--r--etc/input.conf7
-rw-r--r--image_writer.c47
-rw-r--r--image_writer.h7
-rw-r--r--input/input.c9
-rw-r--r--libmpcodecs/mp_image.c63
-rw-r--r--libmpcodecs/mp_image.h26
-rw-r--r--libmpcodecs/sws_utils.c199
-rw-r--r--libmpcodecs/sws_utils.h33
-rw-r--r--libmpcodecs/vd_ffmpeg.c2
-rw-r--r--libmpcodecs/vf.c12
-rw-r--r--libmpcodecs/vf.h6
-rw-r--r--libmpcodecs/vf_scale.c83
-rw-r--r--libmpcodecs/vf_scale.h28
-rw-r--r--libmpcodecs/vf_screenshot.c3
-rw-r--r--libmpcodecs/vf_sub.c (renamed from libmpcodecs/vf_ass.c)221
-rw-r--r--libmpcodecs/vf_vo.c29
-rw-r--r--libmpcodecs/vfcap.h7
-rw-r--r--libmpdemux/demuxer.h2
-rw-r--r--libvo/aspect.c31
-rw-r--r--libvo/aspect.h5
-rw-r--r--libvo/bitmap_packer.c73
-rw-r--r--libvo/bitmap_packer.h19
-rw-r--r--libvo/csputils.c74
-rw-r--r--libvo/csputils.h15
-rw-r--r--libvo/eosd_packer.c255
-rw-r--r--libvo/eosd_packer.h74
-rw-r--r--libvo/fastmemcpy.h13
-rw-r--r--libvo/gl_common.c47
-rw-r--r--libvo/gl_common.h6
-rw-r--r--libvo/gl_osd.c324
-rw-r--r--libvo/gl_osd.h43
-rw-r--r--libvo/osd.c224
-rw-r--r--libvo/osd.h34
-rw-r--r--libvo/osd_template.c383
-rw-r--r--libvo/video_out.c162
-rw-r--r--libvo/video_out.h22
-rw-r--r--libvo/vo_caca.c6
-rw-r--r--libvo/vo_corevideo.m203
-rw-r--r--libvo/vo_direct3d.c520
-rw-r--r--libvo/vo_image.c3
-rw-r--r--libvo/vo_lavc.c135
-rw-r--r--libvo/vo_opengl.c412
-rw-r--r--libvo/vo_opengl_old.c411
-rw-r--r--libvo/vo_opengl_shaders.glsl7
-rw-r--r--libvo/vo_vdpau.c417
-rw-r--r--libvo/vo_x11.c86
-rw-r--r--libvo/vo_xv.c218
-rw-r--r--mpcommon.h5
-rw-r--r--mplayer.c134
-rw-r--r--screenshot.c71
-rw-r--r--screenshot.h10
-rw-r--r--sub/ass_mp.c53
-rw-r--r--sub/ass_mp.h11
-rw-r--r--sub/dec_sub.c26
-rw-r--r--sub/dec_sub.h39
-rw-r--r--sub/draw_bmp.c530
-rw-r--r--sub/draw_bmp.h17
-rw-r--r--sub/find_subfiles.c1
-rw-r--r--sub/img_convert.c89
-rw-r--r--sub/img_convert.h15
-rw-r--r--sub/osd_dummy.c22
-rw-r--r--sub/osd_libass.c234
-rw-r--r--sub/sd.h5
-rw-r--r--sub/sd_ass.c22
-rw-r--r--sub/sd_lavc.c133
-rw-r--r--sub/spudec.c823
-rw-r--r--sub/spudec.h21
-rw-r--r--sub/sub.c426
-rw-r--r--sub/sub.h262
80 files changed, 3339 insertions, 5084 deletions
diff --git a/DOCS/man/en/ao.rst b/DOCS/man/en/ao.rst
index 412d9ac939..ae0432784f 100644
--- a/DOCS/man/en/ao.rst
+++ b/DOCS/man/en/ao.rst
@@ -94,7 +94,7 @@ dsound (Windows only)
null
Produces no audio output but maintains video playback speed. Use
- ``--nosound`` for benchmarking.
+ ``--no-audio`` for benchmarking.
pcm
raw PCM/wave file writer audio output
diff --git a/DOCS/man/en/changes.rst b/DOCS/man/en/changes.rst
index 6e96cde115..5febb3afd2 100644
--- a/DOCS/man/en/changes.rst
+++ b/DOCS/man/en/changes.rst
@@ -43,24 +43,27 @@ General changes for mplayer2 to mpv
decades old hardware
* Removal of support for dead platforms
* Generally improved MS Windows support (dealing with unicode filenames,
- improved ``vo_direct3d``, improve window handling)
+ improved ``--vo=direct3d``, improved window handling)
* Better OSD rendering (using libass). This has full unicode support, and
languages like Arabic should be better supported.
* Cleaned up terminal output (nicer status line, less useless noise)
* Support for playing URLs of popular streaming sites directly
(e.g. ``mpv https://www.youtube.com/watch?v=...``)
-* Improved OpenGL output (``vo_opengl``)
+* Improved OpenGL output (``--vo=opengl-hq``)
* Make ``--softvol`` default (**mpv** is not a mixer control panel)
* Improved support for .cue files
-* Screenshot improvements (can save screenshots as JPG, configurable filenames)
+* Screenshot improvements (can save screenshots as JPG or PNG, configurable
+ filenames, support for taking screenshots with or without subtitles)
* Removal of teletext support
-* Replace image VOs (``vo_jpeg`` etc.) with ``vo_image``
-* Remove ``vo_gif89a``, ``vo_md5sum``, ``vo_yuv4mpeg`` (the plan is to merge
- divverent's encoding branch, which provides support for all of these)
+* Replace image VOs (``--vo=jpeg`` etc.) with ``--vo=image``
* Do not lose settings when playing a new file in the same player instance
* New location for config files, new name for the binary. (Planned change.)
* Slave mode compatibility broken (see below)
* Encoding functionality (replacement for mencoder)
+ (Remove ``--vo=gif89a``, ``--vo=md5sum``, ``--vo=yuv4mpeg``, as encoding can
+ handle these use cases.)
+* Image subtitles (DVDs etc.) are rendered in color and use more correct
+ positioning
* General code cleanups
* Many more changes
@@ -80,7 +83,7 @@ Command line switches
know about this change.
(The new syntax was introduced in mplayer2.)
-* In general, negating a switch like ``-noopt`` now has to be written as
+* In general, negating switches like ``-noopt`` now have to be written as
``-no-opt``, or better ``--no-opt``.
* Per-file options are not the default anymore. You can explicitly specify
file local options. See ``Usage`` section.
@@ -151,8 +154,8 @@ Other
mplayer. A proper slave mode application needed tons of code and hacks to get
it right. The main problem is that slave mode is a bad and incomplete
interface, and to get around that, applications parsed output messages
- intended for users. It's hard to know just which messages are parsed by some
- slave mode application, and as such it's virtually impossible to improve
+ intended for users. It's hard to know which messages exactly are parsed by
+ slave mode applications. This makes it virtually impossible to improve
terminal output intended for users without possibly breaking something.
This is absolutely insane, and **mpv** will not try to keep slave mode
@@ -164,7 +167,7 @@ Policy for removed features
Features are a good thing, because they make users happy. As such, it is
attempted to preserve useful features as far as possible. But if a feature is
-likely to be not used by many, and causes otherwise problems, it will be
+likely to be not used by many, and causes problems otherwise, it will be
removed. Developers should not be burdened with fixing or cleaning up code that
has no actual use.
diff --git a/DOCS/man/en/input.rst b/DOCS/man/en/input.rst
index 74c4929684..2f6e0b1e09 100644
--- a/DOCS/man/en/input.rst
+++ b/DOCS/man/en/input.rst
@@ -14,16 +14,24 @@ with shift.
A list of special keys can be obtained with
-| **mplayer** --input=keylist
+| **mpv** --input=keylist
In general, keys can be combined with ``Shift``, ``Ctrl`` and ``Alt``:
| ctrl+q quit
+**mpv** can be started in input test mode, which displays key bindings and the
+commands they're bound to on the OSD, instead of running the commands:
+
+| **mpv** --input=test --demuxer=rawvideo --rawvideo=w=1280:h=720 /dev/zero
+
+(Commands which normally close the player will not work in this mode, and you
+must kill **mpv** externally to make it exit.)
+
General input command syntax
----------------------------
-`[Shift+][Ctrl+][Alt+][Meta+]<key> [<prefix>] <command> (<argument>)*`
+`[Shift+][Ctrl+][Alt+][Meta+]<key> [<prefixes>] <command> (<argument>)*`
Newlines always start a new binding. ``#`` starts a comment (outside of quoted
string arguments). To bind commands to the ``#`` key, ``SHARP`` can be used.
@@ -45,7 +53,7 @@ ignore
disabling default bindings, without disabling all bindings with
``--input=default-bindings=no``.
-seek <seconds> [relative|absolute|absolute-percent] [default-precise|exact|keyframes]
+seek <seconds> [relative|absolute|absolute-percent|- [default-precise|exact|keyframes]]
Change the playback position. By default, seeks by a relative amount of
seconds.
@@ -56,7 +64,7 @@ seek <seconds> [relative|absolute|absolute-percent] [default-precise|exact|keyfr
absolute
Seek to a given time.
absolute-percent
- Seek to agiven percent position.
+ Seek to a given percent position.
The third argument defines how exact the seek is:
@@ -87,28 +95,31 @@ cycle <property> [up|down]
speed_mult <value>
Multiply the ``speed`` property by the given value.
-screenshot [single|each-frame] [video|window]
+screenshot [subtitles|video|window|- [single|each-frame]]
Take a screenshot.
First argument:
+ <subtitles> (default)
+ Save the video image, in its original resolution, and with subtitles.
+ Some video outputs may still include the OSD in the output under certain
+ circumstances.
+ <video>
+ Like ``subtitles``, but typically without OSD or subtitles. The exact
+ behavior depends on the selected video output.
+ <window>
+ Save the contents of the mpv window. Typically scaled, with OSD and
+ subtitles. The exact behavior depends on the selected video output, and
+ if no support is available, this will act like ``video``.
+
+ Second argument:
+
<single> (default)
Take a single screenshot.
<each-frame>
Take a screenshot each frame. Issue this command again to stop taking
screenshots.
- Second argument:
-
- <video> (default)
- Save the video image, in its original resolution. Typically without
- OSD or subtitles, but the exact behavior depends on the selected video
- output.
- <window>
- Save the contents of the mplayer window. Typically scaled, with OSD and
- subtitles. The exact behavior depends on the selected video output, and
- if not support is available, this will act like ``video``.
-
playlist_next [weak|force]
Go to the next entry on the playlist.
@@ -164,7 +175,7 @@ print_text "<string>"
Print text to stdout. The string can contain properties, which are expanded
like in ``--playing-msg``.
-show_text "<string>" [<duration>] [<level>]
+show_text "<string>" [<duration>|- [<level>]]
Show text on the OSD. The string can contain properties, which are expanded
like in ``--playing-msg``. This can be used to show playback time, filename,
and so on.
@@ -204,9 +215,9 @@ osd-bar
If possible, show a bar with this command. Seek commands will show the
progress bar, property changing commands may show the newly set value.
osd-msg
- If possible, show an OSD message with this command. The seek command shows
- the current playback time (like ``show_progress``), property changing
- commands show the newly set value as text.
+ If possible, show an OSD message with this command. Seek command show
+ the current playback time, property changing commands show the newly set
+ value as text.
osd-msg-bar
Combine osd-bar and osd-msg.
@@ -220,7 +231,7 @@ pausing_keep_force. (Should these be made official?)
Properties
----------
-Properties are used to set mplayer options during runtime, or to query arbitrary
+Properties are used to set mpv options during runtime, or to query arbitrary
information. They can be manipulated with the ``set``/``add``/``cycle``
commands, and retrieved with ``show_text``, or anything else that uses property
expansion. (See ``--playing-msg`` how properties are expanded.)
@@ -253,7 +264,7 @@ edition x current MKV edition number
titles number of DVD titles
chapters number of chapters
editions number of MKV editions
-angle current DVD angle
+angle x current DVD angle
metadata metadata key/value pairs
metadata/<key> value of metedata entry <key>
pause x pause status (bool)
@@ -303,8 +314,8 @@ sub-scale x subtitle font size multiplicator
ass-use-margins x see ``--ass-use-margins``
ass-vsfilter-aspect-compat x see ``--ass-vsfilter-aspect-compat``
ass-style-override x see ``--ass-style-override``
-tv-brightness
-tv-contrast
-tv-saturation
-tv-hue
+tv-brightness x
+tv-contrast x
+tv-saturation x
+tv-hue x
=========================== = ==================================================
diff --git a/DOCS/man/en/mpv.rst b/DOCS/man/en/mpv.rst
index 6de386fdf9..96ccb10691 100644
--- a/DOCS/man/en/mpv.rst
+++ b/DOCS/man/en/mpv.rst
@@ -18,9 +18,6 @@ Synopsis
| **mpv** \mf://[filemask|\@listfile] [-mf options] [options]
| **mpv** [cdda|cddb]://track[-endtrack][:speed][/device] [options]
| **mpv** [file|mms[t]|http|http\_proxy|rt[s]p|ftp|udp|unsv|icyx|noicyx|smb]:// [user:pass\@]URL[:port] [options]
-| **mpv** \sdp://file [options]
-| **mpv** \mpst://host[:port]/URL [options]
-| **mpv** \tivo://host/[list|llist|fsid] [options]
DESCRIPTION
@@ -48,13 +45,11 @@ keyboard control
LEFT and RIGHT
Seek backward/forward 10 seconds. Shift+arrow does a 1 second exact seek
- (see ``--hr-seek``; currently modifier keys like shift only work if used in
- an X output window).
+ (see ``--hr-seek``).
UP and DOWN
Seek forward/backward 1 minute. Shift+arrow does a 5 second exact seek (see
- ``--hr-seek``; currently modifier keys like shift only work if used in an X
- output window).
+ ``--hr-seek``).
PGUP and PGDWN
Seek forward/backward 10 minutes.
@@ -149,20 +144,15 @@ V
Toggle subtitle VSFilter aspect compatibility mode. See
``--ass-vsfilter-aspect-compat`` for more info.
-C (``--capture`` only)
- Start/stop capturing the primary stream.
-
r and t
Move subtitles up/down.
-i (``--edlout`` mode only)
- Set start or end of an EDL skip and write it out to the given file.
-
s
Take a screenshot.
S
- Start/stop taking screenshots.
+ Take a screenshot, without subtitles. (Whether this works depends on VO
+ driver support.)
I
Show filename on the OSD.
@@ -173,7 +163,7 @@ P
! and @
Seek to the beginning of the previous/next chapter.
-D (``--vo=vdpau``, ``--vf=yadif``, ``--vf=kerndeint`` only)
+D (``--vo=vdpau``, ``--vf=yadif`` only)
Activate/deactivate deinterlacer.
A
@@ -183,8 +173,7 @@ c
Change YUV colorspace.
(The following keys are valid only when using a video output that supports the
-corresponding adjustment, the software equalizer (``--vf=eq`` or ``--vf=eq2``)
-or hue filter (``--vf=hue``).)
+corresponding adjustment, or the software equalizer (``--vf=eq2``).)
1 and 2
Adjust contrast.
@@ -304,7 +293,7 @@ affects all files. Example:
| file2.mkv | --a --b --c |
+-----------+-------------------------+
-Also, if any option is changed at runtime (via slave commands), they aren't
+Also, if any option is changed at runtime (via input commands), they aren't
reset when a new file is played.
Sometimes, it's useful to change options per-file. This can be achieved by
@@ -340,9 +329,8 @@ your configuration directory (e.g. ``/etc/mpv`` or
User specific options override system-wide options and options given on the
command line override either. The syntax of the configuration files is
``option=<value>``, everything after a *#* is considered a comment. Options
-that work without values can be enabled by setting them to *yes* or *1* or
-*true* and disabled by setting them to *no* or *0* or *false*. Even suboptions
-can be specified in this way.
+that work without values can be enabled by setting them to *yes* and disabled by
+setting them to *no*. Even suboptions can be specified in this way.
You can also write file-specific configuration files. If you wish to have a
configuration file for a file called 'movie.avi', create a file named
@@ -358,8 +346,8 @@ as the file played and then tries to load any file-specific configuration.
*EXAMPLE MPV CONFIGURATION FILE:*
-| # Use gl3 video output by default.
-| vo=gl3
+| # Use opengl video output by default.
+| vo=opengl
| # I love practicing handstands while watching videos.
| flip=yes
| # Decode multiple files from PNG,
@@ -415,12 +403,13 @@ Taking screenshots
==================
Screenshots of the currently played file can be taken using the 'screenshot'
-slave mode command, which is by default bound to the ``s`` key. Files named
-``shotNNNN.png`` will be saved in the working directory, using the first
+input mode command, which is by default bound to the ``s`` key. Files named
+``shotNNNN.jpg`` will be saved in the working directory, using the first
available number - no files will be overwritten.
A screenshot will usually contain the unscaled video contents at the end of the
-video filter chain. Some video output drivers will include subtitles and OSD in
+video filter chain and subtitles. By default the ``S`` takes screenshots without
+subtitles. Some video output drivers will always include subtitles and OSD in
the video frame as well - this is because of technical restrictions.
The ``screenshot`` video filter is normally not required when using a
@@ -442,10 +431,6 @@ ENVIRONMENT VARIABLES
There are a number of environment variables that can be used to control the
behavior of mpv.
-``MPV_CHARSET`` (see also ``--msgcharset``)
- Convert console messages to the specified charset (default: autodetect). A
- value of "noconv" means no conversion.
-
``MPV_HOME``
Directory where mpv looks for user settings.
@@ -519,29 +504,6 @@ libdvdcss:
``HOME``
FIXME: Document this.
-libao2:
- ``AUDIOSERVER``
- Specifies the Network Audio System server to which the nas audio
- output driver should connect and the transport that should be used. If
- unset DISPLAY is used instead. The transport can be one of tcp and
- unix. Syntax is ``tcp/<somehost>:<someport>``,
- ``<somehost>:<instancenumber>`` or ``[unix]:<instancenumber>``. The
- NAS base port is 8000 and <instancenumber> is added to that.
-
- *EXAMPLES*:
-
- ``AUDIOSERVER=somehost:0``
- Connect to NAS server on somehost using default port and
- transport.
- ``AUDIOSERVER=tcp/somehost:8000``
- Connect to NAS server on somehost listening on TCP port 8000.
- ``AUDIOSERVER=(unix)?:0``
- Connect to NAS server instance 0 on localhost using unix domain
- sockets.
-
- ``DISPLAY``
- FIXME: Document this.
-
osdep:
``TERM``
FIXME: Document this.
@@ -550,9 +512,6 @@ libvo:
``DISPLAY``
FIXME: Document this.
- ``FRAMEBUFFER``
- FIXME: Document this.
-
``HOME``
FIXME: Document this.
@@ -639,7 +598,7 @@ Play DVD video from a directory with VOB files:
``mpv dvd://1 --dvd-device=/path/to/directory/``
Stream from HTTP:
- ``mpv http://mpv.hq/example.avi``
+ ``mpv http://example.com/example.avi``
Stream using RTSP:
``mpv rtsp://server.example.com/streamName``
@@ -647,24 +606,6 @@ Stream using RTSP:
input from standard V4L:
``mpv tv:// --tv=driver=v4l:width=640:height=480:outfmt=i420 --vc=rawi420 --vo=xv``
-Play DTS-CD with passthrough:
- ``mpv --ac=hwdts --rawaudio=format=0x2001 --cdrom-device=/dev/cdrom cdda://``
-
- You can also use ``--afm=hwac3`` instead of ``--ac=hwdts``. Adjust
- ``/dev/cdrom`` to match the CD-ROM device on your system. If your external
- receiver supports decoding raw DTS streams, you can directly play it via
- ``cdda://`` without setting format, hwac3 or hwdts.
-
-Play a 6-channel AAC file with only two speakers:
- ``mpv --rawaudio=format=0xff --demuxer=rawaudio --af=pan=2:.32:.32:.39:.06:.06:.39:.17:-.17:-.17:.17:.33:.33 adts_he-aac160_51.aac``
-
- You might want to play a bit with the pan values (e.g multiply with a
- value) to increase volume or avoid clipping.
-
-checkerboard invert with geq filter:
- ``mpv --vf=geq='128+(p(X\,Y)-128)*(0.5-gt(mod(X/SW\,128)\,64))*(0.5-gt(mod(Y/SH\,128)\,64))*4'``
-
-
AUTHORS
=======
diff --git a/DOCS/man/en/options.rst b/DOCS/man/en/options.rst
index e226cb7cb7..56d8305c95 100644
--- a/DOCS/man/en/options.rst
+++ b/DOCS/man/en/options.rst
@@ -19,16 +19,6 @@
*NOTE*: