summaryrefslogtreecommitdiffstats
path: root/DOCS
Commit message (Collapse)AuthorAgeFilesLines
* edl: add a way to add tagsYour Name2021-05-111-0/+20
| | | | | | | | Add new header which shows up as tags/metadata (associated with --display-tags). The way this is added means it doesn't always work, because root->meta (see code) can be NULL for some absurd reason. But it works for the one case I intended to use it (ytdl_hook, see next commit), though only in default configurations.
* command: add display-width/display-height propertyDudemanguy2021-05-061-0/+5
| | | | | | | | | For some reason, this never existed before. Add VOCTRL_GET_DISPLAY_RES and use it to obtain the current display's resolution from each vo/windowing backend if applicable. Users can then access the current display resolution as display-width and display-height as per the client api. Note that macOS/cocoa was not attempted in this commit since the author has no clue how to write swift.
* DOCS/input.rst: clarify --no-input-default-keybindings docsAvi Halachmi (:avih)2021-05-041-1/+4
| | | | | | | | | | | | | | This commit describes more accurately what currently gets disabled by this option - specifically also keys from mp.add_key_binding. It's not necessarily the best behavior because libmpv clients might want to disable mpv's own builtin keybindings while still allowing scripts to define keys which `input.conf' can override. In the future we might exclude mp.add_key_binding from this option, but for now at least document this option accurately. Fixes #8809
* DOCS/lua.rst: fix docs for utils.file_infoAvi Halachmi (:avih)2021-05-031-1/+1
| | | | | | | | | | | | | | The ctime member on Windows uses FILE_BASIC_INFO.ChangeTime, which is pretty much the same as st_ctime on POSIX. See https://devblogs.microsoft.com/oldnewthing/20100709-00/?p=13463 : ... The Last­Write­Time covers writes to the file’s data stream (which you accomplish via the Write­File function). On the other hand, the Change­Time also includes changes to the file metadata, such as changing its file attributes ... Fixes #8801
* command: new property: pid (process id)Avi Halachmi (:avih)2021-05-011-0/+3
| | | | Fixes #7562
* DOCS: clarify how client/script names workDudemanguy2021-04-292-4/+12
| | | | | This isn't really clearly stated anywhere and could understandably lead to some confusion.
* command: osd-dimensions: return ints and doc fixesDudemanguy2021-04-291-2/+2
| | | | | | Some subproperties in osd-dimensions were returned as doubles despite actually being integers. Additionally, correct a highly misleading line in the osd-width/osd-height documentation.
* DOCS: mpv.rst: minor escaping clarificationsAvi Halachmi (:avih)2021-04-231-1/+4
| | | | Fixes #8767
* options: win32: ignore and deprecate --fit-borderAvi Halachmi (:avih)2021-04-231-6/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The accurate description of this option was: - fit-border is enabled by default. When disabled, it adds a bug where if the window has borders and mpv shrinks it to fit the desktop, then the calculation ignores the borders and adds incorrect video crop. The option was added at commits 70f64f3c and 949247d6, in order to solve an issue (#2935) where if mpv wanted to display a video with size WxH, then w32_common.c incorrectly set the window to WxH, while down-scaling the video slightly to fit (even with small sizes). It was addressed with a new option which is enabled by default, but does the right thing (sets the client area to WxH) only when disabled, so that everyone who prefers their video slightly downscaled could keep their default behavior. (#2935 also addressed an off-by-one issue, fixed before fit-border) While disabling the option did avoid unnecessary downscaling, it also added a bug when disabled: the borders are no longer taken into account when the size is too big for the desktop. Most users don't notice and are unaffected as it's enabled by default. Shortly later (981048e0) the core issue is fixed, and now the client area is correctly set to WxH instead of the window (and together with the three following commits which center the video, adds a new bug where the window title can be outside the display - addressed next). However, fit-border remained, now without any effect, except that it still has the same bug when disabled and the window is too big. Later code changes and refactoring preserved this issue with great attention to details, and it remained in identical form until now. Simply rip out fit-border.
* demux: undeprecate --cache-secssfan52021-04-082-6/+1
| | | | | It serves a purpose and a rework of the cache won't be coming anytime soon. This partially reverts commit 8427292eb7c4074e1205c3d73c53c9e82569325f.
* manpage: fix a typo in the --aid option noteun.def2021-04-051-1/+1
|
* vo_gpu: adjust interpolation_threshold's defaultLaserEyess2021-03-281-6/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When mpv attempts to play a video that is, on average, 60 FPS on a display that is not exactly 60.00 Hz, two options try to fight each other: `video-sync-max-video-change` and `interpolation-threshold`. Normally, container FPS in something such as an .mp4 or a .mkv is precise enough such that the video can be retimed exactly to the display Hz and interpolation is not activated. In the case of something like certain live streaming videos or other scenario where container FPS is not known, the default option of 0.0001 for `interpolation-threshold` is extremely low, and while `video-sync-max-video-change` retimes the video to what it approximately knows as the "real" FPS, this may or may not be outside of `interpolation-threshold`'s logic at any given time, which causes interpolation to be frequently flipped on and off giving an appearance of stuttering or repeated frames that is oftern quite jarring and makes a video unwatchable. This commit changes the default of `interpolation-threshold` to 0.01, which is the same value as `video-sync-max-video-change`, and guarantees that if the user accepts a video being retimed to match the display, they do not additionally have to worry about a much more precise interpolation threshold randomly flipping on or off. No internal logic is changed so setting `interpolation-threshold` to -1 will still disable this logic entirely and always enable interpolation. The documentation has been updated to reflect this change and give context to the user for which scenarios they might want to disable `interpolation-threshold` logic or change it to a smaller value.
* ao_oss: add this audio output againrim2021-03-151-1/+4
| | | | | | | | | | | Changes: - code refactored; - mixer options removed; - new mpv sound API used; - add sound devices detect (mpv --audio-device=help will show all available devices); - only OSSv4 supported now; Tested on FreeBSD 12.2 amd64.
* player/command: add albumart argument to video-addTom Wilson2021-03-092-2/+7
| | | | | | Enables marking of specific video sources as album art. Co-authored-by: Jan Ekström <jeebjp@gmail.com>
* manpage: mention rotate limitations with hwdecGuido Cella2021-03-021-0/+4
|
* manpage: video-rotate supports arbitrary stepsGuido Cella2021-03-021-5/+4
| | | | | The 90° step limitation must be a leftover from old behavior since any value between 0 and 359 works now.
* mac: support --on-all-workspaces optionEvgeny Zinoviev2021-02-211-1/+1
|
* filters/auto_filters: switch from scaletempo to scaletempo2Jan Ekström2021-02-151-2/+2
| | | | | | | Part 1 of "look how well it performs, then start cleaning up the old one." Closes #8376
* DOCS: fix cplugins information in libmpv.rst.Érico Rolim2021-02-121-2/+2
|
* man: update deband-threshold defaultMia Herkt2021-02-051-1/+1
|
* manpage: fix PDF buildgaroto2021-01-231-4/+6
| | | | | Not clear what exactly makes it fail with this change, but making the note paragraph added in d5ab5482a9 a note structure seems to fix it.
* docs: Fix an old style parameter referenceChris Varenhorst2021-01-201-1/+1
| | | | `--vf format:stereo-in=help` no longer works. It now must be `--vf=format:stereo-in=help`
* manpage: document off-by-one loop-file behaviorLeo Izen2021-01-071-0/+5
| | | | | loop-file counts the number of zero-seeks, not playthroughs, which makes its counter off by one compared to loop-playlist.
* manpage: rename OS X references to macOSLeo Izen2021-01-034-36/+36
| | | | | | | | Apple has decided that Mac OS X is now named macOS for the time being. For consistency, it makes sense to use the same name for the operating system in all places where it occurs. This commit renames OS X to macOS in the documentation in places where it was otherwise still using the old name.
* input.conf syntax: support custom quotes !XstringX!Avi Halachmi (:avih)2020-12-311-8/+18
| | | | | | | | | | Where X is any ASCII char chosen by the user. An argument is only interpreted as custom-quoted if it starts with '!' and the line doesn't end right after it. Custom quotes don't interpret backslash-escape. This change only affects command arguments which mpv parses (not array commands), and not tokens before the arguments (where applicable - key name, input section, command prefixes, command name).
* input.rst: fix typo commands -> argumentsAvi Halachmi (:avih)2020-12-311-1/+1
|
* vd_lavc: add VP8 to the default allowed hwdec codec listEmmanuel Gil Peyrot2020-12-301-1/+1
| | | | | It is supported at least on Intel, from gen8 to gen11, and still gives a pretty welcome reduction of CPU usage on my gen9.
* mac: use visible frame rectangle for window geometry calculationder richter2020-12-192-1/+16
| | | | | | | | | | | | | currently we use the whole screen rectangle to calculate the window geometry. this doesn't take the menu bar or the Dock into account. by default use the visible screen rectangle instead. this is also a change in behaviour, since the window can't be placed outside of this rectangle anymore. also add an option to change to the old behaviour, because it can still be useful in certain cases, like placing the window directly underneath the menu bar when used a desktop background. Fixes #8272
* console: use wl-paste on WaylandGuido Cella2020-12-141-2/+2
|
* manpage: document background transparencyGuido Cella2020-12-081-7/+7
| | | | | | | | | | | | | | | --alpha=yes doesn't affect only transparent videos and images, but also the background. I spent time researching how to implement transparent backgrounds and had no idea that they already worked at least on Wayland. Background transparency will work on X11 when https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/2376 is merged. It doesn't work on Windows. No idea about macOS. Either way, this paragraph already says that it only works on certain environments twice. References #6590
* manpage: clarify that you can prefetch m3u8 urlsGuido Cella2020-12-081-5/+7
| | | | | | | | | | | With the current wording, I thought that playlist-prefetch doesn't prefetch the next url within a playlist of m3u8 urls, but it makes a big difference, and I would have enabled it earlier if it wasn't for this paragraph. This makes it clear that you can prefetch any file, but that it won't prefill the cache with the video data. This is true for any video, there's nothing unique about HLS streams in the behavior of this option.
* player: add --screen-name and --fs-screen-nameDudemanguy2020-12-062-0/+15
| | | | | | Simple groundwork for adding a couple of user options that allow selecting the screen with a string name. The next two commits implements these options for xorg and wayland.
* manpage: clarify profile-cond requires underscoresGuido Cella2020-12-061-3/+5
| | | | | | | While this says that _ is replaced with -, it doesn't say that you HAVE to use _. This isn't obvious and I didn't understand why my profile conditions with - weren't working at first. Seeing as the person who reproted #8324 ran into this as well, this may be worth clarifying.
* vo_sixel: change default dither to "auto"Avi Halachmi (:avih)2020-11-271-3/+3
| | | | | | | | | | | | | | For two reasons: 1. It was counter intuitive that there's an "auto" value (which is actually a libsixel value and not an mpv one), but it's not the default value - our default was Atkinson. 2. "auto" provides better dithering than Atkinson with libsixel, which is especially noticeable with smooth gradients - where Atkinson has visible banding. In libsixel 1.8.2 the "auto" value maps to Atkinson if the output palette has up to 16 colors, or to Floyd-Steinberg otherwise (e.g. using fixed palette with 256 colors chooses Floyd-Steinberg).
* vo_sixel: fix the image corruption with mltermAvi Halachmi (:avih)2020-11-271-9/+7
| | | | | | | | | | | | | | | | | | | | | | | | The issue was that we only uploaded the palette to the terminal when it changed (once on init with fixed palette, every frame with dynamic palette with trheshold=-1, only on scene change with threshold >= 0). Now we upload it on every frame, and it seems to fix the mlterm image corruption both with fixed palette and also with dynamic palette with threshold (i.e. at frames which did not upload a palette). It's not entirely clear why it's required with mlterm. It would seem that the palette which libsixel uses with fixed palette matches the built in default palette in xterm, but not in mlterm. With dynamic palette we can guess that mlterm resets the palette after a sixel image, but that's not confirmed. Uploading the palette on every frame doesn't seem to slow down xterm when using fixed palette - not clear yet why uploading a different palette (when using fixedpalette=no) slows it down while same palette on every frame doesn't. In mlterm there's no slowdown either way - and now also no corruption.
* vo_sixel: support --vo-sixel-exit-clear[=yes]Avi Halachmi (:avih)2020-11-271-0/+4
| | | | | | | | By default we still clear the screen, but now it's possible to leave the last sixel image on screen. Allows mpv to be used as img2sixel of sorts, but with our auto-fit and various mpv scaling/filters etc.
* Revert "options: disable vsfilter blur compat by default"rcombs2020-11-221-1/+1
| | | | | | | | | | | | | | | This reverts commit 3d17e19c2c5ca80f916411e7e61126cac8443baa. The effect of turning off this setting is that mpv doesn't tell libass what the video stream's resolution is. This happens to result in some files having their transforms scaled in ways that give higher performance (as described in #7435) because libass happened to guess a video resolution that resulted in transforms yielding smaller bitmaps, but it's just as easy for the opposite to happen depending on the resolutions and effects involved. The option's name is also somewhat misleading: setting the storage size affects blur, but it also affects stroke (which is far more important for the vast majority of scripts) and 3D transforms (which look very screwy when done wrong).
* vo_sixel: Add aspect ratio based output centeringShreesh Adiga2020-11-221-35/+63
| | | | | | | | | | | | | | | | | | | | | | | | | | Resize the image based on the dimensions reported by vo_get_src_dst_rects to correctly handle aspect ratio that might be set/ignored. Added pad-x and pad-y options for padding. These options will be used to remove the extra padding. Some terminals report the padding of 2px in the ioctl dimensions which can't be used for displaying sixel output. These options can be used for fine tuning the output video resolution. Now all the terminal size detection and calculation logic is done in a single function at resize. Also top and left values are computed from the dst_rect parameters to simplify the logic for the aspect ratio based centering. Additionally vo-sixel-rows and vo-sixel-cols options have been added to enable the user to override the values in case of failures with get_terminal_size2. This commit also adds ability to handle video zoom correctly. Whenever video-zoom is triggered, the src and dst rects will be updated. Scaling seems to work well now.
* doc: split BNF definitions of <command> and <argument> in separate linesEmanuele Torre2020-11-221-2/+3
| | | | | | Having them in the same line made it hard to read them in the man page since they are formatted in the same way and they look as though they are only one definition.
* manpage: document improved --playlist securityLeo Izen2020-11-181-18/+28
| | | | | | | Recent versions of mpv have applied security checks to --playlist that previously only existed if playlist files were played as an input directly. This commit documents this change and how to work around it, in the event that playlist files are trusted.
* docs/input.rst: document the mouse-pos propertyAvi Halachmi (:avih)2020-11-161-0/+14
|
* path: do not use old_home for win32 exe dirwm42020-11-161-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | Apparently mpv supports loading config files from the same directory as the mpv.exe. This is a fallback of some sort. It used the old_home mechanism. I want to add a warning if old_home exists, but that would always show the warning on win32. Obviously we don't want that. Add a separate exe_dir entry to deal with that. Untested, but probably works. Mistakenly reverted as part of the default configuration directory location switch-back in aa18a8e1cde663caeabd93af7d57a745c1a76af6. Separation of the mpv executable directory from old_path is a good change now that we warn about the old_config directory also existing. Fixes #8232 Fixes #8244 Fixes #8262
* js: report scripts CPU/memory usage statisticsAvi Halachmi (:avih)2020-11-151-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This can be viewed at page 4 of the internal stats display (i or I). CPU time report is the same as at lua.c, but untested - doesn't seem to work on windows - also not for lua. TL;DR: Set env MPV_LEAK_REPORT=1 to enable js memory reporting stats. This also almost doubles the memory usage by js scripts. For memory reporting, we don't have enough info by default, because even when using a custom allocator, mujs doesn't report the old size (on free or realloc) because it doesn't track this value, and as a result we can't track the overall size. Our option are either to track the size of each allocation on our own, or use talloc which tracks this value. However, using talloc for mujs allocations adds a considerable overhead, and almost doubles(!) the overall memory used, because each individual allocation includes a considerable talloc header, and mujs does many small allocations. So our solution is that by default we behave like previously - not using a custom allocator with mujs, and stats does not display memory usage for js scripts. However, if the env var MPV_LEAK_REPORT is set to 1, then we use a custom allocator with talloc and track/report memory usage. We can't switch allocator at runtime, so an mpv instance either tracks or doesn't track js scripts memory usage, according to the env var. (we could use a property and apply it whenever a new script starts, so that it could change for newly launched scripts, but we don't).
* manpage: properties fixesGuido Cella2020-11-111-17/+21
| | | | | | | | | | | - Explain which properties are writeable. - Mark edition-list/N/id as writable. - Remove (R) from some read-only properties since none of the others have it. - Add osd-dimension/ to its subproperties. - options/<name> isn't read-only. - focused works on macOS because of 82eda2e. Though it shouldn't be possible to observe it without raising VO_EVENT_FOCUS.
* manpage: document the property-change eventGuido Cella2020-11-111-0/+11
|
* manpage: document video-frame-info sub-propertiesGuido Cella2020-11-111-5/+13
| | | | | | | The picture type is explained in /usr/include/libavutil/avutil.h Other subproperties in /usr/include/libavutil/frame.h And there is a more detailed explanation for repeat_pict in /usr/include/libavcodec/avcodec.h
* manpage: remove redundant "Return(s) "Guido Cella2020-11-111-59/+58
| | | | | | ...from the property descriptions that include it, and reformat the paragraphs. And say "Returns" in idle-active.
* manpage: document demuxer-cache-state betterGuido Cella2020-11-111-4/+11
|
* manpage: be consistent with booleansGuido Cella2020-11-111-73/+73
| | | | | | | | | | | | | When possible, refer to booleans with "Whether..." since it can refer to both yes (using input.conf and mp.get_property) and true (using the JSON IPC or mp.get_property_native/bool), else explicitly say yes/true. Say "true" for subprocess and osd-overlay named arguments since you can't use them in input.conf and you will typically use them with the boolean true in the named arguments, like the subprocess example in the manpage does (though the string "yes" also works). Subproperties that can't be accessed with the / syntax like demuxer-cache-state's bof-cached and eof-cached always return true, never yes.
* DOCS: correct interface-changes.rstDudemanguy2020-11-071-2/+2
| | | | delete-watch-later-config was introduced in mpv 0.33.0 not mpv 0.31.0.
* video/out/vo_sixel.c: Implement sixel as a output deviceShreesh Adiga2020-11-071-0/+68
| | | | | | | | | | | | | | | | | | | | | | | | | | Based on the implementation of ffmpeg's sixel backend output written by Hayaki Saito https://github.com/saitoha/FFmpeg-SIXEL/blob/sixel/libavdevice/sixel.c Sixel is a protocol to display graphics in a terminal. This commit adds support to play videos on a sixel enabled terminal using libsixel. With --vo=sixel, the output will be in sixel format. The input frame will be scaled to the user specified resolution (--vo-sixel-width and --vo-sixel-height) using swscaler and then encoded using libsixel and output to the terminal. This method requires high cpu and there are high frame drops for 720p and higher resolution videos and might require using lesser colors and have drop in quality. Docs have all the supported options listed to fine tune the output quality. TODO: A few parameters of libsixel such as the sixel_encode_policy and the SIXEL_XTERM16 variables are hardcoded, might want to expose them as command line options. Also the initialization resolution is not automatic and if the user doesn't specify the dimensions, it picks 320x240 as the default resolution which is not optimal. So need to automatically pick the best fit resolution for the current open terminal window size.
* manpage: document av1 addition to --hwdec-codecs default settingLeo Izen2020-11-051-1/+1
| | | | | Document the change to add AV1 to the list of default hwdec codecs, in commit 172146e9f7a231b5de21921d883612d18b13a717.
* input.conf: add default keybindings for sub-scalesoredake2020-10-271-0/+3
|
* console: let type set the cursor positionGuido Cella2020-10-271-2/+8
| | | | | | | | | | | | | | | | | | This allows keybindings such as: a script-message-to console type "seek :0 absolute" 6 % script-message-to console type "seek absolute-percent" 6 The cursor position 0 isn't allowed because it has the weird effect of filling the console wit