layers: Protect format table from autoformatting
Change-Id: I0dbb2ab1c8f8179fe3d1fe575258051e56104f7d
diff --git a/layers/vk_layer_utils.cpp b/layers/vk_layer_utils.cpp
index 8d912d7..c82d204 100644
--- a/layers/vk_layer_utils.cpp
+++ b/layers/vk_layer_utils.cpp
@@ -32,6 +32,9 @@
VkFormatCompatibilityClass format_class;
};
+// Disable auto-formatting for this large table
+// clang-format off
+
// Set up data structure with number of bytes and number of channels for each Vulkan format
const std::map<VkFormat, VULKAN_FORMAT_INFO> vk_format_table = {
{VK_FORMAT_UNDEFINED, {0, 0, VK_FORMAT_COMPATIBILITY_CLASS_NONE_BIT }},
@@ -229,6 +232,9 @@
{VK_FORMAT_PVRTC2_4BPP_SRGB_BLOCK_IMG, {8, 4, VK_FORMAT_COMPATIBILITY_CLASS_ASTC_12X10_BIT}},
};
+// Renable formatting
+// clang-format on
+
// Return true if format is a depth or stencil format
VK_LAYER_EXPORT bool vk_format_is_depth_or_stencil(VkFormat format) {
return (vk_format_is_depth_and_stencil(format) || vk_format_is_depth_only(format) || vk_format_is_stencil_only(format));