layers: GL168, fix bad compressed texel block size
The image<->buffer copy validation was checking against texel block
sizes, but needed the block size in byte. Fixed the bad validation
errors and renamed existing util function and updated a compressed
texture size to match the spec.
Change-Id: I40b9635a4fab131ab1525da51e94c4c5577217be
diff --git a/layers/vk_layer_utils.cpp b/layers/vk_layer_utils.cpp
index 18a42b9..cd23563 100644
--- a/layers/vk_layer_utils.cpp
+++ b/layers/vk_layer_utils.cpp
@@ -189,7 +189,7 @@
{VK_FORMAT_ETC2_R8G8B8A1_UNORM_BLOCK, {8, 4, VK_FORMAT_COMPATIBILITY_CLASS_ETC2_RGBA_BIT}},
{VK_FORMAT_ETC2_R8G8B8A1_SRGB_BLOCK, {8, 4, VK_FORMAT_COMPATIBILITY_CLASS_ETC2_RGBA_BIT}},
{VK_FORMAT_ETC2_R8G8B8A8_UNORM_BLOCK, {16, 4, VK_FORMAT_COMPATIBILITY_CLASS_ETC2_EAC_RGBA_BIT}},
- {VK_FORMAT_ETC2_R8G8B8A8_SRGB_BLOCK, {16, 4, VK_FORMAT_COMPATIBILITY_CLASS_ETC2_EAC_RGBA_BIT}},
+ {VK_FORMAT_ETC2_R8G8B8A8_SRGB_BLOCK, {8, 4, VK_FORMAT_COMPATIBILITY_CLASS_ETC2_EAC_RGBA_BIT}},
{VK_FORMAT_EAC_R11_UNORM_BLOCK, {8, 1, VK_FORMAT_COMPATIBILITY_CLASS_EAC_R_BIT}},
{VK_FORMAT_EAC_R11_SNORM_BLOCK, {8, 1, VK_FORMAT_COMPATIBILITY_CLASS_EAC_R_BIT}},
{VK_FORMAT_EAC_R11G11_UNORM_BLOCK, {16, 2, VK_FORMAT_COMPATIBILITY_CLASS_EAC_RG_BIT}},
@@ -559,8 +559,8 @@
}
}
-// Return compressed block sizes for block compressed formats
-VK_LAYER_EXPORT VkExtent2D vk_format_compressed_block_size(VkFormat format) {
+// Return compressed texel block sizes for block compressed formats
+VK_LAYER_EXPORT VkExtent2D vk_format_compressed_texel_block_extents(VkFormat format) {
VkExtent2D block_size = {1, 1};
switch (format) {
case VK_FORMAT_BC1_RGB_UNORM_BLOCK: