summaryrefslogtreecommitdiffstats
path: root/DOCS/man
Commit message (Collapse)AuthorAgeFilesLines
* man/mpv: document bd:// expected titles and title listRicardo Constantino2017-08-111-0/+5
|
* cocoa: add an option to disable the native macOS fullscreenAkemi2017-08-061-0/+4
| | | | Fixes #4014
* w32_common: handle media keysJames Ross-Gowan2017-08-051-1/+1
| | | | | | | | | | | | | | | | | This was attempted before in fc9695e63b5b, but it was reverted in 1b7ce759b1f4 because it caused conflicts with other software watching the same keys (See #2041.) It seems like some PCs ship with OEM software that watches the volume keys without consuming key events and this causes them to be handled twice, once by mpv and once by the other software. In order to prevent conflicts like this, use the WM_APPCOMMAND message to handle media keys. Returning TRUE from the WM_APPCOMMAND handler should indicate to the operating system that we consumed the key event and it should not be propogated to the shell. Also, we now only listen for keys that are directly related to multimedia playback (eg. the APPCOMMAND_MEDIA_* keys.) Keys like APPCOMMAND_VOLUME_* are ignored, so they can be handled by the shell, or by other mixer software.
* vo_opengl: support embedded ICC profilesNiklas Haas2017-08-031-0/+6
| | | | | | | | | | | | | | | | This currently only works when using lcms-based color management (--icc-profile-*). In principle, we could also support using lcms even when the user has not specified an ICC profile, by generating the profile against a fixed reference (--target-prim/--target-trc) instead. I still might do that some day, simply because 3dlut provides a higher quality conversion than our simple gamut mapping does for stuff like BT.2020, and also because it's now needed to enable embedded ICC profiles. But that would be a separate change, so preserve the status quo for now. (Besides, my opinion is still that you should be using an ICC profile if you care about colors being accurate _at all_)
* vo_opengl: make compute shaders more flexibleNiklas Haas2017-08-031-7/+17
| | | | | | This allows users to do their own custom sample writing, mainly meant to address use cases such as RAVU. Also clean up the compute shader code a bit.
* vo_opengl: simplify/fix user shader textureswm42017-08-031-10/+12
| | | | | | | | | | | | | | | | | | | | This broke float textures, which were actually used by some shaders. There were probably some other bugs as well. Lots of code can be avoided by using ra_tex_params directly, so do that. The main change is that COMPONENT/FORMAT are replaced by a single FORMAT directive, which takes different parameters now. Due to the mess with 16/32 bit float textures, and because we want to support other APIs than just GL in the future, it's not really clear how this should be handled, and the nice component/type separation makes things actually harder. So just jump the gun and use the ra_format.name names, which were originally meant mostly for debugging. (This is probably something that will be regretted later.) Still only superficially tested, but seems to work. Fixes #4708.
* vo_opengl: generalize HDR tone mapping to gamut mappingNiklas Haas2017-08-031-7/+9
| | | | | | | | | | | | | | | | | | | | | | Since this code was already written for HDR, and is now per-channel (because it works better for HDR as well), we can actually reuse this to get very high quality gamut mapping without clipping. The only required change is to move the tone mapping from before the gamut map to after the gamut map. Additonally, we need to also account for changes in the signal range as a result of applying the CMS when we compute ref_peak, which is fortunately pretty easy because we only need to consider the case of primaries mapping to themselves. Since `HDR` no longer really makes sense as a label, rename it to `--tone-mapping` in general. Also fits better with `--tone-mapping-desat` etc. Arguably we could also rename `--hdr-compute-peak`, but that option is basically only useful for HDR content anyway because we don't need information about the signal range for gamut mapping. This (finally!) gives us reasonably high quality gamut mapping even in the absence of an ICC profile / 3DLUT.
* vo_opengl: support loading custom user texturesNiklas Haas2017-07-271-13/+48
| | | | | | | | | | | Parsing the texture data as raw strings makes the textures the most portable and self-contained. In order to facilitate different types of shaders, the parse_user_shader interaction has been changed to instead have it loop through blocks and call the passed functions for each valid block parsed. This is more modular and also cleaner, with better code separation. Closes #4586.
* vo_opengl: adjust the rules for linearizationNiklas Haas2017-07-241-2/+4
| | | | | | | | | | | | | | | | | | Two changes, compounded into one since they affect the same logic: 1. Never use linearization for HDR downscaling 2. Always use linearization for interpolation Instead of fixing p->use_linear at the beginning of pass_render_frame, we flip it on "dynamically" as needed. I plan on killing this p->use_linear frame (along with other per-pass metadata) and moving them into their own struct for tracking the "current" state of the video, but that's a separate/upcoming refactor. As a small bonus, reduce some code duplication in the interpolation logic. Fixes #4631
* manpage: expand --hwdec warningsNiklas Haas2017-07-241-17/+36
| | | | | | | | | | | | | I've found more test cases where hwdec=cuda shits itself, even hwdec=cuda-copy. So the whole “copyback is no worse than swdec” is simply not true. Also, in the light of 10 bit media files and APIs silently truncating to 8 bit, the warnings need to be generalized a bit. It's no longer safe to say that “doesn't convert to RGB” means “perfect playback”. I've also added a very strong disclaimer to the whole hwdec scenario clarifying why hwdec is usually a bad idea unless absolutely needed, because I've seen issue after issue that is resolved by disabling hwdec.
* vo_opengl: support user compute shadersNiklas Haas2017-07-241-0/+11
| | | | | These are identical to regular fragment shader hooks, but with extra metadata indicating the preferred block size.
* vo_opengl: support HDR peak detectionNiklas Haas2017-07-241-0/+8
| | | | | | | | | | | | | | This is done via compute shaders. As a consequence, the tone mapping algorithms had to be rewritten to compute their known constants in GLSL (ahead of time), instead of doing it once. Didn't affect performance. Using shmem/SSBO atomics in this way is extremely fast on nvidia, but it might be slow on other platforms. Needs testing. Unfortunately, setting up the SSBO still requires OpenGL calls, which means I can't have it in video_shaders.c, where it belongs. But I'll defer worrying about that until the backend refactor, since then I'll be breaking up the video/video_shaders structure anyway.
* vo_opengl: add direct rendering supportwm42017-07-241-0/+17
| | | | | | | | | | | | | | | | | | | | Can be enabled via --vd-lavc-dr=yes. See manpage additions for what it does. This reminds of the MPlayer -dr flag, but the implementation is completely different. It's the same basic concept: letting the decoder render into a GPU buffer to avoid a copy. Unlike MPlayer, this doesn't try to go through filters (libavfilter doesn't support this anyway). Unless a filter can work in-place, DR will be silently disabled. MPlayer had very complex semantics about buffer types and management (which apparently nobody ever understood) and weird restrictions that mostly limited it to mpeg2 style codecs. The mpv code does not do any of this, and just lets the decoder allocate an arbitrary number of untyped images. (No MPlayer code was used.) Parts of the code based on work by atomnuker (starting point for the generic code) and haasn (some GL definitions, some basic PBO code, and correct fencing).
* options: drop --video-aspect-method=hybridwm42017-07-211-4/+1
| | | | | | | | | Remove this code because it could be argued that it contains GPL-only code (see commit 642e963c860 for details). The remaining aspect methods appear to work just as well, are potentially more compatible to other players, and the code becomes much simpler.
* options: kill --field-dominancewm42017-07-213-14/+2
| | | | GPL-only author, no chance of relicensing.
* manpage: fix minor spelling mistake in mpv.rstJames Cowgill2017-07-191-1/+1
| | | | Found by https://lintian.debian.org/
* manpage: upcase JavaScript for section title case consistency.torque2017-07-171-1/+1
|
* vo_opengl: use glBufferSubData instead of glMapBufferRangeNiklas Haas2017-07-161-3/+0
| | | | | | | | | | | | | | | | | | | | Performance seems pretty much unchanged but I no longer get nasty spikes on NUMA systems, probably because glBufferSubData runs in the driver or something. As a simplification of the code, we also just size the PBO to always have the full size, even for cropped textures. This seems slower but not by relevant amounts, and only affects e.g. --vf=crop. It also slightly increases VRAM usage for textures with big strides. This new code path is especially nice because it no longer depends on GL_ARB_map_buffer_range, and no longer uses any functions that can possibly fail, thus simplifying control flow and seemingly deprecating the manpage's claim about possible image corruption. In theory we could also reduce NUM_PBO_BUFFERS since it doesn't seem like we're streaming uploads anyway, but leave it in there just in case some drivers disagree...
* vo_opengl: generalize --scale-clamp etc.Niklas Haas2017-07-121-6/+10
| | | | | This can help fight ringing without completely killing it, thus providing a middle-ground between ringing and aliasing.
* man/options: fix a few broken options' examplesRicardo Constantino2017-07-121-16/+14
|
* ytdl_hook: actually load the script-optsRicardo Constantino2017-07-111-3/+3
| | | | | Also, comma-separated list doesn't actually work, even quote-surrounded. Switch to using | instead.
* ytdl_hook: add option to exclude URLs from being parsedRicardo Constantino2017-07-111-0/+20
| | | | | | | | | This is more of a niche usecase than --ytdl-format and --ytdl-raw-options, so a simple script option should be enough. Either create lua-settings/ytdl_hook.conf with 'exclude=example.com,sub.example.com' option or "--script-opts=ytdl_hook-exclude=example.com,sub.example.com"
* manpage: add a description for --scaleNiklas Haas2017-07-091-0/+1
| | | | For some reason this wasn't actually documented.
* vo_opengl: support tone-mapping-param for `clip`Niklas Haas2017-07-071-0/+3
| | | | | | | This just indicates a fixed linear coefficient to multiply into the signal, similar to the old option --target-brightness (but the inverse thereof). Good for testing purposes, which is why I added it. (This also corresponds somewhat to what zimg does)
* vo_opengl: rework --opengl-dumb-modeNiklas Haas2017-07-071-4/+4
| | | | | | | It's now possible to request non-dumb mode as a user, even when not using any non-dumb features. This change is mostly intended for testing, so I can easily switch between dumb and non-dumb mode on default settings. The default behavior is unaffected.
* demux_lavf: remove --demuxer-lavf-cryptokey optionwm42017-07-061-4/+0
| | | | | | | | Was at least somewhat broken, and is misleading. I don't really have an idea why FFmpeg has two AVOptions here anyway. We don't need to care, and I'm only aware of 1 user trying this option ever. See #4579.
* js: utils.getenv(): fix crash on undefined varAvi Halachmi (:avih)2017-07-061-1/+2
|
* vo_opengl: also expose NAME_mul for user shadersNiklas Haas2017-07-061-0/+8
| | | | | | | | | This is exposed so that bjin/mpv-prescalers can use textureGatherOffset for performance. Since there are now quite a lot of parameters where it isn't quite clear why they're all defined, add a paragraph to the man page that explains them a bit.
* vo_opengl: add --tone-mapping-desaturateNiklas Haas2017-07-061-0/+10
| | | | | | | This helps prevent unnaturally, weirdly colorized blown out highlights for direct images of the sunlit sky and other way-too-bright HDR content. I was debating whether to set the default at 1.0 or 2.0, but went with the more conservative option that preserves more detail/color.
* vo_opengl: use textureGatherOffset for polar filtersNiklas Haas2017-07-051-1/+1
| | | | | | | | | | | | | | | | | | This is more efficient on my machine (nvidia), but only when applied to groups of exactly 4 texels. So we switch to the more efficient textureGather for groups of 4. Some notes: - textureGatherOffset seems to be faster than textureGather by a non-negligible amount, but for some reason, textureOffset is still slower than a straight-up texture - textureGather* requires GLSL 400; and at least on nvidia, this requires actually allocating a GL 4.0 context. - the code in opengl/common.c that clamped the GLSL version to 330 is deprecated, because the old user shader style has been removed completely in the meantime - To combat the growing complexity of the polar sampling code, we drop the antiringing functionality from EWA shaders completely, since it never really worked well for EWA to begin with. (Horrific artifacting)
* filter_kernels: add radius cutoff functionalityNiklas Haas2017-07-031-0/+8
| | | | | | | | This allows filter functions to be prematurely cut off once their contributions start becoming insignificant. This effectively prevents wasted GPU time sampling from parts of the function that are essentially reduced to zero by the window function, providing anywhere from a 10% to 20% speedup. (5700μs -> 4700μs for me)
* options: change everything againwm42017-07-022-24/+28
| | | | Fucking bullshit.
* vo_opengl: refactor vo performance subsystemNiklas Haas2017-07-012-24/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This replaces `vo-performance` by `vo-passes`, bringing with it a number of changes and improvements: 1. mpv users can now introspect the vo_opengl passes, which is something that has been requested multiple times. 2. performance data is now measured per-pass, which helps both development and debugging. 3. since adding more passes is cheap, we can now report information for more passes (e.g. the blit pass, and the osd pass). Note: we also switch to nanosecond scale, to be able to measure these passes better. 4. `--user-shaders` authors can now describe their own passes, helping users both identify which user shaders are active at any given time as well as helping shader authors identify performance issues. 5. the timing data per pass is now exported as a full list of samples, so projects like Argon-/mpv-stats can immediately read out all of the samples and render a graph without having to manually poll this option constantly. Due to gl_timer's design being complicated (directly reading performance data would block, so we delay the actual read-back until the next _start command), it's vital not to conflate different passes that might be doing different things from one frame to another. To accomplish this, the actual timers are stored as part of the gl_shader_cache's sc_entry, which makes them unique for that exact shader. Starting and stopping the time measurement is easy to unify with the gl_sc architecture, because the existing API already relies on a "generate, render, reset" flow, so we can just put timer_start and timer_stop in sc_generate and sc_reset, respectively. The ugliest thing about this code is that due to the need to keep pass information relatively stable in between frames, we need to distinguish between "new" and "redrawn" frames, which bloats the code somewhat and also feels hacky and vo_opengl-specific. (But then again, this entire thing is vo_opengl-specific)
* options: change path list options, and document list optionswm42017-06-302-8/+55
| | | | | | | | | | | | | | | | | | | | | | | The changes to path list options is basically getting rid of the need to pass multiple paths to a single option. Instead, you can use the option multiple times. The old behavior can be used by using the -set suffix with the option. Change some options to path lists. For example --script is now append by default, and if you use --script-set, you need to use ":"/";" as separator instead of ",". --sub-paths/--audio-file-paths is a deprecated alias now, and will break if the user tries to pass multiple paths to it. I'm assuming that if these are used, most users will pass only 1 path anyway. --opengl-shaders has more compatibility handling, since it's probably rather common that users pass multiple options to it. Also document all that in the manpage. I'll probably regret this later, as it somewhat increases the complexity of the option parser, rather than increasing it.
* ao_coreaudio: insane hack for passing through AC3 as float PCMwm42017-06-301-0/+9
| | | | | This uses the same hack as Kodi uses, and I suspect MPlayer/ancient mpv also did this (but didn't research that).
* video: change --video-aspect-method default value againwm42017-06-291-6/+9
| | | | | | I noticed that the previous default, bitstream, actually breaks with some shitty anamorphic DVD rips that signal square pixel aspect in the bitstream. So I think the "container" method is a better default.
* manpage: fix unfinished sentencewm42017-06-291-1/+2
| | | | | | | No idea what I intended to write here, so I'm finishing it in some way that makes sense (going by the commit that added it). Fixes #4525.
* input.conf: drop TV/DVB bindingswm42017-06-271-7/+2
| | | | Is anyone still using them? Well, I'm removing them anyway.
* manpage: fix --angle-swapchain-length requirementsJames Ross-Gowan2017-06-261-1/+1
| | | | This should also make a difference with the Windows 7 Platform Update.
* manpage: Remove documentation to use 'I' to show filename on the OSDLeo Izen2017-06-211-3/+0
| | | | | | A relic of mplayer had 'I' as the keybind to show the filename of the currently playing file on the OSD. mpv does not do this by default. This commit removes this incorrect information from the mpv manage.
* man/options: correct --{sub,osd}-font examplesRicardo Constantino2017-06-211-2/+2
| | | | Comic Sans is a good font that did nothing wrong.
* vo_opengl: implement sony s-log2 trcNiklas Haas2017-06-182-0/+3
| | | | | | | | Apparently this is virtually identical to Panasonic's V-Log, but using the constants from S-Log1 and an extra scaling coefficient to make the S-Log1 curve less limited. Whatever floats their NIH boat, I guess. Source: https://pro.sony.com/bbsccms/assets/files/micro/dmpc/training/S-Log2_Technical_PaperV1_0.pdf
* vo_opengl: implement sony s-log1 trcNiklas Haas2017-06-182-0/+3
| | | | | | | | Source: https://pro.sony.com/bbsccms/assets/files/mkt/cinema/solutions/slog_manual.pdf Not 100% confident in the implementation since the values from the spec seem to be very subtly off (~1%), but it should be close enough for practical purposes.
* csputils: implement sony s-gamutNiklas Haas2017-06-181-0/+2
| | | | The S-Log "matching" colorspace
* vo_opengl: implement support for OOTFs and non-display referred contentNiklas Haas2017-06-182-0/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | This introduces (yet another..) mp_colorspace members, an enum `light` (for lack of a better name) which basically tells us whether we're dealing with scene-referred or display-referred light, but also a bit more metadata (in which way is the scene-referred light expected to be mapped to the display?). The addition of this parameter accomplishes two goals: 1. Allows us to actually support HLG more-or-less correctly[1] 2. Allows people playing back direct “camera” content (e.g. v-log or s-log2) to treat it as scene-referred instead of display-referred [1] Even better would be to use the display-referred OOTF instead of the idealized OOTF, but this would require either native HLG support in LittleCMS (unlikely) or more communication between lcms.c and video_shaders.c than I'm remotely comfortable with That being said, in principle we could switch our usage of the BT.1886 EOTF to the BT.709 OETF instead and treat BT.709 content as being scene-referred under application of the 709+1886 OOTF; which moves that particular conversion from the 3dlut to the shader code; but also allows a) users like UliZappe to turn it off and b) supporting the full HLG OOTF in the same framework. But I think I prefer things as they are right now.
* csputils: rename HDR curvesNiklas Haas2017-06-182-6/+6
| | | | | | | | | | st2084 and std-b67 are really weird names for PQ and HLG, which is what everybody else (including e.g. the ITU-R) calls them. Follow their example. I decided against naming them bt2020-pq and bt2020-hlg because it's not necessary in this case. The standard name is only used for the other colorspaces etc. because those literally have no other names.
* video: refactor HDR implementationNiklas Haas2017-06-183-18/+8
| | | | | | | | | | | | | | | List of changes: 1. Kill nom_peak, since it's a pointless non-field that stores nothing of value and is _always_ derived from ref_white anyway. 2. Kill ref_white/--target-brightness, because the only case it really existed for (PQ) actually doesn't need to be this general: According to ITU-R BT.2100, PQ *always* assumes a reference monitor with a white point of 100 cd/m². 3. Improve documentation and comments surrounding this stuff. 4. Clean up some of the code in general. Move stuff where it belongs.
* dec_video: change license to LGPL (almost)wm42017-06-181-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | "Almost" because this might contain copyright by michael, who agreed with LGPL, but only once the core is LGPL. This is preparation for that to happen. Apart from that, the usual remarks apply. In particular, dec_video.c started out quite chaotic with no modularization, but was later basically gutted, and in general rewritten a bunch of times. Not going to give a history lesson. Special attention needs to be given to 3 patches by cehosos, who did not agree to the relicensing: 240b743ebdf: --field-dominance e32cbbf7dc3: reinit VO if aspect ratio changes 306f6243fdf: use container aspect if codec aspect unset (?) The first patch is pretty clearly still in the current code, and needs to be disabled for LGPL. The functionality of the second patch is still active, but implemented completely different, and as part of general frame parameter changes (at the time of the patch, MPlayer already reinitialized the VO on frame size and pixel format changes - all this was merged into a single check for changing image parameters). The third patch makes me a bit more uncomfortable. It appears the code was moved to dec_video.c in de68b8f23c8c, and further changed in 82f0d373, 0a0bb905, and bf13bd0d. You could claim that cehoyos' copyright still sticks. Fortunately, we implement alternative aspect detection, which is simpler and probably preferable, and which arguably contains none of the original code and logic, and thus should be fully safe. While I don't know if cehoyos' copyright actually still applies, I'm more comfortable with making the code GPL-only for now. Also change the default to use the (in future) plain LGPL code, and deprecate the one associated with the GPL code, so we can eventually remove the GPL code. But it's also possible we decide that the copyright doesn't apply, and undo the deprecation and GPL guards. I expect that users won't notice anything. If you ask me, the old aspect method was probably an accidental bug instead of intentional behavior. Although, the new aspect method was broken too, so I had to fix it.
* image_writer, vo_image: change license to LGPLwm42017-06-181-8/+0
| | | | | | | | | | | | | | | | | | image_writer.c has code originating from vf_screenshot.c, vo_jpeg.c, and potentially others.