summaryrefslogtreecommitdiffstats
path: root/wscript_build.py
diff options
context:
space:
mode:
authorPhilip Langdale <philipl@overt.org>2019-12-02 10:37:40 +0800
committerPhilip Langdale <github.philipl@overt.org>2021-06-11 09:54:16 -0700
commitdbbf4a415de7866c6fe2dce10142d8a185eb0660 (patch)
tree7d98e0dc93f36bf8c80363831bb0430a571d5671 /wscript_build.py
parentdbf0fd7d60fa7b4996a3dd96101abd627768e9df (diff)
downloadmpv-dbbf4a415de7866c6fe2dce10142d8a185eb0660.tar.bz2
mpv-dbbf4a415de7866c6fe2dce10142d8a185eb0660.tar.xz
vo_gpu: vulkan: implement a VkDisplayKHR backed context
This is the Vulkan equivalent of the drm context for OpenGL, with the big difference that it's implemented purely in terms of Vulkan calls and doesn't actually require drm or kms. The basic idea is to identify a display, mode, and plane on a device, and then create a display backed surface for the swapchain. In theory, past that point, everything is the same, and this is in fact the case on Intel hardware. I can get a video playing on a vt. On nvidia, naturally, things don't work that way. Instead, nvidia only implemented the extension for scenarios where a VR application is stealing a display from a running window system, and not for standalone scenarios. With additional code, I've got this scenario to work but that's a separate incremental change. Other people have tested on AMD, and report roughly the same behaviour as on Intel. Note, that in this change, the VT will not be correctly restored after qutting. The only way to restore the VT is to introduce some drm specific code which I will illustrate in a separate change.
Diffstat (limited to 'wscript_build.py')
-rw-r--r--wscript_build.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/wscript_build.py b/wscript_build.py
index a12cbf19e1..fbec5006f8 100644
--- a/wscript_build.py
+++ b/wscript_build.py
@@ -506,6 +506,7 @@ def build(ctx):
( "video/out/vo_x11.c" , "x11" ),
( "video/out/vo_xv.c", "xv" ),
( "video/out/vulkan/context.c", "vulkan" ),
+ ( "video/out/vulkan/context_display.c", "vulkan" ),
( "video/out/vulkan/context_android.c", "vulkan && android" ),
( "video/out/vulkan/context_wayland.c", "vulkan && wayland" ),
( "video/out/vulkan/context_win.c", "vulkan && win32-desktop" ),