aboutsummaryrefslogtreecommitdiffhomepage
path: root/video/out/vo_drm.c
Commit message (Collapse)AuthorAge
* vo_drm: fallback to vo_wait_default if VT switcher is not availableGravatar rslovers2017-06-08
| | | | | | | | | | | | | | | | | | | When the drm video output is used under VT with a terminal multiplexer like screen, the VT_SETMODE ioctl call will fail since the controlling terminal is a pseudoterminal instead of a real one, thus the VT switcher will be unavailable. The problem is, the wait_events function inside vo_drm.c will test for this, and will do nothing if the switcher is not active. Normally, this would not be noticed, however, when you pause a video, or if you're playing multiple image files, mpv will suddenly start busy waiting on a single core. I confirmed this by building mpv with gprof support, in a few seconds, wait_events got called about 90 million times. So I added a fallback, when the VT switcher is not availble, just use the vo_wait_default function. I tested it and it's working well so far.
* vo_drm: remove 2 redundant include statementsGravatar wm42017-01-09
| | | | They're already pulled in by drm_common.h.
* drm: include <poll.h> instead of <sys/poll.h>Gravatar wm42017-01-09
| | | | | | | I'm not sure what systems have <sys/poll.h> (maybe there are historical reasons why some would), but POSIX defines <poll.h>. Although this code is full of highly OS specific calls (like ioctl()), there's no reason not to use the more standard include path.
* options: remove deprecated sub-option handling for --vo and --aoGravatar wm42016-11-25
| | | | | | | | Long planned. Leads to some sanity. There still are some rather gross things. Especially g_groups is ugly, and a hack that can hopefully be removed. (There is a plan for it, but whether it's implemented depends on how much energy is left.)
* vo_drm: change CLI options + refactorsGravatar rr-2016-10-07
| | | | | | | | | | - Change connector selection to accept human readable names (such as eDP-1, HDMI-A-2) rather than arbitrary numbers. - Change GPU selection to accept GPU number rather than device paths. - Merge connector and GPU selection into one --drm-connector. - Add support for --drm-connector=help. - Add support for --drm-* in EGL backend. - Refactor KMS; reduce state sharing across drm_common.
* vo_drm: fix segfault when using invalid cardGravatar rr-2016-10-06
|
* vo_drm: refactor getting display fpsGravatar rr-2016-10-04
| | | | | | | | Reduces code duplication between OpenGL backend and DRM VO. (The control() for OpenGL backend isn't sufficiently similar to the VO's control() to consider merging it as a whole - I extracted only the FPS code.)
* vo_drm: provide display fpsGravatar rr-2016-09-26
|
* vo: remove unused VOCTRL_GET_PANSCANGravatar wm42016-09-08
| | | | | | It was used to determine whether the VO supports VOCTRL_SET_PANSCAN. With all those changes to property semantics this became unnecessary, and its only use was dropped at some point.
* options: deprecate suboptions for the remaining AO/VOsGravatar wm42016-09-05
|
* vo_opengl: allow backends to provide callbacks for custom event loopsGravatar wm42016-07-20
| | | | | | | Until now, this has been either handled over vo.event_fd (which should go away), or by putting event handling on a separate thread. The backends which do the latter do it for a reason and won't need this, but X11 and Wayland will, in order to get rid of event_fd.
* Change GPL/LGPL dual-licensed files to LGPLGravatar wm42016-01-19
| | | | | | | | | | | Do this to make the license situation less confusing. This change should be of no consequence, since LGPL is compatible with GPL anyway, and making it LGPL-only does not restrict the use with GPL code. Additionally, the wording implies that this is allowed, and that we can just remove the GPL part.
* video: switch from using display aspect to sample aspectGravatar wm42015-12-19
| | | | | | | | | | | | | | | | MPlayer traditionally always used the display aspect ratio, e.g. 16:9, while FFmpeg uses the sample (aka pixel) aspect ratio. Both have a bunch of advantages and disadvantages. Actually, it seems using sample aspect ratio is generally nicer. The main reason for the change is making mpv closer to how FFmpeg works in order to make life easier. It's also nice that everything uses integer fractions instead of floats now (except --video-aspect option/property). Note that there is at least 1 user-visible change: vf_dsize now does not set the display size, only the display aspect ratio. This is because the image_params d_w/d_h fields did not just set the display aspect, but also the size (except in encoding mode).
* vo_drm: relicense to LGPLGravatar rr-2015-11-08
| | | | | Also removed authorship information (as per convention seen in other files)
* vo_drm: use bool rather than integer return valuesGravatar rr-2015-11-08
| | | | | Since the errors weren't used for anything other than simple success/fail checks, I simplified things a bit.
* vo_drm: move initialization to drm_commonGravatar rr-2015-11-08
| | | | | Makes KMS initialization procedures reusable so that they can be used by the upcoming DRM EGL adapter.
* vo_drm: show osd in audio only modeGravatar Paul B Mahol2015-10-29
| | | | Signed-off-by: Paul B Mahol <onemda@gmail.com>
* video/out: remove an unused parameterGravatar wm42015-10-03
| | | | | | | | | | | This parameter has been unused for years (the last flag was removed in commit d658b115). Get rid of it. This affects the general VO API, as well as the vo_opengl backend API, so it touches a lot of files. The VOFLAGs are still used to control OpenGL context creation, so move them to the OpenGL backend code.
* vo_drm: make VT switching non mandatoryGravatar rr-2015-06-28
|
* vo_drm: fixed crashes with --profile=pseudo-guiGravatar Marcin Kurczewski2015-06-13
|
* vo_drm: fix not using BUF_COUNTGravatar Marcin Kurczewski2015-05-29
|
* vo_drm: fix centering with regard to strideGravatar Marcin Kurczewski2015-05-29
|
* vo_drm: Expose mode ID option to usersGravatar Marcin Kurczewski2015-05-28
|
* vo_drm: Fix resolution not restored after exitingGravatar Marcin Kurczewski2015-05-28
|
* vo_drm: Fix stride problem for certain devicesGravatar Marcin Kurczewski2015-05-28
|
* vo_drm: allow changing video rectangle settingsGravatar wm42015-05-08
| | | | | | | | | Now among other things panscan can be changed during playback. Unfortunately, it flickers. The issue is that reconfig() clears the framebuffer. Removing the clearing shows that the "unused" parts of the picture are not cleared - even though OSD could render there. As such, this is a separate issue.
* vo_drm: don't mutate the current frame when clamping for panscanGravatar wm42015-05-08
| | | | | | When running with --panscan=1, this could crash - because the current frame was reduced in size each time the image was redrawn, which would result in a failed assertion the second time it's drawn.
* vo_drm: zero screen buffers in reconfig function.Gravatar akemi-san2015-04-27
|
* vo_drm: add window screenshots supportGravatar Marcin Kurczewski2015-04-26
|
* vo_drm: fix return value for void functionGravatar Marcin Kurczewski2015-04-21
|
* vo_drm: fix coding style to adhere to guidelinesGravatar Marcin Kurczewski2015-04-21
|
* vo_drm: fix releasing VT if received signal twiceGravatar Marcin Kurczewski2015-04-21
| | | | | | If user switched terminals frantically, mpv could get SIGUSR1 twice in a row, which, up until now, resulted in destroying CRTC twice. This caused it to segfault. After this fix, double SIGUSR1 should be ignored.
* vo_drm: add vertical syncGravatar Marcin Kurczewski2015-04-21
|
* vo_drm: extract vt_switcher to drm_commonGravatar Marcin Kurczewski2015-04-19
|
* vo_drm: disable VT switcher for non-Linux systemsGravatar Marcin Kurczewski2015-04-19
|
* vo_drm: fix logging problems with connectorsGravatar Marcin Kurczewski2015-04-18
| | | | | | | Logging was meant to be silenced only when user uses connector auto-detection feature. If user supplies connector ID manually, he should see exact reason why connecting to this specific connector failed.
* vo_drm: fix VT behavior with auxiliary screensGravatar Marcin Kurczewski2015-04-18
| | | | Fixes #1828
* vo_drm: fix VT switchingGravatar Marcin Kurczewski2015-04-18
| | | | Fixes #1827
* vo_drm: add KMS/DRM renderer supportGravatar Marcin Kurczewski2015-04-16
Signed-off-by: wm4 <wm4@nowhere>