wsi/common: Track VkColorSpaceKHR with wsi swapchain

Signed-off-by: Joshua Ashton <joshua@froggi.es>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35461>
This commit is contained in:
Joshua Ashton
2022-11-14 23:35:35 +00:00
committed by Marge Bot
parent 52cdbd78ec
commit b465d144ca
2 changed files with 5 additions and 0 deletions
+4
View File
@@ -403,6 +403,8 @@ configure_image(const struct wsi_swapchain *chain,
struct wsi_image_info *info)
{
info->image_type = params->image_type;
info->color_space = pCreateInfo->imageColorSpace;
switch (params->image_type) {
case WSI_IMAGE_TYPE_CPU: {
const struct wsi_cpu_image_params *cpu_params =
@@ -643,6 +645,8 @@ wsi_configure_image(const struct wsi_swapchain *chain,
.initialLayout = VK_IMAGE_LAYOUT_UNDEFINED,
};
info->color_space = pCreateInfo->imageColorSpace;
if (handle_types != 0) {
info->ext_mem = (VkExternalMemoryImageCreateInfo) {
.sType = VK_STRUCTURE_TYPE_EXTERNAL_MEMORY_IMAGE_CREATE_INFO,
+1
View File
@@ -85,6 +85,7 @@ struct wsi_image_info {
VkExternalMemoryImageCreateInfo ext_mem;
VkImageFormatListCreateInfo format_list;
VkImageDrmFormatModifierListCreateInfoEXT drm_mod_list;
VkColorSpaceKHR color_space;
enum wsi_image_type image_type;
bool explicit_sync;