blob: 076b2112d9e26ce677c9c84e0372bc6c4572059c (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
#ifndef RENDER_SURFACE_H
#define RENDER_SURFACE_H
// NOTE: what a platform layer hands the renderer to make a VkSurfaceKHR from. its own header so
// platform/ and render/ can both see it without including each other.
typedef enum VulkanSurfaceKind {
VK_SURFACE_SOURCE_WAYLAND, // a = wl_display, b = wl_surface
VK_SURFACE_SOURCE_XLIB, // a = Display, b = Window (as a pointer sized integer)
VK_SURFACE_SOURCE_WIN32, // a = HINSTANCE, b = HWND
VK_SURFACE_SOURCE_METAL, // a = CAMetalLayer
} VulkanSurfaceKind;
typedef struct VulkanSurfaceSource VulkanSurfaceSource;
struct VulkanSurfaceSource {
u32 kind;
void *a;
void *b;
};
#endif // RENDER_SURFACE_H
|