Mirror of Vulkan-Utility-Libraries
Find a file
Charles Giessen 0d5b49b80f formats: vkuGetFormatInfo to use array
Puts the contents of a switch in a big array, then rewrites
vkuGetFormatInfo() to index into it based on the formats enum value.

This was done because the switch statement was large enough that
compilers wouldn't inline the function, leading to performance bubbles.

The logic for generating the logic of vkuGetFormatInfo is complex but
boils down to finding the groups of consecutive VkFormats, where the
end of a group has a value that is more than 1 away from the next format
value.

To follow C const initializer rules, VKU_FORMAT_COMPRESSED_COMPONENT
had to be turned into a macro.
2025-03-26 08:00:39 -06:00
.github build(deps): Bump jidicula/clang-format-action from 4.14.0 to 4.15.0 2025-03-24 22:20:55 -06:00
.reuse Add REUSE to CI 2023-07-25 16:11:18 -06:00
docs Minor improvements to VK_EXT_layer_settings documentation 2023-12-07 15:39:18 -07:00
include formats: vkuGetFormatInfo to use array 2025-03-26 08:00:39 -06:00
LICENSES Add REUSE to CI 2023-07-25 16:11:18 -06:00
scripts formats: vkuGetFormatInfo to use array 2025-03-26 08:00:39 -06:00
src build: Update to header 1.4.311 2025-03-21 08:52:30 -07:00
tests format: Fix DepthStencil to Color compatible check 2025-03-05 23:36:42 -05:00
.clang-format Add REUSE to CI 2023-07-25 16:11:18 -06:00
.gitattributes git: Add .gitattributes 2023-09-19 12:23:37 -06:00
.gitignore Update .gitignore 2024-06-27 11:01:38 -05:00
BUILD.gn Move vk_safe_struct to VUL 2024-03-28 11:11:35 -06:00
BUILD.md build: Update to header 1.4.309 2025-02-21 10:13:51 -08:00
CMakeLists.txt build: Add VUL_ENABLE_INSTALL option 2025-02-25 09:52:34 -06:00
CODE_OF_CONDUCT.md Add REUSE to CI 2023-07-25 16:11:18 -06:00
LICENSE.md Add REUSE to CI 2023-07-25 16:11:18 -06:00
README.md doc: Update README.md with project description 2023-09-20 13:25:56 -06:00

Vulkan-Utility-Libraries

This repo was created to share code across various Vulkan repositories, solving long standing issues for Vulkan SDK developers and users.

Historical Context

The Vulkan-ValidationLayers contained many libraries and utilities that were useful for other Vulkan repositories, and became the primary mechanism for code sharing in the Vulkan ecosystem.

This caused the Vulkan-ValidationLayers to have to maintain and export source code which was never intended for that purpose. This not only hindered development of the Vulkan-ValidationLayers, but would frequently break anyone depending on the source code due to the poorly located nature of it. On top of numerous other issues.

This repository was created to facilitate official source deliverables that can be reliably used by developers.

Vulkan::LayerSettings

The Vulkan::LayerSettings library was created to standardize layer configuration code for various SDK layer deliverables.

This is to ensure they all worked consistently with the 3 main methods of layer configuration.

For more information see layer_configuration.md.

Vulkan::UtilityHeaders

The Vulkan::UtilityHeaders library contains header only files that provide useful functionality to developers:

  • vk_dispatch_table.h: Initializing instance/device dispatch tables
  • vk_format_utils.h: Utilities for VkFormat
  • vk_struct_helper.hpp: Utilities for vulkan structs
  • vk_enum_string_helper.h: Converts Vulkan enums into strings