summaryrefslogtreecommitdiffstats
path: root/src/vulkan/wsi/wsi_common.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/vulkan/wsi/wsi_common.h')
-rw-r--r--src/vulkan/wsi/wsi_common.h23
1 files changed, 23 insertions, 0 deletions
diff --git a/src/vulkan/wsi/wsi_common.h b/src/vulkan/wsi/wsi_common.h
index 3e0d3be1c24..6cf729ba025 100644
--- a/src/vulkan/wsi/wsi_common.h
+++ b/src/vulkan/wsi/wsi_common.h
@@ -35,11 +35,15 @@
*/
#define VK_STRUCTURE_TYPE_WSI_IMAGE_CREATE_INFO_MESA (VkStructureType)1000001002
#define VK_STRUCTURE_TYPE_WSI_MEMORY_ALLOCATE_INFO_MESA (VkStructureType)1000001003
+#define VK_STRUCTURE_TYPE_WSI_FORMAT_MODIFIER_PROPERTIES_LIST_MESA (VkStructureType)1000001004
struct wsi_image_create_info {
VkStructureType sType;
const void *pNext;
bool scanout;
+
+ uint32_t modifier_count;
+ const uint64_t *modifiers;
};
struct wsi_memory_allocate_info {
@@ -48,14 +52,32 @@ struct wsi_memory_allocate_info {
bool implicit_sync;
};
+struct wsi_format_modifier_properties {
+ uint64_t modifier;
+ uint32_t modifier_plane_count;
+};
+
+/* Chain in for vkGetPhysicalDeviceFormatProperties2KHR */
+struct wsi_format_modifier_properties_list {
+ VkStructureType sType;
+ const void *pNext;
+
+ uint32_t modifier_count;
+ struct wsi_format_modifier_properties *modifier_properties;
+};
+
struct wsi_interface;
#define VK_ICD_WSI_PLATFORM_MAX 5
struct wsi_device {
+ VkPhysicalDevice pdevice;
VkPhysicalDeviceMemoryProperties memory_props;
uint32_t queue_family_count;
+ bool supports_modifiers;
+ uint64_t (*image_get_modifier)(VkImage image);
+
#define WSI_CB(cb) PFN_vk##cb cb
WSI_CB(AllocateMemory);
WSI_CB(AllocateCommandBuffers);
@@ -79,6 +101,7 @@ struct wsi_device {
WSI_CB(GetImageSubresourceLayout);
WSI_CB(GetMemoryFdKHR);
WSI_CB(GetPhysicalDeviceFormatProperties);
+ WSI_CB(GetPhysicalDeviceFormatProperties2KHR);
WSI_CB(ResetFences);
WSI_CB(QueueSubmit);
WSI_CB(WaitForFences);