From 98183b83386f7b6aeab80c312d4989793001d747 Mon Sep 17 00:00:00 2001 From: Tobin Ehlis Date: Thu, 11 May 2017 08:52:51 -0600 Subject: layers: Validate shared presentable image cases Add validation support for shared presentable images as defined in VK_KHR_shared_presentable_image extension. For all uses of shared presentable images, make sure that the image is appropriately in VK_IMAGE_LAYOUT_PRESENT_SRC_KHR layout. For two cases where no layout validation was performed, added a TODO note (vkCmdBlitImage, vkCmdResolveImage) as basic layout validation should first be added upstream. Also locked the layout in the case where a front-buffered image is presented and then flag an error if an attempt is made to transition the image layout after that point. Change-Id: I06cda727e3a7f56ccff4bffd7503b5ff73e8a795 --- layers/core_validation.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'layers/core_validation.cpp') diff --git a/layers/core_validation.cpp b/layers/core_validation.cpp index 16f7172d..371aca7a 100644 --- a/layers/core_validation.cpp +++ b/layers/core_validation.cpp @@ -10297,7 +10297,7 @@ static bool PreCallValidateCreateSwapchainKHR(layer_data *dev_data, const char * VK_PRESENT_MODE_SHARED_CONTINUOUS_REFRESH_KHR == pCreateInfo->presentMode) { if (!dev_data->device_extensions.khr_shared_presentable_image) { if (log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_DEVICE_EXT, - reinterpret_cast(dev_data->device), __LINE__, DRAWSTATE_EXTENSION_NOT_ENABLED, "DS", + HandleToUint64(dev_data->device), __LINE__, DRAWSTATE_EXTENSION_NOT_ENABLED, "DS", "%s called with presentMode %s which requires the VK_KHR_shared_presentable_image extension, which has not " "been enabled.", func_name, string_VkPresentModeKHR(pCreateInfo->presentMode))) -- cgit v1.2.3