.\" Man page generated from reStructuredText. . . .nr rst2man-indent-level 0 . .de1 rstReportMargin \\$1 \\n[an-margin] level \\n[rst2man-indent-level] level margin: \\n[rst2man-indent\\n[rst2man-indent-level]] - \\n[rst2man-indent0] \\n[rst2man-indent1] \\n[rst2man-indent2] .. .de1 INDENT .\" .rstReportMargin pre: . RS \\$1 . nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin] . nr rst2man-indent-level +1 .\" .rstReportMargin post: .. .de UNINDENT . RE .\" indent \\n[an-margin] .\" old: \\n[rst2man-indent\\n[rst2man-indent-level]] .nr rst2man-indent-level -1 .\" new: \\n[rst2man-indent\\n[rst2man-indent-level]] .in \\n[rst2man-indent\\n[rst2man-indent-level]]u .. .TH "MPV" 1 "" "" "multimedia" .SH NAME mpv \- a media player .SH SYNOPSIS .nf \fBmpv\fP [options] [file|URL|PLAYLIST|\-] \fBmpv\fP [options] files .fi .sp .SH DESCRIPTION .sp \fBmpv\fP is a media player based on MPlayer and mplayer2. It supports a wide variety of video file formats, audio and video codecs, and subtitle types. Special input URL types are available to read input from a variety of sources other than disk files. Depending on platform, a variety of different video and audio output methods are supported. .sp Usage examples to get you started quickly can be found at the end of this man page. .SH INTERACTIVE CONTROL .sp mpv has a fully configurable, command\-driven control layer which allows you to control mpv using keyboard, mouse, or remote control (there is no LIRC support \- configure remotes as input devices instead). .sp See the \fB\-\-input\-\fP options for ways to customize it. .sp The following listings are not necessarily complete. See \fBetc/input.conf\fP in the mpv source files for a list of default bindings. User \fBinput.conf\fP files and Lua scripts can define additional key bindings. .sp See \fI\%COMMAND INTERFACE\fP and \fI\%Key names\fP sections for more details on configuring keybindings. .sp See also \fB\-\-input\-test\fP for interactive binding details by key, and the \fI\%stats\fP built\-in script for key bindings list (including print to terminal). .SS Keyboard Control .INDENT 0.0 .TP .B LEFT and RIGHT Seek backward/forward 5 seconds. Shift+arrow does a 1 second exact seek (see \fB\-\-hr\-seek\fP). .TP .B UP and DOWN Seek forward/backward 1 minute. Shift+arrow does a 5 second exact seek (see \fB\-\-hr\-seek\fP). .TP .B Ctrl+LEFT and Ctrl+RIGHT Seek to the previous/next subtitle. Subject to some restrictions and might not always work; see \fBsub\-seek\fP command. .TP .B Ctrl+Shift+LEFT and Ctrl+Shift+RIGHT Adjust subtitle delay so that the next or previous subtitle is displayed now. This is especially useful to sync subtitles to audio. .TP .B [ and ] Decrease/increase current playback speed by 10%. .TP .B { and } Halve/double current playback speed. .TP .B BACKSPACE Reset playback speed to normal. .TP .B Shift+BACKSPACE Undo the last seek. This works only if the playlist entry was not changed. Hitting it a second time will go back to the original position. See \fBrevert\-seek\fP command for details. .TP .B Shift+Ctrl+BACKSPACE Mark the current position. This will then be used by \fBShift+BACKSPACE\fP as revert position (once you seek back, the marker will be reset). You can use this to seek around in the file and then return to the exact position where you left off. .TP .B < and > Go backward/forward in the playlist. .TP .B ENTER Go forward in the playlist. .TP .B p and SPACE Pause (pressing again unpauses). .TP .B \&. Step forward. Pressing once will pause, every consecutive press will play one frame and then go into pause mode again. .UNINDENT .INDENT 0.0 .TP .B , Step backward. Pressing once will pause, every consecutive press will play one frame in reverse and then go into pause mode again. .TP .B q Stop playing and quit. .TP .B Q Like \fBq\fP, but store the current playback position. Playing the same file later will resume at the old playback position if possible. See \fI\%RESUMING PLAYBACK\fP\&. .TP .B / and * Decrease/increase volume. .TP .B 9 and 0 Decrease/increase volume. .TP .B m Mute sound. .TP .B _ Cycle through the available video tracks. .TP .B # Cycle through the available audio tracks. .TP .B E Cycle through the available Editions. .TP .B f Toggle fullscreen (see also \fB\-\-fs\fP). .TP .B ESC Exit fullscreen mode. .TP .B T Toggle stay\-on\-top (see also \fB\-\-ontop\fP). .TP .B w and W Decrease/increase pan\-and\-scan range. The \fBe\fP key does the same as \fBW\fP currently, but use is discouraged. .TP .B o and P Show progression bar, elapsed time and total duration on the OSD. .TP .B O Toggle OSD states between normal and playback time/duration. .TP .B v Toggle subtitle visibility. .TP .B j and J Cycle through the available subtitles. .TP .B z and Z Adjust subtitle delay by +/\- 0.1 seconds. The \fBx\fP key does the same as \fBZ\fP currently, but use is discouraged. .TP .B l Set/clear A\-B loop points. See \fBab\-loop\fP command for details. .TP .B L Toggle infinite looping. .TP .B Ctrl++ and Ctrl+\- Adjust audio delay (A/V sync) by +/\- 0.1 seconds. .TP .B Shift+g and Shift+f Adjust subtitle font size by +/\- 10%. .TP .B u Switch between applying only \fB\-\-sub\-ass\-*\fP overrides (default) to SSA/ASS subtitles, and overriding them almost completely with the normal subtitle style. See \fB\-\-sub\-ass\-override\fP for more info. .TP .B V Toggle subtitle VSFilter aspect compatibility mode. See \fB\-\-sub\-ass\-vsfilter\-aspect\-compat\fP for more info. .TP .B r and R Move subtitles up/down. The \fBt\fP key does the same as \fBR\fP currently, but use is discouraged. .TP .B s Take a screenshot. .TP .B S Take a screenshot, without subtitles. (Whether this works depends on VO driver support.) .TP .B Ctrl+s Take a screenshot, as the window shows it (with subtitles, OSD, and scaled video). .TP .B PGUP and PGDWN Seek to the beginning of the previous/next chapter. In most cases, \(dqprevious\(dq will actually go to the beginning of the current chapter; see \fB\-\-chapter\-seek\-threshold\fP\&. .TP .B Shift+PGUP and Shift+PGDWN Seek backward or forward by 10 minutes. (This used to be mapped to PGUP/PGDWN without Shift.) .TP .B b Activate/deactivate debanding. .TP .B d Cycle the deinterlacing filter. .TP .B A Cycle aspect ratio override. .TP .B Ctrl+h Toggle hardware video decoding on/off. .TP .B Alt+LEFT, Alt+RIGHT, Alt+UP, Alt+DOWN Move the video rectangle (panning). .TP .B Alt++ and Alt+\- Change video zoom. .TP .B Alt+BACKSPACE Reset the pan/zoom settings. .TP .B F8 Show the playlist and the current position in it. .TP .B F9 Show the list of audio and subtitle streams. .TP .B i and I Show/toggle an overlay displaying statistics about the currently playing file such as codec, framerate, number of dropped frames and so on. See \fI\%STATS\fP for more information. .TP .B DEL Cycle OSC visibility between never / auto (mouse\-move) / always .TP .B \(ga Show the console. (ESC closes it again. See \fI\%CONSOLE\fP\&.) .UNINDENT .sp (The following keys are valid only when using a video output that supports the corresponding adjustment.) .INDENT 0.0 .TP .B 1 and 2 Adjust contrast. .TP .B 3 and 4 Adjust brightness. .TP .B 5 and 6 Adjust gamma. .TP .B 7 and 8 Adjust saturation. .TP .B Alt+0 (and Command+0 on macOS) Resize video window to half its original size. .TP .B Alt+1 (and Command+1 on macOS) Resize video window to its original size. .TP .B Alt+2 (and Command+2 on macOS) Resize video window to double its original size. .TP .B Command + f (macOS only) Toggle fullscreen (see also \fB\-\-fs\fP). .UNINDENT .sp (The following keys are valid if you have a keyboard with multimedia keys.) .INDENT 0.0 .TP .B PAUSE Pause. .TP .B STOP Stop playing and quit. .TP .B PREVIOUS and NEXT Seek backward/forward 1 minute. .TP .B ZOOMIN and ZOOMOUT Change video zoom. .UNINDENT .sp If you miss some older key bindings, look at \fBetc/restore\-old\-bindings.conf\fP in the mpv git repository. .SS Mouse Control .INDENT 0.0 .TP .B Left double click Toggle fullscreen on/off. .TP .B Right click Toggle pause on/off. .TP .B Forward/Back button Skip to next/previous entry in playlist. .TP .B Wheel up/down Decrease/increase volume. .TP .B Wheel left/right Seek forward/backward 10 seconds. .TP .B Ctrl+Wheel up/down Change video zoom. .UNINDENT .SS Context Menu .sp \fBWARNING:\fP .INDENT 0.0 .INDENT 3.5 This feature is experimental. It may not work with all VOs. A libass based fallback may be implemented in the future. .UNINDENT .UNINDENT .sp Context Menu is a menu that pops up on the video window on user interaction (mouse right click, etc.). .sp To use this feature, you need to fill the \fBmenu\-data\fP property with menu definition data, and add a keybinding to run the \fBcontext\-menu\fP command, which can be done with a user script. .SH USAGE .sp Command line arguments starting with \fB\-\fP are interpreted as options, everything else as filenames or URLs. All options except \fIflag\fP options (or choice options which include \fByes\fP) require a parameter in the form \fB\-\-option=value\fP\&. .sp One exception is the lone \fB\-\fP (without anything else), which means media data will be read from stdin. Also, \fB\-\-\fP (without anything else) will make the player interpret all following arguments as filenames, even if they start with \fB\-\fP\&. (To play a file named \fB\-\fP, you need to use \fB\&./\-\fP\&.) .sp Every \fIflag\fP option has a \fIno\-flag\fP counterpart, e.g. the opposite of the \fB\-\-fs\fP option is \fB\-\-no\-fs\fP\&. \fB\-\-fs=yes\fP is same as \fB\-\-fs\fP, \fB\-\-fs=no\fP is the same as \fB\-\-no\-fs\fP\&. .sp If an option is marked as \fI(XXX only)\fP, it will only work in combination with the \fIXXX\fP option or if \fIXXX\fP is compiled in. .SS Legacy option syntax .sp The \fB\-\-option=value\fP syntax is not strictly enforced, and the alternative legacy syntax \fB\-option value\fP and \fB\-option=value\fP will also work. This is mostly for compatibility with MPlayer. Using these should be avoided. Their semantics can change any time in the future. .sp For example, the alternative syntax will consider an argument following the option a filename. \fBmpv \-fs no\fP will attempt to play a file named \fBno\fP, because \fB\-\-fs\fP is a flag option that requires no parameter. If an option changes and its parameter becomes optional, then a command line using the alternative syntax will break. .sp Until mpv 0.31.0, there was no difference whether an option started with \fB\-\-\fP or a single \fB\-\fP\&. Newer mpv releases strictly expect that you pass the option value after a \fB=\fP\&. For example, before \fBmpv \-\-log\-file f.txt\fP would write a log to \fBf.txt\fP, but now this command line fails, as \fB\-\-log\-file\fP expects an option value, and \fBf.txt\fP is simply considered a normal file to be played (as in \fBmpv f.txt\fP). .sp The future plan is that \fB\-option value\fP will not work anymore, and options with a single \fB\-\fP behave the same as \fB\-\-\fP options. .SS Escaping spaces and other special characters .sp Keep in mind that the shell will partially parse and mangle the arguments you pass to mpv. For example, you might need to quote or escape options and filenames: .INDENT 0.0 .INDENT 3.5 \fBmpv \(dqfilename with spaces.mkv\(dq \-\-title=\(dqwindow title\(dq\fP .UNINDENT .UNINDENT .sp It gets more complicated if the suboption parser is involved. The suboption parser puts several options into a single string, and passes them to a component at once, instead of using multiple options on the level of the command line. .sp The suboption parser can quote strings with \fB\(dq\fP and \fB[...]\fP\&. Additionally, there is a special form of quoting with \fB%n%\fP described below. .sp For example, assume the hypothetical \fBfoo\fP filter can take multiple options: .INDENT 0.0 .INDENT 3.5 \fBmpv test.mkv \-\-vf=foo:option1=value1:option2:option3=value3,bar\fP .UNINDENT .UNINDENT .sp This passes \fBoption1\fP and \fBoption3\fP to the \fBfoo\fP filter, with \fBoption2\fP as flag (implicitly \fBoption2=yes\fP), and adds a \fBbar\fP filter after that. If an option contains spaces or characters like \fB,\fP or \fB:\fP, you need to quote them: .INDENT 0.0 .INDENT 3.5 \fBmpv \(aq\-\-vf=foo:option1=\(dqoption value with spaces\(dq,bar\(aq\fP .UNINDENT .UNINDENT .sp Shells may actually strip some quotes from the string passed to the commandline, so the example quotes the string twice, ensuring that mpv receives the \fB\(dq\fP quotes. .sp The \fB[...]\fP form of quotes wraps everything between \fB[\fP and \fB]\fP\&. It\(aqs useful with shells that don\(aqt interpret these characters in the middle of an argument (like bash). These quotes are balanced (since mpv 0.9.0): the \fB[\fP and \fB]\fP nest, and the quote terminates on the last \fB]\fP that has no matching \fB[\fP within the string. (For example, \fB[a[b]c]\fP results in \fBa[b]c\fP\&.) .sp The fixed\-length quoting syntax is intended for use with external scripts and programs. .sp It is started with \fB%\fP and has the following format: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C %n%string_of_length_n .ft P .fi .UNINDENT .UNINDENT .INDENT 0.0 .INDENT 3.5 .IP "Examples" .sp \fBmpv \(aq\-\-vf=foo:option1=%11%quoted text\(aq test.avi\fP .sp Or in a script: .sp \fBmpv \-\-vf=foo:option1=%\(gaexpr length \(dq$NAME\(dq\(ga%\(dq$NAME\(dq test.avi\fP .UNINDENT .UNINDENT .sp Note: where applicable with JSON\-IPC, \fB%n%\fP is the length in UTF\-8 bytes, after decoding the JSON data. .sp Suboptions passed to the client API are also subject to escaping. Using \fBmpv_set_option_string()\fP is exactly like passing \fB\-\-name=data\fP to the command line (but without shell processing of the string). Some options support passing values in a more structured way instead of flat strings, and can avoid the suboption parsing mess. For example, \fB\-\-vf\fP supports \fBMPV_FORMAT_NODE\fP, which lets you pass suboptions as a nested data structure of maps and arrays. .SS Paths .sp Some care must be taken when passing arbitrary paths and filenames to mpv. For example, paths starting with \fB\-\fP will be interpreted as options. Likewise, if a path contains the sequence \fB://\fP, the string before that might be interpreted as protocol prefix, even though \fB://\fP can be part of a legal UNIX path. To avoid problems with arbitrary paths, you should be sure that absolute paths passed to mpv start with \fB/\fP, and prefix relative paths with \fB\&./\fP\&. .sp Using the \fBfile://\fP pseudo\-protocol is discouraged, because it involves strange URL unescaping rules. .sp The name \fB\-\fP itself is interpreted as stdin, and will cause mpv to disable console controls. (Which makes it suitable for playing data piped to stdin.) .sp The special argument \fB\-\-\fP can be used to stop mpv from interpreting the following arguments as options. .sp When using the client API, you should strictly avoid using \fBmpv_command_string\fP for invoking the \fBloadfile\fP command, and instead prefer e.g. \fBmpv_command\fP to avoid the need for filename escaping. .sp For paths passed to suboptions, the situation is further complicated by the need to escape special characters. To work this around, the path can be additionally wrapped in the fixed\-length syntax, e.g. \fB%n%string_of_length_n\fP (see above). .sp Some mpv options interpret paths starting with \fB~\fP\&. Currently, the prefix \fB~~home/\fP expands to the mpv configuration directory (usually \fB~/.config/mpv/\fP). \fB~/\fP expands to the user\(aqs home directory. (The trailing \fB/\fP is always required.) The following paths are currently recognized: .TS center; |l|l|. _ T{ Name T} T{ Meaning T} _ T{ \fB~~/\fP T} T{ If the subpath exists in any of the mpv\(aqs config directories the path of the existing file/dir is returned. Otherwise this is equivalent to \fB~~home/\fP\&. Note that if \-\-no\-config is used \fB~~/foobar\fP will resolve to \fBfoobar\fP which can be unexpected. T} _ T{ \fB~/\fP T} T{ user home directory root (similar to shell, \fB$HOME\fP) T} _ T{ \fB~~home/\fP T} T{ mpv config dir (for example \fB~/.config/mpv/\fP) T} _ T{ \fB~~global/\fP T} T{ the global config path, if available (not on win32) T} _ T{ \fB~~osxbundle/\fP T} T{ the macOS bundle resource path (macOS only) T} _ T{ \fB~~desktop/\fP T} T{ the path to the desktop (win32, macOS) T} _ T{ \fB~~exe_dir/\fP T} T{ win32 only: the path to the directory containing the exe (for config file purposes; \fB$MPV_HOME\fP overrides it) T} _ T{ \fB~~cache/\fP T} T{ the path to application cache data (\fB~/.cache/mpv/\fP) On some platforms, this will be the same as \fB~~home/\fP\&. T} _ T{ \fB~~state/\fP T} T{ the path to application state data (\fB~/.local/state/mpv/\fP) On some platforms, this will be the same as \fB~~home/\fP\&. T} _ T{ \fB~~old_home/\fP T} T{ do not use T} _ .TE .SS Per\-File Options .sp When playing multiple files, any option given on the command line usually affects all files. Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C mpv \-\-a file1.mkv \-\-b file2.mkv \-\-c .ft P .fi .UNINDENT .UNINDENT .TS center; |l|l|. _ T{ File T} T{ Active options T} _ T{ file1.mkv T} T{ \fB\-\-a \-\-b \-\-c\fP T} _ T{ file2.mkv T} T{ \fB\-\-a \-\-b \-\-c\fP T} _ .TE .sp (This is different from MPlayer and mplayer2.) .sp Also, if any option is changed at runtime (via input commands), they are not reset when a new file is played. .sp Sometimes, it is useful to change options per\-file. This can be achieved by adding the special per\-file markers \fB\-\-{\fP and \fB\-\-}\fP\&. (Note that you must escape these on some shells.) Example: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C mpv \-\-a file1.mkv \-\-b \-\-\e{ \-\-c file2.mkv \-\-d file3.mkv \-\-e \-\-\e} file4.mkv \-\-f .ft P .fi .UNINDENT .UNINDENT .TS center; |l|l|. _ T{ File T} T{ Active options T} _ T{ file1.mkv T} T{ \fB\-\-a \-\-b \-\-f\fP T} _ T{ file2.mkv T} T{ \fB\-\-a \-\-b \-\-f \-\-c \-\-d \-\-e\fP T} _ T{ file3.mkv T} T{ \fB\-\-a \-\-b \-\-f \-\-c \-\-d \-\-e\fP T} _ T{ file4.mkv T} T{ \fB\-\-a \-\-b \-\-f\fP T} _ .TE .sp Additionally, any file\-local option changed at runtime is reset when the current file stops playing. If option \fB\-\-c\fP is changed during playback of \fBfile2.mkv\fP, it is reset when advancing to \fBfile3.mkv\fP\&. This only affects file\-local options. The option \fB\-\-a\fP is never reset here. .SS List Options .sp Some options which store lists of option values can have action suffixes. For example, the \fB\-\-display\-tags\fP option takes a \fB,\fP\-separated list of tags, but the option also allows you to append a single tag with \fB\-\-display\-tags\-append\fP, and the tag name can for example contain a literal \fB,\fP without the need for escaping. .SS String list and path list options .sp String lists are separated by \fB,\fP\&. The strings are not parsed or interpreted by the option system itself. However, most path or file list options use \fB:\fP (Unix) or \fB;\fP (Windows) as separator, instead of \fB,\fP\&. .sp They support the following operations: .TS center; |l|l|. _ T{ Suffix T} T{ Meaning T} _ T{ \-set T} T{ Set a list of items (using the list separator, escaped with backslash) T} _ T{ \-append T} T{ Append single item (does not interpret escapes) T} _ T{ \-add T} T{ Append 1 or more items (same syntax as \-set) T} _ T{ \-pre T} T{ Prepend 1 or more items (same syntax as \-set) T} _ T{ \-clr T} T{ Clear the option (remove all items) T} _ T{ \-remove T} T{ Delete item if present (does not interpret escapes) T} _ T{ \-toggle T} T{ Append an item, or remove if if it already exists (no escapes) T} _ .TE .sp \fB\-append\fP is meant as a simple way to append a single item without having to escape the argument (you may still need to escape on the shell level). .SS Key/value list options .sp A key/value list is a list of key/value string pairs. In programming languages, this type of data structure is often called a map or a dictionary. The order normally does not matter, although in some cases the order might matter. .sp They support the following operations: .TS center; |l|l|. _ T{ Suffix T} T{ Meaning T} _ T{ \-set T} T{ Set a list of items (using \fB,\fP as separator) T} _ T{ \-append T} T{ Append a single item (escapes for the key, no escapes for the value) T} _ T{ \-add T} T{ Append 1 or more items (same syntax as \-set) T} _ T{ \-remove T} T{ Delete item by key if present (does not interpret escapes) T} _ .TE .sp Keys are unique within the list. If an already present key is set, the existing key is removed before the new value is appended. .sp If you want to pass a value without interpreting it for escapes or \fB,\fP, it is recommended to use the \fB\-append\fP variant. When using libmpv, prefer using \fBMPV_FORMAT_NODE_MAP\fP; when using a scripting backend or the JSON IPC, use an appropriate structured data type. .sp Prior to mpv 0.33, \fB:\fP was also recognized as separator by \fB\-set\fP\&. .SS Filter options .sp This is a very complex option type for the \fB\-\-af\fP and \fB\-\-vf\fP options only. They often require complicated escaping. See \fI\%VIDEO FILTERS\fP for details. They support the following operations: .TS center; |l|l|. _ T{ Suffix T} T{ Meaning T} _ T{ \-set T} T{ Set a list of filters (using \fB,\fP as separator) T} _ T{ \-append T} T{ Append single filter T} _ T{ \-add T} T{ Append 1 or more filters (same syntax as \-set) T} _ T{ \-pre T} T{ Prepend 1 or more filters (same syntax as \-set) T} _ T{ \-clr T} T{ Clear the option (remove all filters) T} _ T{ \-remove T} T{ Delete filter if present T} _ T{ \-toggle T} T{ Append a filter, or remove if if it already exists T} _ T{ \-help T} T{ Pseudo operation that prints a help text to the terminal T} _ .TE .SS General .sp Without suffix, the operation used is normally \fB\-set\fP\&. .sp Although some operations allow specifying multiple items, using this is strongly discouraged and deprecated, except for \fB\-set\fP\&. There is a chance that operations like \fB\-add\fP and \fB\-pre\fP will work like \fB\-append\fP and accept a single, unescaped item only (so the \fB,\fP separator will not be interpreted and is passed on as part of the value). .sp Some options (like \fB\-\-sub\-file\fP, \fB\-\-audio\-file\fP, \fB\-\-glsl\-shader\fP) are aliases for the proper option with \fB\-append\fP action. For example, \fB\-\-sub\-file\fP is an alias for \fB\-\-sub\-files\-append\fP\&. .sp Options of this type can be changed at runtime using the \fBchange\-list\fP command, which takes the suffix (without the \fB\-\fP) as separate operation parameter. .SH CONFIGURATION FILES .SS Location and Syntax .sp You can put all of the options in configuration files which will be read every time mpv is run. The system\-wide configuration file \(aqmpv.conf\(aq is in your configuration directory (e.g. \fB/etc/mpv\fP or \fB/usr/local/etc/mpv\fP), the user\-specific one is \fB~/.config/mpv/mpv.conf\fP\&. For details and platform specifics (in particular Windows paths) see the \fI\%FILES\fP section. .sp User\-specific options override system\-wide options and options given on the command line override both. The syntax of the configuration files is \fBoption=value\fP\&. Everything after a \fI#\fP is considered a comment. Options that work without values can be enabled by setting them to \fIyes\fP and disabled by setting them to \fIno\fP, and if the value is omitted, \fIyes\fP is implied. Even suboptions can be specified in this way. .INDENT 0.0 .INDENT 3.5 .IP "Example configuration file" .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C # Don\(aqt allow new windows to be larger than the screen. autofit\-larger=100%x100% # Enable hardware decoding if available, =yes is implied. hwdec # Spaces don\(aqt have to be escaped. osd\-playing\-msg=File: ${filename} .ft P .fi .UNINDENT .UNINDENT .UNINDENT .UNINDENT .SS Escaping special characters .sp This is done like with command line options. A config entry can be quoted with \fB\(dq\fP, \fB\(aq\fP, as well as with the fixed\-length syntax (\fB%n%\fP) mentioned before. This is like passing the exact contents of the quoted string as a command line option. C\-style escapes are currently _not_ interpreted on this level, although some options do this manually (this is a mess and should probably be changed at some point). The shell is not involved here, so option values only need to be quoted to escape \fB#\fP anywhere in the value, \fB\(dq\fP, \fB\(aq\fP or \fB%\fP at the beginning of the value, and leading and trailing whitespace. .SS Putting Command Line Options into the Configuration File .sp Almost all command line options can be put into the configuration file. Here is a small guide: .TS center; |l|l|. _ T{ Option T} T{ Configuration file entry T} _ T{ \fB\-\-flag\fP T} T{ \fBflag\fP T} _ T{ \fB\-opt val\fP T} T{ \fBopt=val\fP T} _ T{ \fB\-\-opt=val\fP T} T{ \fBopt=val\fP T} _ T{ \fB\-opt \(dqhas spaces\(dq\fP T} T{ \fBopt=has spaces\fP T} _ .TE .SS File\-specific Configuration Files .sp You can also write file\-specific configuration files. If you wish to have a configuration file for a file called \(aqvideo.avi\(aq, create a file named \(aqvideo.avi.conf\(aq with the file\-specific options in it and put it in \fB~/.config/mpv/\fP\&. You can also put the configuration file in the same directory as the file to be played. Both require you to set the \fB\-\-use\-filedir\-conf\fP option (either on the command line or in your global config file). If a file\-specific configuration file is found in the same directory, no file\-specific configuration is loaded from \fB~/.config/mpv\fP\&. In addition, the \fB\-\-use\-filedir\-conf\fP option enables directory\-specific configuration files. For this, mpv first tries to load a mpv.conf from the same directory as the file played and then tries to load any file\-specific configuration. .SS Profiles .sp To ease working with different configurations, profiles can be defined in the configuration files. A profile starts with its name in square brackets, e.g. \fB[my\-profile]\fP\&. All following options will be part of the profile. A description (shown by \fB\-\-profile=help\fP) can be defined with the \fBprofile\-desc\fP option. To end the profile, start another one or use the profile name \fBdefault\fP to continue with normal options. .sp You can list profiles with \fB\-\-profile=help\fP, and show the contents of a profile with \fB\-\-show\-profile=\fP (replace \fB\fP with the profile name). You can apply profiles on start with the \fB\-\-profile=\fP option, or at runtime with the \fBapply\-profile \fP command. .INDENT 0.0 .INDENT 3.5 .IP "Example mpv config file with profiles" .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C # normal top\-level option fullscreen=yes # a profile that can be enabled with \-\-profile=big\-cache [big\-cache] cache=yes demuxer\-max\-bytes=512MiB demuxer\-readahead\-secs=20 [network] profile\-desc=\(dqprofile for content over network\(dq force\-window=immediate # you can also include other profiles profile=big\-cache [reduce\-judder] video\-sync=display\-resample interpolation=yes # using a profile again extends it [network] demuxer\-max\-back\-bytes=512MiB # reference a builtin profile profile=fast .ft P .fi .UNINDENT .UNINDENT .UNINDENT .UNINDENT .SS Runtime profiles .sp Profiles can be set at runtime with \fBapply\-profile\fP command. Since this operation is \(dqdestructive\(dq (every item in a profile is simply set as an option, overwriting the previous value), you can\(aqt just enable and disable profiles again. .sp As a partial remedy, there is a way to make profiles save old option values before overwriting them with the profile values, and then restoring the old values at a later point using \fBapply\-profile restore\fP\&. .sp This can be enabled with the \fBprofile\-restore\fP option, which takes one of the following options: .INDENT 0.0 .INDENT 3.5 .INDENT 0.0 .TP .B \fBdefault\fP Does nothing, and nothing can be restored (default). .TP .B \fBcopy\fP When applying a profile, copy the old values of all profile options to a backup before setting them from the profile. These options are reset to their old values using the backup when restoring. .sp Every profile has its own list of backed up values. If the backup already exists (e.g. if \fBapply\-profile name\fP was called more than once in a row), the existing backup is no changed. The restore operation will remove the backup. .sp It\(aqs important to know that restoring does not \(dqundo\(dq setting an option, but simply copies the old option value. Consider for example \fBvf\-add\fP, appends an entry to \fBvf\fP\&. This mechanism will simply copy the entire \fBvf\fP list, and does _not_ execute the inverse of \fBvf\-add\fP (that would be \fBvf\-remove\fP) on restoring. .sp Note that if a profile contains recursive profiles (via the \fBprofile\fP option), the options in these recursive profiles are treated as if they were part of this profile. The referenced profile\(aqs backup list is not used when creating or using the backup. Restoring a profile does not restore referenced profiles, only the options of referenced profiles (as if they were part of the main profile). .TP .B \fBcopy\-equal\fP Similar to \fBcopy\fP, but restore an option only if it has the same value as the value effectively set by the profile. This tries to deal with the situation when the user does not want the option to be reset after interactively changing it. .UNINDENT .UNINDENT .UNINDENT .INDENT 0.0 .INDENT 3.5 .IP "Example" .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [something] profile\-restore=copy\-equal vf\-add=rotate=PI/2 # rotate by 90 degrees .ft P .fi .UNINDENT .UNINDENT .sp Then running these commands will result in behavior as commented: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C set vf vflip apply\-profile something vf add hflip apply\-profile something # vf == vflip,rotate=PI/2,hflip,rotate=PI/2 apply\-profile something restore # vf == vflip .ft P .fi .UNINDENT .UNINDENT .UNINDENT .UNINDENT .SS Conditional auto profiles .sp Profiles which have the \fBprofile\-cond\fP option set are applied automatically if the associated condition matches (unless auto profiles are disabled). The option takes a string, which is interpreted as Lua expression. If the expression evaluates as truthy, the profile is applied. If the expression errors or evaluates as falsy, the profile is not applied. This Lua code execution is not sandboxed. .sp Any variables in condition expressions can reference properties. If an identifier is not already defined by Lua or mpv, it is interpreted as property. For example, \fBpause\fP would return the current pause status. You cannot reference properties with \fB\-\fP this way since that would denote a subtraction, but if the variable name contains any \fB_\fP characters, they are turned into \fB\-\fP\&. For example, \fBplayback_time\fP would return the property \fBplayback\-time\fP\&. .sp A more robust way to access properties is using \fBp.property_name\fP or \fBget(\(dqproperty\-name\(dq, default_value)\fP\&. The automatic variable to property magic will break if a new identifier with the same name is introduced (for example, if a function named \fBpause()\fP were added, \fBpause\fP would return a function value instead of the value of the \fBpause\fP property). .sp Note that if a property is not available, it will return \fBnil\fP, which can cause errors if used in expressions. These are logged in verbose mode, and the expression is considered to be false. .sp Whenever a property referenced by a profile condition changes, the condition is re\-evaluated. If the return value of the condition changes from falsy or error to truthy, the profile is applied. .sp This mechanism tries to \(dqunapply\(dq profiles once the condition changes from truthy to falsy or error. If you want to use this, you need to set \fBprofile\-restore\fP for the profile. Another possibility it to create another profile with an inverse condition to undo the other profile. .sp Recursive profiles can be used. But it is discouraged to reference other conditional profiles in a conditional profile, since this can lead to tricky and unintuitive behavior. .INDENT 0.0 .INDENT 3.5 .IP "Example" .sp Make only HD video look funny: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [something] profile\-desc=HD video sucks profile\-cond=width >= 1280 hue=\-50 .ft P .fi .UNINDENT .UNINDENT .sp Make only videos containing \(dqyoutube\(dq or \(dqyoutu.be\(dq in their path brighter: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [youtube] profile\-cond=path:find(\(aqyoutu%.?be\(aq) gamma=20 .ft P .fi .UNINDENT .UNINDENT .sp If you want the profile to be reverted if the condition goes to false again, you can set \fBprofile\-restore\fP: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [something] profile\-desc=Mess up video when entering fullscreen profile\-cond=fullscreen profile\-restore=copy vf\-add=rotate=PI/2 # rotate by 90 degrees .ft P .fi .UNINDENT .UNINDENT .sp This appends the \fBrotate\fP filter to the video filter chain when entering fullscreen. When leaving fullscreen, the \fBvf\fP option is set to the value it had before entering fullscreen. Note that this would also remove any other filters that were added during fullscreen mode by the user. Avoiding this is trickier, and could for example be solved by adding a second profile with an inverse condition and operation: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [something] profile\-cond=fullscreen vf\-add=@rot:rotate=PI/2 [something\-inv] profile\-cond=not fullscreen vf\-remove=@rot .ft P .fi .UNINDENT .UNINDENT .UNINDENT .UNINDENT .sp \fBWARNING:\fP .INDENT 0.0 .INDENT 3.5 Every time an involved property changes, the condition is evaluated again. If your condition uses \fBp.playback_time\fP for example, the condition is re\-evaluated approximately on every video frame. This is probably slow. .UNINDENT .UNINDENT .sp This feature is managed by an internal Lua script. Conditions are executed as Lua code within this script. Its environment contains at least the following things: .INDENT 0.0 .TP .B \fB(function environment table)\fP Every Lua function has an environment table. This is used for identifier access. There is no named Lua symbol for it; it is implicit. .sp The environment does \(dqmagic\(dq accesses to mpv properties. If an identifier is not already defined in \fB_G\fP, it retrieves the mpv property of the same name. Any occurrences of \fB_\fP in the name are replaced with \fB\-\fP before reading the property. The returned value is as retrieved by \fBmp.get_property_native(name)\fP\&. Internally, a cache of property values, updated by observing the property is used instead, so properties that are not observable will be stuck at the initial value forever. .sp If you want to access properties, that actually contain \fB_\fP in the name, use \fBget()\fP (which does not perform transliteration). .sp Internally, the environment table has a \fB__index\fP meta method set, which performs the access logic. .TP .B \fBp\fP A \(dqmagic\(dq table similar to the environment table. Unlike the latter, this does not prefer accessing variables defined in \fB_G\fP \- it always accesses properties. .TP .B \fBget(name [, def])\fP Read a property and return its value. If the property value is \fBnil\fP (e.g. if the property does not exist), \fBdef\fP is returned. .sp This is superficially similar to \fBmp.get_property_native(name)\fP\&. An important difference is that this accesses the property cache, and enables the change detection logic (which is essential to the dynamic runtime behavior of auto profiles). Also, it does not return an error value as second return value. .sp The \(dqmagic\(dq tables mentioned above use this function as backend. It does not perform the \fB_\fP transliteration. .UNINDENT .sp In addition, the same environment as in a blank mpv Lua script is present. For example, \fBmath\fP is defined and gives access to the Lua standard math library. .sp \fBWARNING:\fP .INDENT 0.0 .INDENT 3.5 This feature is subject to change indefinitely. You might be forced to adjust your profiles on mpv updates. .UNINDENT .UNINDENT .SS Legacy auto profiles .sp Some profiles are loaded automatically using a legacy mechanism. The following example demonstrates this: .INDENT 0.0 .INDENT 3.5 .IP "Auto profile loading" .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [extension.mkv] profile\-desc=\(dqprofile for .mkv files\(dq vf=vflip .ft P .fi .UNINDENT .UNINDENT .UNINDENT .UNINDENT .sp The profile name follows the schema \fBtype.name\fP, where type can be \fBprotocol\fP for the input/output protocol in use (see \fB\-\-list\-protocols\fP), and \fBextension\fP for the extension of the path of the currently played file (\fInot\fP the file format). .sp This feature is very limited, and is considered soft\-deprecated. Use conditional auto profiles. .SH USING MPV FROM OTHER PROGRAMS OR SCRIPTS .sp There are three choices for using mpv from other programs or scripts: .INDENT 0.0 .INDENT 3.5 .INDENT 0.0 .IP 1. 3 Calling it as UNIX process. If you do this, \fIdo not parse terminal output\fP\&. The terminal output is intended for humans, and may change any time. In addition, terminal behavior itself may change any time. Compatibility cannot be guaranteed. .sp Your code should work even if you pass \fB\-\-terminal=no\fP\&. Do not attempt to simulate user input by sending terminal control codes to mpv\(aqs stdin. If you need interactive control, using \fB\-\-input\-ipc\-server\fP is recommended. This gives you access to the \fI\%JSON IPC\fP over unix domain sockets (or named pipes on Windows). .sp Depending on what you do, passing \fB\-\-no\-config\fP or \fB\-\-config\-dir\fP may be a good idea to avoid conflicts with the normal mpv user configuration intended for CLI playback. .sp Using \fB\-\-input\-ipc\-server\fP is also suitable for purposes like remote control (however, the IPC protocol itself is not \(dqsecure\(dq and not intended to be so). .IP 2. 3 Using libmpv. This is generally recommended when mpv is used as playback backend for a completely different application. The provided C API is very close to CLI mechanisms and the scripting API. .sp Note that even though libmpv has different defaults, it can be configured to work exactly like the CLI player (except command line parsing is unavailable). .sp See \fI\%EMBEDDING INTO OTHER PROGRAMS (LIBMPV)\fP\&. .IP 3. 3 As a user script (\fI\%LUA SCRIPTING\fP, \fI\%JAVASCRIPT\fP, \fI\%C PLUGINS\fP). This is recommended when the goal is to \(dqenhance\(dq the CLI player. Scripts get access to the entire client API of mpv. .sp This is the standard way to create third\-party extensions for the player. .UNINDENT .UNINDENT .UNINDENT .sp All these access the client API, which is the sum of the various mechanisms provided by the player core, as documented here: \fI\%OPTIONS\fP, \fI\%List of Input Commands\fP, \fI\%Properties\fP, \fI\%List of events\fP (also see C API), \fI\%Hooks\fP\&. .SH TAKING SCREENSHOTS .sp Screenshots of the currently played file can be taken using the \(aqscreenshot\(aq input mode command, which is by default bound to the \fBs\fP key. Files named \fBmpv\-shotNNNN.jpg\fP will be saved in the working directory, using the first available number \- no files will be overwritten. In pseudo\-GUI mode, the screenshot will be saved somewhere else. See \fI\%PSEUDO GUI MODE\fP\&. .sp A screenshot will usually contain the unscaled video contents at the end of the video filter chain and subtitles. By default, \fBS\fP takes screenshots without subtitles, while \fBs\fP includes subtitles. .sp Unlike with MPlayer, the \fBscreenshot\fP video filter is not required. This filter was never required in mpv, and has been removed. .SH TERMINAL STATUS LINE .sp During playback, mpv shows the playback status on the terminal. It looks like something like this: .INDENT 0.0 .INDENT 3.5 \fBAV: 00:03:12 / 00:24:25 (13%) A\-V: \-0.000\fP .UNINDENT .UNINDENT .sp The status line can be overridden with the \fB\-\-term\-status\-msg\fP option. .sp The following is a list of things that can show up in the status line. Input properties, that can be used to get the same information manually, are also listed. .INDENT 0.0 .IP \(bu 2 \fBAV:\fP or \fBV:\fP (video only) or \fBA:\fP (audio only) .IP \(bu 2 The current time position in \fBHH:MM:SS\fP format (\fBplayback\-time\fP property) .IP \(bu 2 The total file duration (absent if unknown) (\fBduration\fP property) .IP \(bu 2 Playback speed, e.g. \fBx2.0\fP\&. Only visible if the speed is not normal. This is the user\-requested speed, and not the actual speed (usually they should be the same, unless playback is too slow). (\fBspeed\fP property.) .IP \(bu 2 Playback percentage, e.g. \fB(13%)\fP\&. How much of the file has been played. Normally calculated out of playback position and duration, but can fallback to other methods (like byte position) if these are not available. (\fBpercent\-pos\fP property.) .IP \(bu 2 The audio/video sync as \fBA\-V: 0.000\fP\&. This is the difference between audio and video time. Normally it should be 0 or close to 0. If it\(aqs growing, it might indicate a playback problem. (\fBavsync\fP property.) .IP \(bu 2 Total A/V sync change, e.g. \fBct: \-0.417\fP\&. Normally invisible. Can show up if there is audio \(dqmissing\(dq, or not enough frames can be dropped. Usually this will indicate a problem. (\fBtotal\-avsync\-change\fP property.) .IP \(bu 2 Encoding state in \fB{...}\fP, only shown in encoding mode. .IP \(bu 2 Display sync state. If display sync is active (\fBdisplay\-sync\-active\fP property), this shows \fBDS: 2.500/13\fP, where the first number is average number of vsyncs per video frame (e.g. 2.5 when playing 24Hz videos on 60Hz screens), which might jitter if the ratio doesn\(aqt round off, or there are mistimed frames (\fBvsync\-ratio\fP), and the second number of estimated number of vsyncs which took too long (\fBvo\-delayed\-frame\-count\fP property). The latter is a heuristic, as it\(aqs generally not possible to determine this with certainty. .IP \(bu 2 Dropped frames, e.g. \fBDropped: 4\fP\&. Shows up only if the count is not 0. Can grow if the video framerate is higher than that of the display, or if video rendering is too slow. May also be incremented on \(dqhiccups\(dq and when the video frame couldn\(aqt be displayed on time. (\fBframe\-drop\-count\fP property.) If the decoder drops frames, the number of decoder\-dropped frames is appended to the display as well, e.g.: \fBDropped: 4/34\fP\&. This happens only if decoder frame dropping is enabled with the \fB\-\-framedrop\fP options. (\fBdecoder\-frame\-drop\-count\fP property.) .IP \(bu 2 Cache state, e.g. \fBCache: 2s/134KB\fP\&. Visible if the stream cache is enabled. The first value shows the amount of video buffered in the demuxer in seconds, the second value shows the estimated size of the buffered amount in kilobytes. (\fBdemuxer\-cache\-duration\fP and \fBdemuxer\-cache\-state\fP properties.) .UNINDENT .SH LOW LATENCY PLAYBACK .sp mpv is optimized for normal video playback, meaning it actually tries to buffer as much data as it seems to make sense. This will increase latency. Reducing latency is possible only by specifically disabling features which increase latency. .sp The builtin \fBlow\-latency\fP profile tries to apply some of the options which can reduce latency. You can use \fB\-\-profile=low\-latency\fP to apply all of them. You can list the contents with \fB\-\-show\-profile=low\-latency\fP (some of the options are quite obscure, and may change every mpv release). .sp Be aware that some of the options can reduce playback quality. .sp Most latency is actually caused by inconvenient timing behavior. You can disable this with \fB\-\-untimed\fP, but it will likely break, unless the stream has no audio, and the input feeds data to the player at a constant rate. .sp Another common problem is with MJPEG streams. These do not signal the correct framerate. Using \fB\-\-untimed\fP or \fB\-\-correct\-pts=no \-\-container\-fps\-override=60\fP might help. .sp For livestreams, data can build up due to pausing the stream, due to slightly lower playback rate, or \(dqbuffering\(dq pauses. If the demuxer cache is enabled, these can be skipped manually. The experimental \fBdrop\-buffers\fP command can be used to discard any buffered data, though it\(aqs very disruptive. .sp In some cases, manually tuning TCP buffer sizes and such can help to reduce latency. .sp Additional options that can be tried: .INDENT 0.0 .IP \(bu 2 \fB\-\-opengl\-glfinish=yes\fP, can reduce buffering in the graphics driver .IP \(bu 2 \fB\-\-opengl\-swapinterval=0\fP, same .IP \(bu 2 \fB\-\-vo=xv\fP, same .IP \(bu 2 without audio \fB\-\-framedrop=no \-\-speed=1.01\fP may help for live sources (results can be mixed) .UNINDENT .SH RESUMING PLAYBACK .sp mpv is capable of storing the playback position of the currently playing file and resume from there the next time that file is played. This is done with the commands \fBquit\-watch\-later\fP (bound to Shift+Q by default) and \fBwrite\-watch\-later\-config\fP, and with the \fB\-\-save\-position\-on\-quit\fP option. .sp The difference between always quitting with a key bound to \fBquit\-watch\-later\fP and using \fB\-\-save\-position\-on\-quit\fP is that the latter will save the playback position even when mpv is closed with a method other than a keybinding, such as clicking the close button in the window title bar. However if mpv is terminated abruptly and doesn\(aqt have the time to save, then the position will not be saved. For example, if you shutdown your system without closing mpv beforehand. .sp mpv also stores options other than the playback position when they have been modified after playback began, for example the volume and selected audio/subtitles, and restores their values the next time the file is played. Which options are saved can be configured with the \fB\-\-watch\-later\-options\fP option. .sp When playing multiple playlist entries, mpv checks if one them has a resume config file associated, and if it finds one it restarts playback from it. For example, if you use \fBquit\-watch\-later\fP on the 5th episode of a show, and later play all the episodes, mpv will automatically resume playback from episode 5. .sp More options to configure this functionality are listed in \fI\%Watch Later\fP\&. .SH PROTOCOLS .sp \fBhttp://...\fP, \fBhttps://\fP, ... .INDENT 0.0 .INDENT 3.5 Many network protocols are supported, but the protocol prefix must always be specified. mpv will never attempt to guess whether a filename is actually a network address. A protocol prefix is always required. .sp Note that not all prefixes are documented here. Undocumented prefixes are either aliases to documented protocols, or are just redirections to protocols implemented and documented in FFmpeg. .sp \fBdata:\fP is supported, but needs to be in the format \fBdata://\fP\&. This is done to avoid ambiguity with filenames. You can also prefix it with \fBlavf://\fP or \fBffmpeg://\fP\&. .UNINDENT .UNINDENT .sp \fBytdl://...\fP .INDENT 0.0 .INDENT 3.5 By default, the youtube\-dl hook script only looks at http(s) URLs. Prefixing an URL with \fBytdl://\fP forces it to be always processed by the script. This can also be used to invoke special youtube\-dl functionality like playing a video by ID or invoking search. .sp Keep in mind that you can\(aqt pass youtube\-dl command line options by this, and you have to use \fB\-\-ytdl\-raw\-options\fP instead. .UNINDENT .UNINDENT .sp \fB\-\fP .INDENT 0.0 .INDENT 3.5 Play data from stdin. .UNINDENT .UNINDENT .sp \fBsmb://PATH\fP .INDENT 0.0 .INDENT 3.5 Play a path from Samba share. (Requires FFmpeg support.) .UNINDENT .UNINDENT .sp \fBbd://[title][/device]\fP \fB\-\-bluray\-device=PATH\fP .INDENT 0.0 .INDENT 3.5 Play a Blu\-ray disc. Since libbluray 1.0.1, you can read from ISO files by passing them to \fB\-\-bluray\-device\fP\&. .sp \fBtitle\fP can be: \fBlongest\fP or \fBfirst\fP (selects the default playlist); \fBmpls/\fP (selects .mpls playlist); \fB\fP (select playlist with the same index). mpv will list the available playlists on loading. .sp \fBbluray://\fP is an alias. .UNINDENT .UNINDENT .sp \fBdvd://[title][/device]\fP \fB\-\-dvd\-device=PATH\fP .INDENT 0.0 .INDENT 3.5 Play a DVD. DVD menus are not supported. If no title is given, the longest title is auto\-selected. Without \fB\-\-dvd\-device\fP, it will probably try to open an actual optical drive, if available and implemented for the OS. .sp \fBdvdnav://\fP is an old alias for \fBdvd://\fP and does exactly the same thing. .UNINDENT .UNINDENT .sp \fBdvb://[cardnumber@]channel\fP \fB\-\-dvbin\-...\fP .INDENT 0.0 .INDENT 3.5 Digital TV via DVB. (Linux only.) .UNINDENT .UNINDENT .sp \fBmf://[@listfile|filemask|glob|printf\-format]\fP \fB\-\-mf\-...\fP .INDENT 0.0 .INDENT 3.5 Play a series of images as video. .sp If the URL path begins with \fB@\fP, it is interpreted as the path to a file containing a list of image paths separated by newlines. If the URL path contains \fB,\fP, it is interpreted as a list of image paths separated by \fB,\fP\&. If the URL path does not contain \fB%\fP and if on POSIX platforms, is interpreted as a glob, and \fB*\fP is automatically appended if it was not specified. Otherwise, the printf sequences \fB%[.][NUM]d\fP, where \fBNUM\fP is one, two, or three decimal digits, and \fB%%\fP and are interpreted. For example, \fBmf://image\-%d.jpg\fP plays files like \fBimage\-1.jpg\fP, \fBimage\-2.jpg\fP and \fBimage\-10.jpg\fP, provided that there are no big gaps between the files. .UNINDENT .UNINDENT .sp \fBcdda://[device]\fP \fB\-\-cdrom\-device=PATH\fP \fB\-\-cdda\-...\fP .INDENT 0.0 .INDENT 3.5 Play CD. .UNINDENT .UNINDENT .sp \fBlavf://...\fP .INDENT 0.0 .INDENT 3.5 Access any FFmpeg libavformat protocol. Basically, this passed the string after the \fB//\fP directly to libavformat. .UNINDENT .UNINDENT .sp \fBav://type:options\fP .INDENT 0.0 .INDENT 3.5 This is intended for using libavdevice inputs. \fBtype\fP is the libavdevice demuxer name, and \fBoptions\fP is the (pseudo\-)filename passed to the demuxer. .INDENT 0.0 .INDENT 3.5 .IP "Example" .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C mpv av://v4l2:/dev/video0 \-\-profile=low\-latency \-\-untimed .ft P .fi .UNINDENT .UNINDENT .sp This plays video from the first v4l input with nearly the lowest latency possible. It\(aqs a good replacement for the removed \fBtv://\fP input. Using \fB\-\-untimed\fP is a hack to output a captured frame immediately, instead of respecting the input framerate. (There may be better ways to handle this in the future.) .UNINDENT .UNINDENT .sp \fBavdevice://\fP is an alias. .UNINDENT .UNINDENT .sp \fBfile://PATH\fP .INDENT 0.0 .INDENT 3.5 A local path as URL. Might be useful in some special use\-cases. Note that \fBPATH\fP itself should start with a third \fB/\fP to make the path an absolute path. .UNINDENT .UNINDENT .sp \fBappending://PATH\fP .INDENT 0.0 .INDENT 3.5 Play a local file, but assume it\(aqs being appended to. This is useful for example for files that are currently being downloaded to disk. This will block playback, and stop playback only if no new data was appended after a timeout of about 2 seconds. .sp Using this is still a bit of a bad idea, because there is no way to detect if a file is actually being appended, or if it\(aqs still written. If you\(aqre trying to play the output of some program, consider using a pipe (\fBsomething | mpv \-\fP). If it really has to be a file on disk, use tail to make it wait forever, e.g. \fBtail \-f \-c +0 file.mkv | mpv \-\fP\&. .UNINDENT .UNINDENT .sp \fBfd://123\fP .INDENT 0.0 .INDENT 3.5 Read data from the given file descriptor (for example 123). This is similar to piping data to stdin via \fB\-\fP, but can use an arbitrary file descriptor. mpv may modify some file descriptor properties when the stream layer \(dqopens\(dq it. .UNINDENT .UNINDENT .sp \fBfdclose://123\fP .INDENT 0.0 .INDENT 3.5 Like \fBfd://\fP, but the file descriptor is closed after use. When using this you need to ensure that the same fd URL will only be used once. .UNINDENT .UNINDENT .sp \fBedl://[edl specification as in edl\-mpv.rst]\fP .INDENT 0.0 .INDENT 3.5 Stitch together parts of multiple files and play them. .UNINDENT .UNINDENT .sp \fBslice://start[\-end]@URL\fP .INDENT 0.0 .INDENT 3.5 Read a slice of a stream. .sp \fBstart\fP and \fBend\fP represent a byte range and accept suffixes such as \fBKiB\fP and \fBMiB\fP\&. \fBend\fP is optional. .sp if \fBend\fP starts with \fB+\fP, it is considered as offset from \fBstart\fP\&. .sp Only works with seekable streams. .sp Examples: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C mpv slice://1g\-2g@cap.ts This starts reading from cap.ts after seeking 1 GiB, then reads until reaching 2 GiB or end of file. mpv slice://1g\-+2g@cap.ts This starts reading from cap.ts after seeking 1 GiB, then reads until reaching 3 GiB or end of file. mpv slice://100m@appending://cap.ts This starts reading from cap.ts after seeking 100MiB, then reads until end of file. .ft P .fi .UNINDENT .UNINDENT .UNINDENT .UNINDENT .sp \fBnull://\fP .INDENT 0.0 .INDENT 3.5 Simulate an empty file. If opened for writing, it will discard all data. The \fBnull\fP demuxer will specifically pass autoprobing if this protocol is used (while it\(aqs not automatically invoked for empty files). .UNINDENT .UNINDENT .sp \fBmemory://data\fP .INDENT 0.0 .INDENT 3.5 Use the \fBdata\fP part as source data. .UNINDENT .UNINDENT .sp \fBhex://data\fP .INDENT 0.0 .INDENT 3.5 Like \fBmemory://\fP, but the string is interpreted as hexdump. .UNINDENT .UNINDENT .SH PSEUDO GUI MODE .sp mpv has no official GUI, other than the OSC (\fI\%ON SCREEN CONTROLLER\fP), which is not a full GUI and is not meant to be. However, to compensate for the lack of expected GUI behavior, mpv will in some cases start with some settings changed to behave slightly more like a GUI mode. .sp Currently this happens only in the following cases: .INDENT 0.0 .IP \(bu 2 if started using the \fBmpv.desktop\fP file on Linux (e.g. started from menus or file associations provided by desktop environments) .IP \(bu 2 if started from explorer.exe on Windows (technically, if it was started on Windows, and all of the stdout/stderr/stdin handles are unset) .IP \(bu 2 started out of the bundle on macOS .IP \(bu 2 if you manually use \fB\-\-player\-operation\-mode=pseudo\-gui\fP on the command line .UNINDENT .sp This mode applies options from the builtin profile \fBbuiltin\-pseudo\-gui\fP, but only if these haven\(aqt been set in the user\(aqs config file or on the command line, which is the main difference to using \fB\-\-profile=builtin\-pseudo\-gui\fP\&. .sp The profile is currently defined as follows: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [builtin\-pseudo\-gui] terminal=no force\-window=yes idle=once screenshot\-directory=~~desktop/ .ft P .fi .UNINDENT .UNINDENT .sp The \fBpseudo\-gui\fP profile exists for compatibility. The options in the \fBpseudo\-gui\fP profile are applied unconditionally. In addition, the profile makes sure to enable the pseudo\-GUI mode, so that \fB\-\-profile=pseudo\-gui\fP works like in older mpv releases: .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C [pseudo\-gui] player\-operation\-mode=pseudo\-gui .ft P .fi .UNINDENT .UNINDENT .sp \fBWARNING:\fP .INDENT 0.0 .INDENT 3.5 Currently, you can extend the \fBpseudo\-gui\fP profile in the config file the normal way. This is deprecated. In future mpv releases, the behavior might change, and not apply your additional settings, and/or use a different profile name. .UNINDENT .UNINDENT .SH OPTIONS .SS Track Selection .INDENT 0.0 .TP .B \fB\-\-alang=\fP Specify a priority list of audio languages to use, as IETF language tags. Equivalent ISO 639\-1 two\-letter and ISO 639\-2 three\-letter codes are treated the same. The first tag in the list whose language matches a track in the file will be used. A track that matches more subtags will be preferred over one that matches fewer, with preference given to earlier subtags over later ones. See also \fB\-\-aid\fP\&. .sp This is a string list option. See \fI\%List Options\fP for details. .INDENT 7.0 .INDENT 3.5 .IP "Examples" .INDENT 0.0 .IP \(bu 2 \fBmpv dvd://1 \-\-alang=hu,en\fP chooses the Hungarian language track on a DVD and falls back on English if Hungarian is not available. .IP \(bu 2 \fBmpv \-\-alang=jpn example.mkv\fP plays a Matroska file with Japanese audio. .UNINDENT .UNINDENT .UNINDENT .TP .B \fB\-\-slang=\fP Equivalent to \fB\-\-alang\fP, for subtitle tracks. .sp This is a string list option. See \fI\%List Options\fP for details. .INDENT 7.0 .INDENT 3.5 .IP "Examples" .INDENT 0.0 .IP \(bu 2 \fBmpv dvd://1 \-\-slang=hu,en\fP chooses the Hungarian subtitle track on a DVD and falls back on English if Hungarian is not available. .IP \(bu 2 \fBmpv \-\-slang=jpn example.mkv\fP plays a Matroska file with Japanese subtitles. .IP \(bu 2 \fBmpv \-\-slang=pt\-BR example.mkv\fP plays a Matroska file with Brazilian Portuguese subtitles if available, and otherwise any Portuguese subtitles. .UNINDENT .UNINDENT .UNINDENT .TP .B \fB\-\-vlang=<...>\fP Equivalent to \fB\-\-alang\fP and \fB\-\-slang\fP, for video tracks. .sp This is a string list option. See \fI\%List Options\fP for details. .TP .B \fB\-\-aid=\fP Select audio track. \fBauto\fP selects the default, \fBno\fP disables audio. See also \fB\-\-alang\fP\&. mpv normally prints available audio tracks on the terminal when starting playback of a file. .sp \fB\-\-audio\fP is an alias for \fB\-\-aid\fP\&. .sp \fB\-\-aid=no\fP or \fB\-\-audio=no\fP disables audio playback. (The latter variant does not work with the client API.) .sp \fBNOTE:\fP .INDENT 7.0 .INDENT 3.5 The track selection options (\fB\-\-aid\fP but also \fB\-\-sid\fP and the others) sometimes expose behavior that may appear strange. Also, the behavior tends to change around with each mpv release. .sp The track selection properties will return the option value outside of playback (as expected), but during playback, the affective track selection is returned. For example, with \fB\-\-aid=auto\fP, the \fBaid\fP property will suddenly return \fB2\fP after playback initialization (assuming the file has at least 2 audio tracks, and the second is the default). .sp At mpv 0.32.0 (and some releases before), if you passed a track value for which a corresponding track didn\(aqt exist (e.g. \fB\-\-aid=2\fP and there was only 1 audio track), the \fBaid\fP property returned \fBno\fP\&. However if another audio track was added during playback, and you tried to set the \fBaid\fP property to \fB2\fP, nothing happened, because the \fBaid\fP option still had the value \fB2\fP, and writing the same value has no effect. .sp With mpv 0.33.0, the behavior was changed. Now track selection options are reset to \fBauto\fP at playback initialization, if the option had tries to select a track that does not exist. The same is done if the track exists, but fails to initialize. The consequence is that unlike before mpv 0.33.0, the user\(aqs track selection parameters are clobbered in certain situations. .sp Also since mpv 0.33.0, trying to select a track by number will strictly select this track. Before this change, trying to select a track which did not exist would fall back to track default selection at playback initialization. The new behavior is more consistent. .sp Setting a track selection property at runtime, and then playing a new file might reset the track selection to defaults, if the fingerprint of the track list of the new file is different. .sp Be aware of tricky combinations of all of all of the above: for example, \fBmpv \-\-aid=2 file_with_2_audio_tracks.mkv file_with_1_audio_track.mkv\fP would first play the correct track, and the second file without audio. If you then go back the first file, its first audio track will be played, and the second file is played with audio. If you do the same thing again but instead of using \fB\-\-aid=2\fP you run \fBset aid 2\fP while the file is playing, then changing to the second file will play its audio track. This is because runtime selection enables the fingerprint heuristic. .sp Most likely this is not the end. .UNINDENT .UNINDENT .TP .B \fB\-\-sid=\fP Display the subtitle stream specified by \fB\fP\&. \fBauto\fP selects the default, \fBno\fP disables subtitles. .sp \fB\-\-sub\fP is an alias for \fB\-\-sid\fP\&. .sp \fB\-\-sid=no\fP or \fB\-\-sub=no\fP disables subtitle decoding. (The latter variant does not work with the client API.) .TP .B \fB\-\-vid=\fP Select video channel. \fBauto\fP selects the default, \fBno\fP disables video. .sp \fB\-\-video\fP is an alias for \fB\-\-vid\fP\&. .sp \fB\-\-vid=no\fP or \fB\-\-video=no\fP disables video playback. (The latter variant does not work with the client API.) .sp If video is disabled, mpv will try to download the audio only if media is streamed with youtube\-dl, because it saves bandwidth. This is done by setting the ytdl_format to \(dqbestaudio/best\(dq in the ytdl_hook.lua script. .TP .B \fB\-\-edition=\fP (Matroska files only) Specify the edition (set of chapters) to use, where 0 is the first. If set to \fBauto\fP (the default), mpv will choose the first edition declared as a default, or if there is no default, the first edition defined. .TP .B \fB\-\-track\-auto\-selection=\fP Enable the default track auto\-selection (default: yes). Enabling this will make the player select streams according to \fB\-\-aid\fP, \fB\-\-alang\fP, and others. If it is disabled, no tracks are selected. In addition, the player will not exit if no tracks are selected, and wait instead (this wait mode is similar to pausing, but the pause option is not set). .sp This is useful with \fB\-\-lavfi\-complex\fP: you can start playback in this mode, and then set select tracks at runtime by setting the filter graph. Note that if \fB\-\-lavfi\-complex\fP is set before playback is started, the referenced tracks are always selected. .TP .B \fB\-\-subs\-with\-matching\-audio=\fP When autoselecting a subtitle track, select it even if the selected audio stream matches you preferred subtitle language (default: yes). If this option is set to \fBno\fP, then no subtitle track that matches the audio language will ever be autoselected by mpv regardless of \fB\-\-slang\fP or \fBsubs\-fallback\fP\&. If set to \fBforced\fP, then only forced subtitles will be selected. .TP .B \fB\-\-subs\-match\-os\-language=\fP When autoselecting a subtitle track, select the track that matches the language of your OS if the audio stream is in a different language if suitable (default track or a forced track under the right conditions). Note that if \fB\-slang\fP is set, this will be completely ignored (default: yes). .TP .B \fB\-\-subs\-fallback=\fP When autoselecting a subtitle track, if no tracks match your preferred languages, select a full track even if it doesn\(aqt match your preferred subtitle language (default: default). Setting this to \fIdefault\fP means that only streams flagged as \fIdefault\fP will be selected. .TP .B \fB\-\-subs\-fallback\-forced=\fP When autoselecting a subtitle track, the default value of \fIyes\fP will prefer using a forced subtitle track if the subtitle language matches the audio language and matches your list of preferred languages. The special value \fIalways\fP will only select forced subtitle tracks and never fallback on a non\-forced track. Conversely, \fIno\fP will never select a forced subtitle track. .UNINDENT .SS Playback Control .INDENT 0.0 .TP .B \fB\-\-start=\fP Seek to given time position. .sp The general format for times is \fB[+|\-][[hh:]mm:]ss[.ms]\fP\&. If the time is prefixed with \fB\-\fP, the time is considered relative from the end of the file (as signaled by the demuxer/the file). A \fB+\fP is usually ignored (but see below). .sp The following alternative time specifications are recognized: .sp \fBpp%\fP seeks to percent position pp (0\-100). .sp \fB#c\fP seeks to chapter number c. (Chapters start from 1.) .sp \fBnone\fP resets any previously set option (useful for libmpv). .sp If \fB\-\-rebase\-start\-time=no\fP is given, then prefixing times with \fB+\fP makes the time relative to the start of the file. A timestamp without prefix is considered an absolute time, i.e. should seek to a frame with a timestamp as the file contains it. As a bug, but also a hidden feature, putting 1 or more spaces before the \fB+\fP or \fB\-\fP always interprets the time as absolute, which can be used to seek to negative timestamps (useful for debugging at most). .INDENT 7.0 .INDENT 3.5 .IP "Examples" .INDENT 0.0 .TP .B \fB\-\-start=+56\fP, \fB\-\-start=00:56\fP Seeks to the start time + 56 seconds. .TP .B \fB\-\-start=\-56\fP, \fB\-\-start=\-00:56\fP Seeks to the end time \- 56 seconds. .TP .B \fB\-\-start=01:10:00\fP Seeks to 1 hour 10 min. .TP .B \fB\-\-start=50%\fP Seeks to the middle of the file. .TP .B \fB\-\-start=30 \-\-end=40\fP Seeks to 30 seconds, plays 10 seconds, and exits. .TP .B \fB\-\-start=\-3:20 \-\-length=10\fP Seeks to 3 minutes and 20 seconds before the end of the file, plays 10 seconds, and exits. .TP .B \fB\-\-start=\(aq#2\(aq \-\-end=\(aq#4\(aq\fP Plays chapters 2 and 3, and exits. .UNINDENT .UNINDENT .UNINDENT .TP .B \fB\-\-end=\fP Stop at given time. Use \fB\-\-length\fP if the time should be relative to \fB\-\-start\fP\&. See \fB\-\-start\fP for valid option values and examples. .TP .B \fB\-\-length=\fP Stop after a given time relative to the start time. See \fB\-\-start\fP for valid option values and examples. .sp If both \fB\-\-end\fP and \fB\-\-length\fP are provided, playback will stop when it reaches either of the two endpoints. .sp Obscurity note: this does not work correctly if \fB\-\-rebase\-start\-time=no\fP, and the specified time is not an \(dqabsolute\(dq time, as defined in the \fB\-\-start\fP option description. .TP .B \fB\-\-rebase\-start\-time=\fP Whether to move the file start time to \fB00:00:00\fP (default: yes). This is less awkward for files which start at a random timestamp, such as transport streams. On the other hand, if there are timestamp resets, the resulting behavior can be rather weird. For this reason, and in case you are actually interested in the real timestamps, this behavior can be disabled with \fBno\fP\&. .TP .B \fB\-\-speed=<0.01\-100>\fP Slow down or speed up playback by the factor given as parameter. .sp If \fB\-\-audio\-pitch\-correction\fP (on by default) is used, playing with a speed higher than normal automatically inserts the \fBscaletempo2\fP audio filter. .TP .B \fB\-\-pause\fP Start the player in paused state. .TP .B \fB\-\-shuffle\fP Play files in random order. .TP .B \fB\-\-playlist\-start=\fP Set which file on the internal playlist to start playback with. The index is an integer, with 0 meaning the first file. The value \fBauto\fP means that the selection of the entry to play is left to the playback resume mechanism (default). If an entry with the given index doesn\(aqt exist, the behavior is unspecified and might change in future mpv versions. The same applies if the playlist contains further playlists (don\(aqt expect any reasonable behavior). Passing a playlist file to mpv should work with this option, though. E.g. \fBmpv playlist.m3u \-\-playlist\-start=123\fP will work as expected, as long as \fBplaylist.m3u\fP does not link to further playlists. .sp The value \fBno\fP is a deprecated alias for \fBauto\fP\&. .TP .B \fB\-\-playlist=\fP Play files according to a playlist file. Supports some common formats. If no format is detected, it will be treated as list of files, separated by newline characters. You may need this option to load plaintext files as a playlist. Note that XML playlist formats are not supported. .sp This option forces \fB\-\-demuxer=playlist\fP to interpret the playlist file. Some playlist formats, notably CUE and optical disc formats, need to use different demuxers and will not work with this option. They still can be played directly, without using this option. .sp You can play playlists directly, without this option. Before mpv version 0.31.0, this option disabled any security mechanisms that might be in place, but since 0.31.0 it uses the same security mechanisms as playing a playlist file directly. If you trust the playlist file, you can disable any security checks with \fB\-\-load\-unsafe\-playlists\fP\&. Because playlists can load other playlist entries, consider applying this option only to the playlist itself and not its entries, using something along these lines: .INDENT 7.0 .INDENT 3.5 \fBmpv \-\-{ \-\-playlist=filename \-\-load\-unsafe\-playlists \-\-}\fP .UNINDENT .UNINDENT .sp \fBWARNING:\fP .INDENT 7.0 .INDENT 3.5 The way older versions of mpv played playlist files via \fB\-\-playlist\fP was not safe against maliciously constructed files. Such files may trigger harmful actions. This has been the case for all versions of mpv prior to 0.31.0, and all MPlayer versions, but unfortunately this fact was not well documented earlier, and some people have even misguidedly recommended the use of \fB\-\-playlist\fP with untrusted sources. Do NOT use \fB\-\-playlist\fP with random internet sources or files you do not trust if you are not sure your mpv is at least 0.31.0. .sp In particular, playlists can contain entries using protocols other than local files, such as special protocols like \fBavdevice://\fP (which are inherently unsafe). .UNINDENT .UNINDENT .TP .B \fB\-\-chapter\-merge\-threshold=\fP Threshold for merging almost consecutive ordered chapter parts in milliseconds (default: 100). Some Matroska files with ordered chapters have inaccurate chapter end timestamps, causing a small gap between the end of one chapter and the start of the next one when they should match. If the end of one playback part is less than the given threshold away from the start of the next one then keep playing video normally over the chapter change instead of doing a seek. .TP .B \fB\-\-chapter\-seek\-threshold=\fP Distance in seconds from the beginning of a chapter within which a backward chapter seek will go to the previous chapter (default: 5.0). Past this threshold, a backward chapter seek will go to the beginning of the current chapter instead. A negative value means always go back to the previous chapter. .TP .B \fB\-\-hr\-seek=\fP Select when to use precise seeks that are not limited to keyframes. Such seeks require decoding video from the previous keyframe up to the target position and so can take some time depending on decoding performance. For some video formats, precise seeks are disabled. This option selects the default choice to use for seeks; it is possible to explicitly override that default in the definition of key bindings and in input commands. .INDENT 7.0 .TP .B no Never use precise seeks. .TP .B absolute Use precise seeks if the seek is to an absolute position in the file, such as a chapter seek, but not for relative seeks like the default behavior of arrow keys. .TP .B default Like \fBabsolute\fP, but enable hr\-seeks in audio\-only cases. The exact behavior is implementation specific and may change with new releases (default). .TP .B yes Use precise seeks whenever possible. .TP .B always Same as \fByes\fP (for compatibility). .UNINDENT .TP .B \fB\-\-hr\-seek\-demuxer\-offset=\fP This option exists to work around failures to do precise seeks (as in \fB\-\-hr\-seek\fP) caused by bugs or limitations in the demuxers for some file formats. Some demuxers fail to seek to a keyframe before the given target position, going to a later position instead. The value of this option is subtracted from the time stamp given to the demuxer. Thus, if you set this option to 1.5 and try to do a precise seek to 60 seconds, the demuxer is told to seek to time 58.5, which hopefully reduces the chance that it erroneously goes to some time later than 60 seconds. The downside of setting this option is that precise seeks become slower, as video between the earlier demuxer position and the real target may be unnecessarily decoded. .TP .B \fB\-\-hr\-seek\-framedrop=\fP Allow the video decoder to drop frames during seek, if these frames are before the seek target. If this is enabled, precise seeking can be faster, but if you\(aqre using video filters which modify timestamps or add new frames, it can lead to precise seeking skipping the target frame. This e.g. can break frame backstepping when deinterlacing is enabled. .sp Default: \fByes\fP .TP .B \fB\-\-index=\fP Controls how to seek in files. Note that if the index is missing from a file, it will be built on the fly by default, so you don\(aqt need to change this. But it might help with some broken files. .INDENT 7.0 .TP .B default use an index if the file has one, or build it if missing .TP .B recreate don\(aqt read or use the file\(aqs index .UNINDENT .sp \fBNOTE:\fP .INDENT 7.0 .INDENT 3.5 This option only works if the underlying media supports seeking (i.e. not with stdin, pipe, etc). .UNINDENT .UNINDENT .TP .B \fB\-\-load\-unsafe\-playlists\fP Load URLs from playlists which are considered unsafe (default: no). This includes special protocols and anything that doesn\(aqt refer to normal files. Local files and HTTP links on the other hand are always considered safe. .sp In addition, if a playlist is loaded while this is set, the added playlist entries are not marked as originating from network or potentially unsafe location. (Instead, the behavior is as if the playlist entries were provided directly to mpv command line or \fBloadfile\fP command.) .TP .B \fB\-\-access\-references=\fP Follow any references in the file being opened (default: yes). Disabling this is helpful if the file is automatically scanned (e.g. thumbnail generation). If the thumbnail scanner for example encounters a playlist file, which contains network URLs, and the scanner should not open these, enabling this option will prevent it. This option also disables ordered chapters, mov reference files, opening of archives, and a number of other features. .sp On older FFmpeg versions, this will not work in some cases. Some FFmpeg demuxers might not respect this option. .sp This option does not prevent opening of paired subtitle files and such. Use \fB\-\-autoload\-files=no\fP to prevent this. .sp This option does not always work if you open non\-files (for example using \fBdvd://directory\fP would open a whole bunch of files in the given directory). Prefixing the filename with \fB\&./\fP if it doesn\(aqt start with a \fB/\fP will avoid this. .TP .B \fB\-\-loop\-playlist=\fP, \fB\-\-loop\-playlist\fP Loops playback \fBN\fP times. A value of \fB1\fP plays it one time (default), \fB2\fP two times, etc. \fBinf\fP means forever. \fBno\fP is the same as \fB1\fP and disables looping. If several files are specified on command line, the entire playlist is looped. \fB\-\-loop\-playlist\fP is the same as \fB\-\-loop\-playlist=inf\fP\&. .sp The \fBforce\fP mode is like \fBinf\fP, but does not skip playlist entries which have been marked as failing. This means the player might waste CPU time trying to loop a file that doesn\(aqt exist. But it might be useful for playing webradios under very bad network conditions. .TP .B \fB\-\-loop\-file=\fP, \fB\-\-loop=\fP Loop a single file N times. \fBinf\fP means forever, \fBno\fP means normal playback. For compatibility, \fB\-\-loop\-file\fP and \fB\-\-loop\-file=yes\fP are also accepted, and are the same as \fB\-\-loop\-file=inf\fP\&. .sp The difference to \fB\-\-loop\-playlist\fP is that this doesn\(aqt loop the playlist, just the file itself. If the playlist contains only a single file, the difference between the two option is that this option performs a seek on loop, instead of reloading the file. .sp \fBNOTE:\fP .INDENT 7.0 .INDENT 3.5 \fB\-\-loop\-file\fP counts the number of times it causes the player to seek to the beginning of the file, not the number of full playthroughs. This means \fB\-\-loop\-file=1\fP will end up playing the file twice. Contrast with \fB\-\-loop\-playlist\fP, which counts the number of full playthroughs. .UNINDENT .UNINDENT .sp \fB\-\-loop\fP is an alias for this option. .TP .B \fB\-\-ab\-loop\-a=