Skip to content

Commit

Permalink
build: Update to header 1.2.176
Browse files Browse the repository at this point in the history
- Update known-good
- Generate source
- Fix version parsing in FindVulkanHeaders.cmake
- Add to VK_ENABLE_BETA_EXTENSIONS to GN build to pick up beta
  VkObjectType values

Change-Id: Ied4e4e71017e48d344b1c9cacf037ae989aceec9
  • Loading branch information
mikes-lunarg committed Apr 20, 2021
1 parent 4b868e5 commit eb6d6f9
Show file tree
Hide file tree
Showing 8 changed files with 718 additions and 17 deletions.
5 changes: 4 additions & 1 deletion BUILD.gn
Expand Up @@ -32,7 +32,10 @@ if (is_win) {
}

config("vulkan_internal_config") {
defines = [ "VULKAN_NON_CMAKE_BUILD" ]
defines = [
"VULKAN_NON_CMAKE_BUILD",
"VK_ENABLE_BETA_EXTENSIONS",
]
if (is_clang || !is_win) {
cflags = [
"-Wno-conversion",
Expand Down
10 changes: 5 additions & 5 deletions cmake/FindVulkanHeaders.cmake
Expand Up @@ -114,19 +114,19 @@ endif()
file(STRINGS
${VulkanHeaders_main_header}
VulkanHeaders_lines
REGEX "^#define (VK_API_VERSION.*VK_MAKE_VERSION|VK_HEADER_VERSION)")
REGEX "^#define VK_HEADER_VERSION(_COMPLETE)? ")

foreach(VulkanHeaders_line ${VulkanHeaders_lines})

# First, handle the case where we have a major/minor version
# Format is:
# #define VK_API_VERSION_X_Y VK_MAKE_VERSION(X, Y, 0)
# #define VK_HEADER_VERSION_COMPLETE VK_MAKE_API_VERSION(0, X, Y, VK_HEADER_VERSION)
# We grab the major version (X) and minor version (Y) out of the parentheses
string(REGEX MATCH "VK_MAKE_VERSION\\(.*\\)" VulkanHeaders_out ${VulkanHeaders_line})
string(REGEX MATCH "VK_HEADER_VERSION_COMPLETE VK_MAKE_API_VERSION\\(.*\\)" VulkanHeaders_out ${VulkanHeaders_line})
string(REGEX MATCHALL "[0-9]+" VulkanHeaders_MAJOR_MINOR "${VulkanHeaders_out}")
if (VulkanHeaders_MAJOR_MINOR)
list (GET VulkanHeaders_MAJOR_MINOR 0 VulkanHeaders_cur_major)
list (GET VulkanHeaders_MAJOR_MINOR 1 VulkanHeaders_cur_minor)
list (GET VulkanHeaders_MAJOR_MINOR 1 VulkanHeaders_cur_major)
list (GET VulkanHeaders_MAJOR_MINOR 2 VulkanHeaders_cur_minor)
if (${VulkanHeaders_cur_major} GREATER ${VulkanHeaders_VERSION_MAJOR})
set(VulkanHeaders_VERSION_MAJOR ${VulkanHeaders_cur_major})
set(VulkanHeaders_VERSION_MINOR ${VulkanHeaders_cur_minor})
Expand Down
111 changes: 111 additions & 0 deletions loader/generated/vk_dispatch_table_helper.h

Large diffs are not rendered by default.

63 changes: 63 additions & 0 deletions loader/generated/vk_layer_dispatch_table.h
Expand Up @@ -119,6 +119,14 @@ typedef struct VkLayerInstanceDispatchTable_ {
PFN_vkGetPhysicalDeviceWin32PresentationSupportKHR GetPhysicalDeviceWin32PresentationSupportKHR;
#endif // VK_USE_PLATFORM_WIN32_KHR

// ---- VK_KHR_video_queue extension commands
#ifdef VK_ENABLE_BETA_EXTENSIONS
PFN_vkGetPhysicalDeviceVideoCapabilitiesKHR GetPhysicalDeviceVideoCapabilitiesKHR;
#endif // VK_ENABLE_BETA_EXTENSIONS
#ifdef VK_ENABLE_BETA_EXTENSIONS
PFN_vkGetPhysicalDeviceVideoFormatPropertiesKHR GetPhysicalDeviceVideoFormatPropertiesKHR;
#endif // VK_ENABLE_BETA_EXTENSIONS

// ---- VK_KHR_get_physical_device_properties2 extension commands
PFN_vkGetPhysicalDeviceFeatures2KHR GetPhysicalDeviceFeatures2KHR;
PFN_vkGetPhysicalDeviceProperties2KHR GetPhysicalDeviceProperties2KHR;
Expand Down Expand Up @@ -434,6 +442,43 @@ typedef struct VkLayerDispatchTable_ {
// ---- VK_KHR_display_swapchain extension commands
PFN_vkCreateSharedSwapchainsKHR CreateSharedSwapchainsKHR;

// ---- VK_KHR_video_queue extension commands
#ifdef VK_ENABLE_BETA_EXTENSIONS
PFN_vkCreateVideoSessionKHR CreateVideoSessionKHR;
#endif // VK_ENABLE_BETA_EXTENSIONS
#ifdef VK_ENABLE_BETA_EXTENSIONS
PFN_vkDestroyVideoSessionKHR DestroyVideoSessionKHR;
#endif // VK_ENABLE_BETA_EXTENSIONS
#ifdef VK_ENABLE_BETA_EXTENSIONS
PFN_vkGetVideoSessionMemoryRequirementsKHR GetVideoSessionMemoryRequirementsKHR;
#endif // VK_ENABLE_BETA_EXTENSIONS
#ifdef VK_ENABLE_BETA_EXTENSIONS
PFN_vkBindVideoSessionMemoryKHR BindVideoSessionMemoryKHR;
#endif // VK_ENABLE_BETA_EXTENSIONS
#ifdef VK_ENABLE_BETA_EXTENSIONS
PFN_vkCreateVideoSessionParametersKHR CreateVideoSessionParametersKHR;
#endif // VK_ENABLE_BETA_EXTENSIONS
#ifdef VK_ENABLE_BETA_EXTENSIONS
PFN_vkUpdateVideoSessionParametersKHR UpdateVideoSessionParametersKHR;
#endif // VK_ENABLE_BETA_EXTENSIONS
#ifdef VK_ENABLE_BETA_EXTENSIONS
PFN_vkDestroyVideoSessionParametersKHR DestroyVideoSessionParametersKHR;
#endif // VK_ENABLE_BETA_EXTENSIONS
#ifdef VK_ENABLE_BETA_EXTENSIONS
PFN_vkCmdBeginVideoCodingKHR CmdBeginVideoCodingKHR;
#endif // VK_ENABLE_BETA_EXTENSIONS
#ifdef VK_ENABLE_BETA_EXTENSIONS
PFN_vkCmdEndVideoCodingKHR CmdEndVideoCodingKHR;
#endif // VK_ENABLE_BETA_EXTENSIONS
#ifdef VK_ENABLE_BETA_EXTENSIONS
PFN_vkCmdControlVideoCodingKHR CmdControlVideoCodingKHR;
#endif // VK_ENABLE_BETA_EXTENSIONS

// ---- VK_KHR_video_decode_queue extension commands
#ifdef VK_ENABLE_BETA_EXTENSIONS
PFN_vkCmdDecodeVideoKHR CmdDecodeVideoKHR;
#endif // VK_ENABLE_BETA_EXTENSIONS

// ---- VK_KHR_device_group extension commands
PFN_vkGetDeviceGroupPeerMemoryFeaturesKHR GetDeviceGroupPeerMemoryFeaturesKHR;
PFN_vkCmdSetDeviceMaskKHR CmdSetDeviceMaskKHR;
Expand Down Expand Up @@ -545,6 +590,11 @@ typedef struct VkLayerDispatchTable_ {
PFN_vkGetPipelineExecutableStatisticsKHR GetPipelineExecutableStatisticsKHR;
PFN_vkGetPipelineExecutableInternalRepresentationsKHR GetPipelineExecutableInternalRepresentationsKHR;

// ---- VK_KHR_video_encode_queue extension commands
#ifdef VK_ENABLE_BETA_EXTENSIONS
PFN_vkCmdEncodeVideoKHR CmdEncodeVideoKHR;
#endif // VK_ENABLE_BETA_EXTENSIONS

// ---- VK_KHR_synchronization2 extension commands
PFN_vkCmdSetEvent2KHR CmdSetEvent2KHR;
PFN_vkCmdResetEvent2KHR CmdResetEvent2KHR;
Expand Down Expand Up @@ -753,6 +803,9 @@ typedef struct VkLayerDispatchTable_ {
// ---- VK_NV_fragment_shading_rate_enums extension commands
PFN_vkCmdSetFragmentShadingRateEnumNV CmdSetFragmentShadingRateEnumNV;

// ---- VK_EXT_vertex_input_dynamic_state extension commands
PFN_vkCmdSetVertexInputEXT CmdSetVertexInputEXT;

// ---- VK_FUCHSIA_external_memory extension commands
#ifdef VK_USE_PLATFORM_FUCHSIA
PFN_vkGetMemoryZirconHandleFUCHSIA GetMemoryZirconHandleFUCHSIA;
Expand All @@ -769,6 +822,16 @@ typedef struct VkLayerDispatchTable_ {
PFN_vkGetSemaphoreZirconHandleFUCHSIA GetSemaphoreZirconHandleFUCHSIA;
#endif // VK_USE_PLATFORM_FUCHSIA

// ---- VK_EXT_extended_dynamic_state2 extension commands
PFN_vkCmdSetPatchControlPointsEXT CmdSetPatchControlPointsEXT;
PFN_vkCmdSetRasterizerDiscardEnableEXT CmdSetRasterizerDiscardEnableEXT;
PFN_vkCmdSetDepthBiasEnableEXT CmdSetDepthBiasEnableEXT;
PFN_vkCmdSetLogicOpEXT CmdSetLogicOpEXT;
PFN_vkCmdSetPrimitiveRestartEnableEXT CmdSetPrimitiveRestartEnableEXT;

// ---- VK_EXT_color_write_enable extension commands
PFN_vkCmdSetColorWriteEnableEXT CmdSetColorWriteEnableEXT;

// ---- VK_KHR_acceleration_structure extension commands
PFN_vkCreateAccelerationStructureKHR CreateAccelerationStructureKHR;
PFN_vkDestroyAccelerationStructureKHR DestroyAccelerationStructureKHR;
Expand Down

0 comments on commit eb6d6f9

Please sign in to comment.