Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1356b0d3 authored by Jesse Hall's avatar Jesse Hall
Browse files

vulkan: Implement VkSurfaceKHR and use vulkanext.h

Between header version 0.183.0 and 0.184.0, a copy of vulkan.h which
includes extensions was added to the registry, called vulkanext.h. The
vulkan.h included here is actually the registry's vulkanext.h.
(In a later upstream change, the no-extensions version was removed
from the registry, and vulkanext.h was renamed vulkan.h, matching what
we're doing here.)

The version of the extensions picked up in the header file is later
than the ones used in the previous SDK, so this change also updates
our implementation to the extension versions included in the header.
The main change is replacing the VkSurfaceDescriptionKHR structure
with a VkSurfaceKHR object.

Change-Id: I18fa5a269db0fcdbdbde3e9304167bc15e456f85
(cherry picked from commit 957a59a48a8d2e81ca3bb52aacd8d08b1b43dc74)
parent fbf97b0e
Loading
Loading
Loading
Loading
+23 −0
Original line number Diff line number Diff line
@@ -22,3 +22,26 @@
// Platform types, as defined or included in vk_platform.h

type u64 size_t

// VK_USE_PLATFORM_X11_KHR
@internal class Display {}
@internal class Window {}

// VK_USE_PLATFORM_XCB_KHR
@internal class xcb_connection_t {}
@internal type u32 xcb_window_t

// VK_USE_PLATFORM_WAYLAND_KHR
@internal class wl_display {}
@internal class wl_surface {}

// VK_USE_PLATFORM_MIR_KHR
@internal class MirConnection {}
@internal class MirSurface {}

// VK_USE_PLATFORM_ANDROID_KHR
@internal class ANativeWindow {}

// VK_USE_PLATFORM_WIN32_KHR
@internal type void* HINSTANCE
@internal type void* HWND
+354 −115

File changed.

Preview size limit exceeded, changes collapsed.

+0 −210

File deleted.

Preview size limit exceeded, changes collapsed.

+0 −153

File deleted.

Preview size limit exceeded, changes collapsed.

+28 −0
Original line number Diff line number Diff line
@@ -71,4 +71,32 @@ extern "C"
} // extern "C"
#endif // __cplusplus

// Platform-specific headers required by platform window system extensions.
// These are enabled prior to #including "vulkan.h". The same enable then
// controls inclusion of the extension interfaces in vulkan.h.

#ifdef VK_USE_PLATFORM_ANDROID_KHR
#include <android/native_window.h>
#endif

#ifdef VK_USE_PLATFORM_MIR_KHR
#include <mir_toolkit/client_types.h>
#endif

#ifdef VK_USE_PLATFORM_WAYLAND_KHR
#include <wayland-client.h>
#endif

#ifdef VK_USE_PLATFORM_WIN32_KHR
#include <windows.h>
#endif

#ifdef VK_USE_PLATFORM_X11_KHR
#include <X11/Xlib.h>
#endif

#ifdef VK_USE_PLATFORM_XCB_KHR
#include <xcb/xcb.h>
#endif

#endif // __VK_PLATFORM_H__
Loading