From ecca0899be558bc29947d89077f380905f70300a Mon Sep 17 00:00:00 2001 From: Tobin Ehlis Date: Tue, 3 Jan 2017 11:23:30 -0700 Subject: layers:Remove redundant image compatibility check The format compatibility check when creating an image view handles case of color-color check as well as compressed image compatibility check. Killing the redundant check and comment as this is all handled above. --- layers/core_validation.cpp | 12 ------------ 1 file changed, 12 deletions(-) (limited to 'layers/core_validation.cpp') diff --git a/layers/core_validation.cpp b/layers/core_validation.cpp index f3ed5370..c3edf928 100644 --- a/layers/core_validation.cpp +++ b/layers/core_validation.cpp @@ -6637,18 +6637,6 @@ static bool PreCallValidateCreateImageView(layer_data *dev_data, const VkImageVi // Validate correct image aspect bits for desired formats and format consistency skip |= ValidateImageAspectMask(dev_data, image_state->image, image_format, aspect_mask, "vkCreateImageView()"); - if (vk_format_is_color(image_format) && !vk_format_is_color(view_format)) { - std::stringstream ss; - ss << "vkCreateImageView: The image view's format can differ from the parent image's format, but both must be " - << "color formats. ImageFormat is " << string_VkFormat(image_format) << " ImageViewFormat is " - << string_VkFormat(view_format); - skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_IMAGE_EXT, - (uint64_t)create_info->image, __LINE__, VALIDATION_ERROR_02171, "IMAGE", "%s %s", ss.str().c_str(), - validation_error_map[VALIDATION_ERROR_02171]); - // TODO: Uncompressed formats are compatible if they occupy they same number of bits per pixel. - // Compressed formats are compatible if the only difference between them is the numerical type of - // the uncompressed pixels (e.g. signed vs. unsigned, or sRGB vs. UNORM encoding). - } } return skip; } -- cgit v1.2.3