mirror of
https://github.com/KhronosGroup/Vulkan-Utility-Libraries.git
synced 2025-05-16 17:58:41 +00:00
scripts: Add initial codegen scripts
This commit is contained in:
parent
471366378c
commit
d8719df037
10 changed files with 13528 additions and 0 deletions
26
docs/generated_code.md
Normal file
26
docs/generated_code.md
Normal file
|
@ -0,0 +1,26 @@
|
|||
# How to generate the code
|
||||
|
||||
- Linux:
|
||||
```bash
|
||||
scripts/generate_source.py external/Vulkan-Headers/registry/
|
||||
```
|
||||
|
||||
- Windows Powershell:
|
||||
```powershell
|
||||
pwsh -Command { python3 scripts/generate_source.py external/Vulkan-Headers/registry/ }
|
||||
```
|
||||
|
||||
- Windows Command:
|
||||
```cmd
|
||||
cmd /C "python3 scripts/generate_source.py external/Vulkan-Headers/registry/"
|
||||
```
|
||||
|
||||
If only dealing with a single file, run `scripts/generate_source.py` with `--target`
|
||||
|
||||
```bash
|
||||
# Example - only generates chassis.h
|
||||
scripts/generate_source.py external/Vulkan-Headers/registry/ --target vk_layer_dispatch_table.h
|
||||
```
|
||||
|
||||
When making change to the `scripts/` folder, make sure to run `generate_source.py`
|
||||
(Code generation does **not** happen automatically at build time.)
|
2326
include/vulkan/vk_dispatch_table_helper.h
Normal file
2326
include/vulkan/vk_dispatch_table_helper.h
Normal file
File diff suppressed because it is too large
Load diff
8843
include/vulkan/vk_enum_string_helper.h
Normal file
8843
include/vulkan/vk_enum_string_helper.h
Normal file
File diff suppressed because it is too large
Load diff
776
include/vulkan/vk_layer_dispatch_table.h
Normal file
776
include/vulkan/vk_layer_dispatch_table.h
Normal file
|
@ -0,0 +1,776 @@
|
|||
// *** THIS FILE IS GENERATED - DO NOT EDIT ***
|
||||
// See layer_dispatch_table_generator.py for modifications
|
||||
/***************************************************************************
|
||||
*
|
||||
* Copyright (c) 2015-2023 The Khronos Group Inc.
|
||||
* Copyright (c) 2015-2023 Valve Corporation
|
||||
* Copyright (c) 2015-2023 LunarG, Inc.
|
||||
* Copyright (c) 2015-2023 Google Inc.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
****************************************************************************/
|
||||
// NOLINTBEGIN
|
||||
#pragma once
|
||||
|
||||
typedef PFN_vkVoidFunction (VKAPI_PTR *PFN_GetPhysicalDeviceProcAddr)(VkInstance instance, const char* pName);
|
||||
|
||||
// Instance function pointer dispatch table
|
||||
typedef struct VkLayerInstanceDispatchTable_ {
|
||||
PFN_GetPhysicalDeviceProcAddr GetPhysicalDeviceProcAddr;
|
||||
|
||||
PFN_vkCreateInstance CreateInstance;
|
||||
PFN_vkDestroyInstance DestroyInstance;
|
||||
PFN_vkEnumeratePhysicalDevices EnumeratePhysicalDevices;
|
||||
PFN_vkGetPhysicalDeviceFeatures GetPhysicalDeviceFeatures;
|
||||
PFN_vkGetPhysicalDeviceFormatProperties GetPhysicalDeviceFormatProperties;
|
||||
PFN_vkGetPhysicalDeviceImageFormatProperties GetPhysicalDeviceImageFormatProperties;
|
||||
PFN_vkGetPhysicalDeviceProperties GetPhysicalDeviceProperties;
|
||||
PFN_vkGetPhysicalDeviceQueueFamilyProperties GetPhysicalDeviceQueueFamilyProperties;
|
||||
PFN_vkGetPhysicalDeviceMemoryProperties GetPhysicalDeviceMemoryProperties;
|
||||
PFN_vkGetInstanceProcAddr GetInstanceProcAddr;
|
||||
PFN_vkCreateDevice CreateDevice;
|
||||
PFN_vkEnumerateInstanceExtensionProperties EnumerateInstanceExtensionProperties;
|
||||
PFN_vkEnumerateDeviceExtensionProperties EnumerateDeviceExtensionProperties;
|
||||
PFN_vkEnumerateInstanceLayerProperties EnumerateInstanceLayerProperties;
|
||||
PFN_vkEnumerateDeviceLayerProperties EnumerateDeviceLayerProperties;
|
||||
PFN_vkGetPhysicalDeviceSparseImageFormatProperties GetPhysicalDeviceSparseImageFormatProperties;
|
||||
PFN_vkEnumerateInstanceVersion EnumerateInstanceVersion;
|
||||
PFN_vkEnumeratePhysicalDeviceGroups EnumeratePhysicalDeviceGroups;
|
||||
PFN_vkGetPhysicalDeviceFeatures2 GetPhysicalDeviceFeatures2;
|
||||
PFN_vkGetPhysicalDeviceProperties2 GetPhysicalDeviceProperties2;
|
||||
PFN_vkGetPhysicalDeviceFormatProperties2 GetPhysicalDeviceFormatProperties2;
|
||||
PFN_vkGetPhysicalDeviceImageFormatProperties2 GetPhysicalDeviceImageFormatProperties2;
|
||||
PFN_vkGetPhysicalDeviceQueueFamilyProperties2 GetPhysicalDeviceQueueFamilyProperties2;
|
||||
PFN_vkGetPhysicalDeviceMemoryProperties2 GetPhysicalDeviceMemoryProperties2;
|
||||
PFN_vkGetPhysicalDeviceSparseImageFormatProperties2 GetPhysicalDeviceSparseImageFormatProperties2;
|
||||
PFN_vkGetPhysicalDeviceExternalBufferProperties GetPhysicalDeviceExternalBufferProperties;
|
||||
PFN_vkGetPhysicalDeviceExternalFenceProperties GetPhysicalDeviceExternalFenceProperties;
|
||||
PFN_vkGetPhysicalDeviceExternalSemaphoreProperties GetPhysicalDeviceExternalSemaphoreProperties;
|
||||
PFN_vkGetPhysicalDeviceToolProperties GetPhysicalDeviceToolProperties;
|
||||
PFN_vkDestroySurfaceKHR DestroySurfaceKHR;
|
||||
PFN_vkGetPhysicalDeviceSurfaceSupportKHR GetPhysicalDeviceSurfaceSupportKHR;
|
||||
PFN_vkGetPhysicalDeviceSurfaceCapabilitiesKHR GetPhysicalDeviceSurfaceCapabilitiesKHR;
|
||||
PFN_vkGetPhysicalDeviceSurfaceFormatsKHR GetPhysicalDeviceSurfaceFormatsKHR;
|
||||
PFN_vkGetPhysicalDeviceSurfacePresentModesKHR GetPhysicalDeviceSurfacePresentModesKHR;
|
||||
PFN_vkGetPhysicalDevicePresentRectanglesKHR GetPhysicalDevicePresentRectanglesKHR;
|
||||
PFN_vkGetPhysicalDeviceDisplayPropertiesKHR GetPhysicalDeviceDisplayPropertiesKHR;
|
||||
PFN_vkGetPhysicalDeviceDisplayPlanePropertiesKHR GetPhysicalDeviceDisplayPlanePropertiesKHR;
|
||||
PFN_vkGetDisplayPlaneSupportedDisplaysKHR GetDisplayPlaneSupportedDisplaysKHR;
|
||||
PFN_vkGetDisplayModePropertiesKHR GetDisplayModePropertiesKHR;
|
||||
PFN_vkCreateDisplayModeKHR CreateDisplayModeKHR;
|
||||
PFN_vkGetDisplayPlaneCapabilitiesKHR GetDisplayPlaneCapabilitiesKHR;
|
||||
PFN_vkCreateDisplayPlaneSurfaceKHR CreateDisplayPlaneSurfaceKHR;
|
||||
#ifdef VK_USE_PLATFORM_XLIB_KHR
|
||||
PFN_vkCreateXlibSurfaceKHR CreateXlibSurfaceKHR;
|
||||
#endif //VK_USE_PLATFORM_XLIB_KHR
|
||||
#ifdef VK_USE_PLATFORM_XLIB_KHR
|
||||
PFN_vkGetPhysicalDeviceXlibPresentationSupportKHR GetPhysicalDeviceXlibPresentationSupportKHR;
|
||||
#endif //VK_USE_PLATFORM_XLIB_KHR
|
||||
#ifdef VK_USE_PLATFORM_XCB_KHR
|
||||
PFN_vkCreateXcbSurfaceKHR CreateXcbSurfaceKHR;
|
||||
#endif //VK_USE_PLATFORM_XCB_KHR
|
||||
#ifdef VK_USE_PLATFORM_XCB_KHR
|
||||
PFN_vkGetPhysicalDeviceXcbPresentationSupportKHR GetPhysicalDeviceXcbPresentationSupportKHR;
|
||||
#endif //VK_USE_PLATFORM_XCB_KHR
|
||||
#ifdef VK_USE_PLATFORM_WAYLAND_KHR
|
||||
PFN_vkCreateWaylandSurfaceKHR CreateWaylandSurfaceKHR;
|
||||
#endif //VK_USE_PLATFORM_WAYLAND_KHR
|
||||
#ifdef VK_USE_PLATFORM_WAYLAND_KHR
|
||||
PFN_vkGetPhysicalDeviceWaylandPresentationSupportKHR GetPhysicalDeviceWaylandPresentationSupportKHR;
|
||||
#endif //VK_USE_PLATFORM_WAYLAND_KHR
|
||||
#ifdef VK_USE_PLATFORM_ANDROID_KHR
|
||||
PFN_vkCreateAndroidSurfaceKHR CreateAndroidSurfaceKHR;
|
||||
#endif //VK_USE_PLATFORM_ANDROID_KHR
|
||||
#ifdef VK_USE_PLATFORM_WIN32_KHR
|
||||
PFN_vkCreateWin32SurfaceKHR CreateWin32SurfaceKHR;
|
||||
#endif //VK_USE_PLATFORM_WIN32_KHR
|
||||
#ifdef VK_USE_PLATFORM_WIN32_KHR
|
||||
PFN_vkGetPhysicalDeviceWin32PresentationSupportKHR GetPhysicalDeviceWin32PresentationSupportKHR;
|
||||
#endif //VK_USE_PLATFORM_WIN32_KHR
|
||||
PFN_vkGetPhysicalDeviceVideoCapabilitiesKHR GetPhysicalDeviceVideoCapabilitiesKHR;
|
||||
PFN_vkGetPhysicalDeviceVideoFormatPropertiesKHR GetPhysicalDeviceVideoFormatPropertiesKHR;
|
||||
PFN_vkGetPhysicalDeviceFeatures2KHR GetPhysicalDeviceFeatures2KHR;
|
||||
PFN_vkGetPhysicalDeviceProperties2KHR GetPhysicalDeviceProperties2KHR;
|
||||
PFN_vkGetPhysicalDeviceFormatProperties2KHR GetPhysicalDeviceFormatProperties2KHR;
|
||||
PFN_vkGetPhysicalDeviceImageFormatProperties2KHR GetPhysicalDeviceImageFormatProperties2KHR;
|
||||
PFN_vkGetPhysicalDeviceQueueFamilyProperties2KHR GetPhysicalDeviceQueueFamilyProperties2KHR;
|
||||
PFN_vkGetPhysicalDeviceMemoryProperties2KHR GetPhysicalDeviceMemoryProperties2KHR;
|
||||
PFN_vkGetPhysicalDeviceSparseImageFormatProperties2KHR GetPhysicalDeviceSparseImageFormatProperties2KHR;
|
||||
PFN_vkEnumeratePhysicalDeviceGroupsKHR EnumeratePhysicalDeviceGroupsKHR;
|
||||
PFN_vkGetPhysicalDeviceExternalBufferPropertiesKHR GetPhysicalDeviceExternalBufferPropertiesKHR;
|
||||
PFN_vkGetPhysicalDeviceExternalSemaphorePropertiesKHR GetPhysicalDeviceExternalSemaphorePropertiesKHR;
|
||||
PFN_vkGetPhysicalDeviceExternalFencePropertiesKHR GetPhysicalDeviceExternalFencePropertiesKHR;
|
||||
PFN_vkEnumeratePhysicalDeviceQueueFamilyPerformanceQueryCountersKHR EnumeratePhysicalDeviceQueueFamilyPerformanceQueryCountersKHR;
|
||||
PFN_vkGetPhysicalDeviceQueueFamilyPerformanceQueryPassesKHR GetPhysicalDeviceQueueFamilyPerformanceQueryPassesKHR;
|
||||
PFN_vkGetPhysicalDeviceSurfaceCapabilities2KHR GetPhysicalDeviceSurfaceCapabilities2KHR;
|
||||
PFN_vkGetPhysicalDeviceSurfaceFormats2KHR GetPhysicalDeviceSurfaceFormats2KHR;
|
||||
PFN_vkGetPhysicalDeviceDisplayProperties2KHR GetPhysicalDeviceDisplayProperties2KHR;
|
||||
PFN_vkGetPhysicalDeviceDisplayPlaneProperties2KHR GetPhysicalDeviceDisplayPlaneProperties2KHR;
|
||||
PFN_vkGetDisplayModeProperties2KHR GetDisplayModeProperties2KHR;
|
||||
PFN_vkGetDisplayPlaneCapabilities2KHR GetDisplayPlaneCapabilities2KHR;
|
||||
PFN_vkGetPhysicalDeviceFragmentShadingRatesKHR GetPhysicalDeviceFragmentShadingRatesKHR;
|
||||
#ifdef VK_ENABLE_BETA_EXTENSIONS
|
||||
PFN_vkGetPhysicalDeviceVideoEncodeQualityLevelPropertiesKHR GetPhysicalDeviceVideoEncodeQualityLevelPropertiesKHR;
|
||||
#endif //VK_ENABLE_BETA_EXTENSIONS
|
||||
PFN_vkGetPhysicalDeviceCooperativeMatrixPropertiesKHR GetPhysicalDeviceCooperativeMatrixPropertiesKHR;
|
||||
PFN_vkCreateDebugReportCallbackEXT CreateDebugReportCallbackEXT;
|
||||
PFN_vkDestroyDebugReportCallbackEXT DestroyDebugReportCallbackEXT;
|
||||
PFN_vkDebugReportMessageEXT DebugReportMessageEXT;
|
||||
#ifdef VK_USE_PLATFORM_GGP
|
||||
PFN_vkCreateStreamDescriptorSurfaceGGP CreateStreamDescriptorSurfaceGGP;
|
||||
#endif //VK_USE_PLATFORM_GGP
|
||||
PFN_vkGetPhysicalDeviceExternalImageFormatPropertiesNV GetPhysicalDeviceExternalImageFormatPropertiesNV;
|
||||
#ifdef VK_USE_PLATFORM_VI_NN
|
||||
PFN_vkCreateViSurfaceNN CreateViSurfaceNN;
|
||||
#endif //VK_USE_PLATFORM_VI_NN
|
||||
PFN_vkReleaseDisplayEXT ReleaseDisplayEXT;
|
||||
#ifdef VK_USE_PLATFORM_XLIB_XRANDR_EXT
|
||||
PFN_vkAcquireXlibDisplayEXT AcquireXlibDisplayEXT;
|
||||
#endif //VK_USE_PLATFORM_XLIB_XRANDR_EXT
|
||||
#ifdef VK_USE_PLATFORM_XLIB_XRANDR_EXT
|
||||
PFN_vkGetRandROutputDisplayEXT GetRandROutputDisplayEXT;
|
||||
#endif //VK_USE_PLATFORM_XLIB_XRANDR_EXT
|
||||
PFN_vkGetPhysicalDeviceSurfaceCapabilities2EXT GetPhysicalDeviceSurfaceCapabilities2EXT;
|
||||
#ifdef VK_USE_PLATFORM_IOS_MVK
|
||||
PFN_vkCreateIOSSurfaceMVK CreateIOSSurfaceMVK;
|
||||
#endif //VK_USE_PLATFORM_IOS_MVK
|
||||
#ifdef VK_USE_PLATFORM_MACOS_MVK
|
||||
PFN_vkCreateMacOSSurfaceMVK CreateMacOSSurfaceMVK;
|
||||
#endif //VK_USE_PLATFORM_MACOS_MVK
|
||||
PFN_vkCreateDebugUtilsMessengerEXT CreateDebugUtilsMessengerEXT;
|
||||
PFN_vkDestroyDebugUtilsMessengerEXT DestroyDebugUtilsMessengerEXT;
|
||||
PFN_vkSubmitDebugUtilsMessageEXT SubmitDebugUtilsMessageEXT;
|
||||
PFN_vkGetPhysicalDeviceMultisamplePropertiesEXT GetPhysicalDeviceMultisamplePropertiesEXT;
|
||||
PFN_vkGetPhysicalDeviceCalibrateableTimeDomainsEXT GetPhysicalDeviceCalibrateableTimeDomainsEXT;
|
||||
#ifdef VK_USE_PLATFORM_FUCHSIA
|
||||
PFN_vkCreateImagePipeSurfaceFUCHSIA CreateImagePipeSurfaceFUCHSIA;
|
||||
#endif //VK_USE_PLATFORM_FUCHSIA
|
||||
#ifdef VK_USE_PLATFORM_METAL_EXT
|
||||
PFN_vkCreateMetalSurfaceEXT CreateMetalSurfaceEXT;
|
||||
#endif //VK_USE_PLATFORM_METAL_EXT
|
||||
PFN_vkGetPhysicalDeviceToolPropertiesEXT GetPhysicalDeviceToolPropertiesEXT;
|
||||
PFN_vkGetPhysicalDeviceCooperativeMatrixPropertiesNV GetPhysicalDeviceCooperativeMatrixPropertiesNV;
|
||||
PFN_vkGetPhysicalDeviceSupportedFramebufferMixedSamplesCombinationsNV GetPhysicalDeviceSupportedFramebufferMixedSamplesCombinationsNV;
|
||||
#ifdef VK_USE_PLATFORM_WIN32_KHR
|
||||
PFN_vkGetPhysicalDeviceSurfacePresentModes2EXT GetPhysicalDeviceSurfacePresentModes2EXT;
|
||||
#endif //VK_USE_PLATFORM_WIN32_KHR
|
||||
PFN_vkCreateHeadlessSurfaceEXT CreateHeadlessSurfaceEXT;
|
||||
PFN_vkAcquireDrmDisplayEXT AcquireDrmDisplayEXT;
|
||||
PFN_vkGetDrmDisplayEXT GetDrmDisplayEXT;
|
||||
#ifdef VK_USE_PLATFORM_WIN32_KHR
|
||||
PFN_vkAcquireWinrtDisplayNV AcquireWinrtDisplayNV;
|
||||
#endif //VK_USE_PLATFORM_WIN32_KHR
|
||||
#ifdef VK_USE_PLATFORM_WIN32_KHR
|
||||
PFN_vkGetWinrtDisplayNV GetWinrtDisplayNV;
|
||||
#endif //VK_USE_PLATFORM_WIN32_KHR
|
||||
#ifdef VK_USE_PLATFORM_DIRECTFB_EXT
|
||||
PFN_vkCreateDirectFBSurfaceEXT CreateDirectFBSurfaceEXT;
|
||||
#endif //VK_USE_PLATFORM_DIRECTFB_EXT
|
||||
#ifdef VK_USE_PLATFORM_DIRECTFB_EXT
|
||||
PFN_vkGetPhysicalDeviceDirectFBPresentationSupportEXT GetPhysicalDeviceDirectFBPresentationSupportEXT;
|
||||
#endif //VK_USE_PLATFORM_DIRECTFB_EXT
|
||||
#ifdef VK_USE_PLATFORM_SCREEN_QNX
|
||||
PFN_vkCreateScreenSurfaceQNX CreateScreenSurfaceQNX;
|
||||
#endif //VK_USE_PLATFORM_SCREEN_QNX
|
||||
#ifdef VK_USE_PLATFORM_SCREEN_QNX
|
||||
PFN_vkGetPhysicalDeviceScreenPresentationSupportQNX GetPhysicalDeviceScreenPresentationSupportQNX;
|
||||
#endif //VK_USE_PLATFORM_SCREEN_QNX
|
||||
PFN_vkGetPhysicalDeviceOpticalFlowImageFormatsNV GetPhysicalDeviceOpticalFlowImageFormatsNV;
|
||||
} VkLayerInstanceDispatchTable;
|
||||
|
||||
// Device function pointer dispatch table
|
||||
typedef struct VkLayerDispatchTable_ {
|
||||
PFN_vkGetDeviceProcAddr GetDeviceProcAddr;
|
||||
PFN_vkDestroyDevice DestroyDevice;
|
||||
PFN_vkGetDeviceQueue GetDeviceQueue;
|
||||
PFN_vkQueueSubmit QueueSubmit;
|
||||
PFN_vkQueueWaitIdle QueueWaitIdle;
|
||||
PFN_vkDeviceWaitIdle DeviceWaitIdle;
|
||||
PFN_vkAllocateMemory AllocateMemory;
|
||||
PFN_vkFreeMemory FreeMemory;
|
||||
PFN_vkMapMemory MapMemory;
|
||||
PFN_vkUnmapMemory UnmapMemory;
|
||||
PFN_vkFlushMappedMemoryRanges FlushMappedMemoryRanges;
|
||||
PFN_vkInvalidateMappedMemoryRanges InvalidateMappedMemoryRanges;
|
||||
PFN_vkGetDeviceMemoryCommitment GetDeviceMemoryCommitment;
|
||||
PFN_vkBindBufferMemory BindBufferMemory;
|
||||
PFN_vkBindImageMemory BindImageMemory;
|
||||
PFN_vkGetBufferMemoryRequirements GetBufferMemoryRequirements;
|
||||
PFN_vkGetImageMemoryRequirements GetImageMemoryRequirements;
|
||||
PFN_vkGetImageSparseMemoryRequirements GetImageSparseMemoryRequirements;
|
||||
PFN_vkQueueBindSparse QueueBindSparse;
|
||||
PFN_vkCreateFence CreateFence;
|
||||
PFN_vkDestroyFence DestroyFence;
|
||||
PFN_vkResetFences ResetFences;
|
||||
PFN_vkGetFenceStatus GetFenceStatus;
|
||||
PFN_vkWaitForFences WaitForFences;
|
||||
PFN_vkCreateSemaphore CreateSemaphore;
|
||||
PFN_vkDestroySemaphore DestroySemaphore;
|
||||
PFN_vkCreateEvent CreateEvent;
|
||||
PFN_vkDestroyEvent DestroyEvent;
|
||||
PFN_vkGetEventStatus GetEventStatus;
|
||||
PFN_vkSetEvent SetEvent;
|
||||
PFN_vkResetEvent ResetEvent;
|
||||
PFN_vkCreateQueryPool CreateQueryPool;
|
||||
PFN_vkDestroyQueryPool DestroyQueryPool;
|
||||
PFN_vkGetQueryPoolResults GetQueryPoolResults;
|
||||
PFN_vkCreateBuffer CreateBuffer;
|
||||
PFN_vkDestroyBuffer DestroyBuffer;
|
||||
PFN_vkCreateBufferView CreateBufferView;
|
||||
PFN_vkDestroyBufferView DestroyBufferView;
|
||||
PFN_vkCreateImage CreateImage;
|
||||
PFN_vkDestroyImage DestroyImage;
|
||||
PFN_vkGetImageSubresourceLayout GetImageSubresourceLayout;
|
||||
PFN_vkCreateImageView CreateImageView;
|
||||
PFN_vkDestroyImageView DestroyImageView;
|
||||
PFN_vkCreateShaderModule CreateShaderModule;
|
||||
PFN_vkDestroyShaderModule DestroyShaderModule;
|
||||
PFN_vkCreatePipelineCache CreatePipelineCache;
|
||||
PFN_vkDestroyPipelineCache DestroyPipelineCache;
|
||||
PFN_vkGetPipelineCacheData GetPipelineCacheData;
|
||||
PFN_vkMergePipelineCaches MergePipelineCaches;
|
||||
PFN_vkCreateGraphicsPipelines CreateGraphicsPipelines;
|
||||
PFN_vkCreateComputePipelines CreateComputePipelines;
|
||||
PFN_vkDestroyPipeline DestroyPipeline;
|
||||
PFN_vkCreatePipelineLayout CreatePipelineLayout;
|
||||
PFN_vkDestroyPipelineLayout DestroyPipelineLayout;
|
||||
PFN_vkCreateSampler CreateSampler;
|
||||
PFN_vkDestroySampler DestroySampler;
|
||||
PFN_vkCreateDescriptorSetLayout CreateDescriptorSetLayout;
|
||||
PFN_vkDestroyDescriptorSetLayout DestroyDescriptorSetLayout;
|
||||
PFN_vkCreateDescriptorPool CreateDescriptorPool;
|
||||
PFN_vkDestroyDescriptorPool DestroyDescriptorPool;
|
||||
PFN_vkResetDescriptorPool ResetDescriptorPool;
|
||||
PFN_vkAllocateDescriptorSets AllocateDescriptorSets;
|
||||
PFN_vkFreeDescriptorSets FreeDescriptorSets;
|
||||
PFN_vkUpdateDescriptorSets UpdateDescriptorSets;
|
||||
PFN_vkCreateFramebuffer CreateFramebuffer;
|
||||
PFN_vkDestroyFramebuffer DestroyFramebuffer;
|
||||
PFN_vkCreateRenderPass CreateRenderPass;
|
||||
PFN_vkDestroyRenderPass DestroyRenderPass;
|
||||
PFN_vkGetRenderAreaGranularity GetRenderAreaGranularity;
|
||||
PFN_vkCreateCommandPool CreateCommandPool;
|
||||
PFN_vkDestroyCommandPool DestroyCommandPool;
|
||||
PFN_vkResetCommandPool ResetCommandPool;
|
||||
PFN_vkAllocateCommandBuffers AllocateCommandBuffers;
|
||||
PFN_vkFreeCommandBuffers FreeCommandBuffers;
|
||||
PFN_vkBeginCommandBuffer BeginCommandBuffer;
|
||||
PFN_vkEndCommandBuffer EndCommandBuffer;
|
||||
PFN_vkResetCommandBuffer ResetCommandBuffer;
|
||||
PFN_vkCmdBindPipeline CmdBindPipeline;
|
||||
PFN_vkCmdSetViewport CmdSetViewport;
|
||||
PFN_vkCmdSetScissor CmdSetScissor;
|
||||
PFN_vkCmdSetLineWidth CmdSetLineWidth;
|
||||
PFN_vkCmdSetDepthBias CmdSetDepthBias;
|
||||
PFN_vkCmdSetBlendConstants CmdSetBlendConstants;
|
||||
PFN_vkCmdSetDepthBounds CmdSetDepthBounds;
|
||||
PFN_vkCmdSetStencilCompareMask CmdSetStencilCompareMask;
|
||||
PFN_vkCmdSetStencilWriteMask CmdSetStencilWriteMask;
|
||||
PFN_vkCmdSetStencilReference CmdSetStencilReference;
|
||||
PFN_vkCmdBindDescriptorSets CmdBindDescriptorSets;
|
||||
PFN_vkCmdBindIndexBuffer CmdBindIndexBuffer;
|
||||
PFN_vkCmdBindVertexBuffers CmdBindVertexBuffers;
|
||||
PFN_vkCmdDraw CmdDraw;
|
||||
PFN_vkCmdDrawIndexed CmdDrawIndexed;
|
||||
PFN_vkCmdDrawIndirect CmdDrawIndirect;
|
||||
PFN_vkCmdDrawIndexedIndirect CmdDrawIndexedIndirect;
|
||||
PFN_vkCmdDispatch CmdDispatch;
|
||||
PFN_vkCmdDispatchIndirect CmdDispatchIndirect;
|
||||
PFN_vkCmdCopyBuffer CmdCopyBuffer;
|
||||
PFN_vkCmdCopyImage CmdCopyImage;
|
||||
PFN_vkCmdBlitImage CmdBlitImage;
|
||||
PFN_vkCmdCopyBufferToImage CmdCopyBufferToImage;
|
||||
PFN_vkCmdCopyImageToBuffer CmdCopyImageToBuffer;
|
||||
PFN_vkCmdUpdateBuffer CmdUpdateBuffer;
|
||||
PFN_vkCmdFillBuffer CmdFillBuffer;
|
||||
PFN_vkCmdClearColorImage CmdClearColorImage;
|
||||
PFN_vkCmdClearDepthStencilImage CmdClearDepthStencilImage;
|
||||
PFN_vkCmdClearAttachments CmdClearAttachments;
|
||||
PFN_vkCmdResolveImage CmdResolveImage;
|
||||
PFN_vkCmdSetEvent CmdSetEvent;
|
||||
PFN_vkCmdResetEvent CmdResetEvent;
|
||||
PFN_vkCmdWaitEvents CmdWaitEvents;
|
||||
PFN_vkCmdPipelineBarrier CmdPipelineBarrier;
|
||||
PFN_vkCmdBeginQuery CmdBeginQuery;
|
||||
PFN_vkCmdEndQuery CmdEndQuery;
|
||||
PFN_vkCmdResetQueryPool CmdResetQueryPool;
|
||||
PFN_vkCmdWriteTimestamp CmdWriteTimestamp;
|
||||
PFN_vkCmdCopyQueryPoolResults CmdCopyQueryPoolResults;
|
||||
PFN_vkCmdPushConstants CmdPushConstants;
|
||||
PFN_vkCmdBeginRenderPass CmdBeginRenderPass;
|
||||
PFN_vkCmdNextSubpass CmdNextSubpass;
|
||||
PFN_vkCmdEndRenderPass CmdEndRenderPass;
|
||||
PFN_vkCmdExecuteCommands CmdExecuteCommands;
|
||||
PFN_vkBindBufferMemory2 BindBufferMemory2;
|
||||
PFN_vkBindImageMemory2 BindImageMemory2;
|
||||
PFN_vkGetDeviceGroupPeerMemoryFeatures GetDeviceGroupPeerMemoryFeatures;
|
||||
PFN_vkCmdSetDeviceMask CmdSetDeviceMask;
|
||||
PFN_vkCmdDispatchBase CmdDispatchBase;
|
||||
PFN_vkGetImageMemoryRequirements2 GetImageMemoryRequirements2;
|
||||
PFN_vkGetBufferMemoryRequirements2 GetBufferMemoryRequirements2;
|
||||
PFN_vkGetImageSparseMemoryRequirements2 GetImageSparseMemoryRequirements2;
|
||||
PFN_vkTrimCommandPool TrimCommandPool;
|
||||
PFN_vkGetDeviceQueue2 GetDeviceQueue2;
|
||||
PFN_vkCreateSamplerYcbcrConversion CreateSamplerYcbcrConversion;
|
||||
PFN_vkDestroySamplerYcbcrConversion DestroySamplerYcbcrConversion;
|
||||
PFN_vkCreateDescriptorUpdateTemplate CreateDescriptorUpdateTemplate;
|
||||
PFN_vkDestroyDescriptorUpdateTemplate DestroyDescriptorUpdateTemplate;
|
||||
PFN_vkUpdateDescriptorSetWithTemplate UpdateDescriptorSetWithTemplate;
|
||||
PFN_vkGetDescriptorSetLayoutSupport GetDescriptorSetLayoutSupport;
|
||||
PFN_vkCmdDrawIndirectCount CmdDrawIndirectCount;
|
||||
PFN_vkCmdDrawIndexedIndirectCount CmdDrawIndexedIndirectCount;
|
||||
PFN_vkCreateRenderPass2 CreateRenderPass2;
|
||||
PFN_vkCmdBeginRenderPass2 CmdBeginRenderPass2;
|
||||
PFN_vkCmdNextSubpass2 CmdNextSubpass2;
|
||||
PFN_vkCmdEndRenderPass2 CmdEndRenderPass2;
|
||||
PFN_vkResetQueryPool ResetQueryPool;
|
||||
PFN_vkGetSemaphoreCounterValue GetSemaphoreCounterValue;
|
||||
PFN_vkWaitSemaphores WaitSemaphores;
|
||||
PFN_vkSignalSemaphore SignalSemaphore;
|
||||
PFN_vkGetBufferDeviceAddress GetBufferDeviceAddress;
|
||||
PFN_vkGetBufferOpaqueCaptureAddress GetBufferOpaqueCaptureAddress;
|
||||
PFN_vkGetDeviceMemoryOpaqueCaptureAddress GetDeviceMemoryOpaqueCaptureAddress;
|
||||
PFN_vkCreatePrivateDataSlot CreatePrivateDataSlot;
|
||||
PFN_vkDestroyPrivateDataSlot DestroyPrivateDataSlot;
|
||||
PFN_vkSetPrivateData SetPrivateData;
|
||||
PFN_vkGetPrivateData GetPrivateData;
|
||||
PFN_vkCmdSetEvent2 CmdSetEvent2;
|
||||
PFN_vkCmdResetEvent2 CmdResetEvent2;
|
||||
PFN_vkCmdWaitEvents2 CmdWaitEvents2;
|
||||
PFN_vkCmdPipelineBarrier2 CmdPipelineBarrier2;
|
||||
PFN_vkCmdWriteTimestamp2 CmdWriteTimestamp2;
|
||||
PFN_vkQueueSubmit2 QueueSubmit2;
|
||||
PFN_vkCmdCopyBuffer2 CmdCopyBuffer2;
|
||||
PFN_vkCmdCopyImage2 CmdCopyImage2;
|
||||
PFN_vkCmdCopyBufferToImage2 CmdCopyBufferToImage2;
|
||||
PFN_vkCmdCopyImageToBuffer2 CmdCopyImageToBuffer2;
|
||||
PFN_vkCmdBlitImage2 CmdBlitImage2;
|
||||
PFN_vkCmdResolveImage2 CmdResolveImage2;
|
||||
PFN_vkCmdBeginRendering CmdBeginRendering;
|
||||
PFN_vkCmdEndRendering CmdEndRendering;
|
||||
PFN_vkCmdSetCullMode CmdSetCullMode;
|
||||
PFN_vkCmdSetFrontFace CmdSetFrontFace;
|
||||
PFN_vkCmdSetPrimitiveTopology CmdSetPrimitiveTopology;
|
||||
PFN_vkCmdSetViewportWithCount CmdSetViewportWithCount;
|
||||
PFN_vkCmdSetScissorWithCount CmdSetScissorWithCount;
|
||||
PFN_vkCmdBindVertexBuffers2 CmdBindVertexBuffers2;
|
||||
PFN_vkCmdSetDepthTestEnable CmdSetDepthTestEnable;
|
||||
PFN_vkCmdSetDepthWriteEnable CmdSetDepthWriteEnable;
|
||||
PFN_vkCmdSetDepthCompareOp CmdSetDepthCompareOp;
|
||||
PFN_vkCmdSetDepthBoundsTestEnable CmdSetDepthBoundsTestEnable;
|
||||
PFN_vkCmdSetStencilTestEnable CmdSetStencilTestEnable;
|
||||
PFN_vkCmdSetStencilOp CmdSetStencilOp;
|
||||
PFN_vkCmdSetRasterizerDiscardEnable CmdSetRasterizerDiscardEnable;
|
||||
PFN_vkCmdSetDepthBiasEnable CmdSetDepthBiasEnable;
|
||||
PFN_vkCmdSetPrimitiveRestartEnable CmdSetPrimitiveRestartEnable;
|
||||
PFN_vkGetDeviceBufferMemoryRequirements GetDeviceBufferMemoryRequirements;
|
||||
PFN_vkGetDeviceImageMemoryRequirements GetDeviceImageMemoryRequirements;
|
||||
PFN_vkGetDeviceImageSparseMemoryRequirements GetDeviceImageSparseMemoryRequirements;
|
||||
PFN_vkCreateSwapchainKHR CreateSwapchainKHR;
|
||||
PFN_vkDestroySwapchainKHR DestroySwapchainKHR;
|
||||
PFN_vkGetSwapchainImagesKHR GetSwapchainImagesKHR;
|
||||
PFN_vkAcquireNextImageKHR AcquireNextImageKHR;
|
||||
PFN_vkQueuePresentKHR QueuePresentKHR;
|
||||
PFN_vkGetDeviceGroupPresentCapabilitiesKHR GetDeviceGroupPresentCapabilitiesKHR;
|
||||
PFN_vkGetDeviceGroupSurfacePresentModesKHR GetDeviceGroupSurfacePresentModesKHR;
|
||||
PFN_vkAcquireNextImage2KHR AcquireNextImage2KHR;
|
||||
PFN_vkCreateSharedSwapchainsKHR CreateSharedSwapchainsKHR;
|
||||
PFN_vkCreateVideoSessionKHR CreateVideoSessionKHR;
|
||||
PFN_vkDestroyVideoSessionKHR DestroyVideoSessionKHR;
|
||||
PFN_vkGetVideoSessionMemoryRequirementsKHR GetVideoSessionMemoryRequirementsKHR;
|
||||
PFN_vkBindVideoSessionMemoryKHR BindVideoSessionMemoryKHR;
|
||||
PFN_vkCreateVideoSessionParametersKHR CreateVideoSessionParametersKHR;
|
||||
PFN_vkUpdateVideoSessionParametersKHR UpdateVideoSessionParametersKHR;
|
||||
PFN_vkDestroyVideoSessionParametersKHR DestroyVideoSessionParametersKHR;
|
||||
PFN_vkCmdBeginVideoCodingKHR CmdBeginVideoCodingKHR;
|
||||
PFN_vkCmdEndVideoCodingKHR CmdEndVideoCodingKHR;
|
||||
PFN_vkCmdControlVideoCodingKHR CmdControlVideoCodingKHR;
|
||||
PFN_vkCmdDecodeVideoKHR CmdDecodeVideoKHR;
|
||||
PFN_vkCmdBeginRenderingKHR CmdBeginRenderingKHR;
|
||||
PFN_vkCmdEndRenderingKHR CmdEndRenderingKHR;
|
||||
PFN_vkGetDeviceGroupPeerMemoryFeaturesKHR GetDeviceGroupPeerMemoryFeaturesKHR;
|
||||
PFN_vkCmdSetDeviceMaskKHR CmdSetDeviceMaskKHR;
|
||||
PFN_vkCmdDispatchBaseKHR CmdDispatchBaseKHR;
|
||||
PFN_vkTrimCommandPoolKHR TrimCommandPoolKHR;
|
||||
#ifdef VK_USE_PLATFORM_WIN32_KHR
|
||||
PFN_vkGetMemoryWin32HandleKHR GetMemoryWin32HandleKHR;
|
||||
#endif //VK_USE_PLATFORM_WIN32_KHR
|
||||
#ifdef VK_USE_PLATFORM_WIN32_KHR
|
||||
PFN_vkGetMemoryWin32HandlePropertiesKHR GetMemoryWin32HandlePropertiesKHR;
|
||||
#endif //VK_USE_PLATFORM_WIN32_KHR
|
||||
PFN_vkGetMemoryFdKHR GetMemoryFdKHR;
|
||||
PFN_vkGetMemoryFdPropertiesKHR GetMemoryFdPropertiesKHR;
|
||||
#ifdef VK_USE_PLATFORM_WIN32_KHR
|
||||
PFN_vkImportSemaphoreWin32HandleKHR ImportSemaphoreWin32HandleKHR;
|
||||
#endif //VK_USE_PLATFORM_WIN32_KHR
|
||||
#ifdef VK_USE_PLATFORM_WIN32_KHR
|
||||
PFN_vkGetSemaphoreWin32HandleKHR GetSemaphoreWin32HandleKHR;
|
||||
#endif //VK_USE_PLATFORM_WIN32_KHR
|
||||
PFN_vkImportSemaphoreFdKHR ImportSemaphoreFdKHR;
|
||||
PFN_vkGetSemaphoreFdKHR GetSemaphoreFdKHR;
|
||||
PFN_vkCmdPushDescriptorSetKHR CmdPushDescriptorSetKHR;
|
||||
PFN_vkCmdPushDescriptorSetWithTemplateKHR CmdPushDescriptorSetWithTemplateKHR;
|
||||
PFN_vkCreateDescriptorUpdateTemplateKHR CreateDescriptorUpdateTemplateKHR;
|
||||
PFN_vkDestroyDescriptorUpdateTemplateKHR DestroyDescriptorUpdateTemplateKHR;
|
||||
PFN_vkUpdateDescriptorSetWithTemplateKHR UpdateDescriptorSetWithTemplateKHR;
|
||||
PFN_vkCreateRenderPass2KHR CreateRenderPass2KHR;
|
||||
PFN_vkCmdBeginRenderPass2KHR CmdBeginRenderPass2KHR;
|
||||
PFN_vkCmdNextSubpass2KHR CmdNextSubpass2KHR;
|
||||
PFN_vkCmdEndRenderPass2KHR CmdEndRenderPass2KHR;
|
||||
PFN_vkGetSwapchainStatusKHR GetSwapchainStatusKHR;
|
||||
#ifdef VK_USE_PLATFORM_WIN32_KHR
|
||||
PFN_vkImportFenceWin32HandleKHR ImportFenceWin32HandleKHR;
|
||||
#endif //VK_USE_PLATFORM_WIN32_KHR
|
||||
#ifdef VK_USE_PLATFORM_WIN32_KHR
|
||||
PFN_vkGetFenceWin32HandleKHR GetFenceWin32HandleKHR;
|
||||
#endif //VK_USE_PLATFORM_WIN32_KHR
|
||||
PFN_vkImportFenceFdKHR ImportFenceFdKHR;
|
||||
PFN_vkGetFenceFdKHR GetFenceFdKHR;
|
||||
PFN_vkAcquireProfilingLockKHR AcquireProfilingLockKHR;
|
||||
PFN_vkReleaseProfilingLockKHR ReleaseProfilingLockKHR;
|
||||
PFN_vkGetImageMemoryRequirements2KHR GetImageMemoryRequirements2KHR;
|
||||
PFN_vkGetBufferMemoryRequirements2KHR GetBufferMemoryRequirements2KHR;
|
||||
PFN_vkGetImageSparseMemoryRequirements2KHR GetImageSparseMemoryRequirements2KHR;
|
||||
PFN_vkCreateSamplerYcbcrConversionKHR CreateSamplerYcbcrConversionKHR;
|
||||
PFN_vkDestroySamplerYcbcrConversionKHR DestroySamplerYcbcrConversionKHR;
|
||||
PFN_vkBindBufferMemory2KHR BindBufferMemory2KHR;
|
||||
PFN_vkBindImageMemory2KHR BindImageMemory2KHR;
|
||||
PFN_vkGetDescriptorSetLayoutSupportKHR GetDescriptorSetLayoutSupportKHR;
|
||||
PFN_vkCmdDrawIndirectCountKHR CmdDrawIndirectCountKHR;
|
||||
PFN_vkCmdDrawIndexedIndirectCountKHR CmdDrawIndexedIndirectCountKHR;
|
||||
PFN_vkGetSemaphoreCounterValueKHR GetSemaphoreCounterValueKHR;
|
||||
PFN_vkWaitSemaphoresKHR WaitSemaphoresKHR;
|
||||
PFN_vkSignalSemaphoreKHR SignalSemaphoreKHR;
|
||||
PFN_vkCmdSetFragmentShadingRateKHR CmdSetFragmentShadingRateKHR;
|
||||
PFN_vkWaitForPresentKHR WaitForPresentKHR;
|
||||
PFN_vkGetBufferDeviceAddressKHR GetBufferDeviceAddressKHR;
|
||||
PFN_vkGetBufferOpaqueCaptureAddressKHR GetBufferOpaqueCaptureAddressKHR;
|
||||
PFN_vkGetDeviceMemoryOpaqueCaptureAddressKHR GetDeviceMemoryOpaqueCaptureAddressKHR;
|
||||
PFN_vkCreateDeferredOperationKHR CreateDeferredOperationKHR;
|
||||
PFN_vkDestroyDeferredOperationKHR DestroyDeferredOperationKHR;
|
||||
PFN_vkGetDeferredOperationMaxConcurrencyKHR GetDeferredOperationMaxConcurrencyKHR;
|
||||
PFN_vkGetDeferredOperationResultKHR GetDeferredOperationResultKHR;
|
||||
PFN_vkDeferredOperationJoinKHR DeferredOperationJoinKHR;
|
||||
PFN_vkGetPipelineExecutablePropertiesKHR GetPipelineExecutablePropertiesKHR;
|
||||
PFN_vkGetPipelineExecutableStatisticsKHR GetPipelineExecutableStatisticsKHR;
|
||||
PFN_vkGetPipelineExecutableInternalRepresentationsKHR GetPipelineExecutableInternalRepresentationsKHR;
|
||||
PFN_vkMapMemory2KHR MapMemory2KHR;
|
||||
PFN_vkUnmapMemory2KHR UnmapMemory2KHR;
|
||||
#ifdef VK_ENABLE_BETA_EXTENSIONS
|
||||
PFN_vkGetEncodedVideoSessionParametersKHR GetEncodedVideoSessionParametersKHR;
|
||||
#endif //VK_ENABLE_BETA_EXTENSIONS
|
||||
#ifdef VK_ENABLE_BETA_EXTENSIONS
|
||||
PFN_vkCmdEncodeVideoKHR CmdEncodeVideoKHR;
|
||||
#endif //VK_ENABLE_BETA_EXTENSIONS
|
||||
PFN_vkCmdSetEvent2KHR CmdSetEvent2KHR;
|
||||
PFN_vkCmdResetEvent2KHR CmdResetEvent2KHR;
|
||||
PFN_vkCmdWaitEvents2KHR CmdWaitEvents2KHR;
|
||||
PFN_vkCmdPipelineBarrier2KHR CmdPipelineBarrier2KHR;
|
||||
PFN_vkCmdWriteTimestamp2KHR CmdWriteTimestamp2KHR;
|
||||
PFN_vkQueueSubmit2KHR QueueSubmit2KHR;
|
||||
PFN_vkCmdWriteBufferMarker2AMD CmdWriteBufferMarker2AMD;
|
||||
PFN_vkGetQueueCheckpointData2NV GetQueueCheckpointData2NV;
|
||||
PFN_vkCmdCopyBuffer2KHR CmdCopyBuffer2KHR;
|
||||
PFN_vkCmdCopyImage2KHR CmdCopyImage2KHR;
|
||||
PFN_vkCmdCopyBufferToImage2KHR CmdCopyBufferToImage2KHR;
|
||||
PFN_vkCmdCopyImageToBuffer2KHR CmdCopyImageToBuffer2KHR;
|
||||
PFN_vkCmdBlitImage2KHR CmdBlitImage2KHR;
|
||||
PFN_vkCmdResolveImage2KHR CmdResolveImage2KHR;
|
||||
PFN_vkCmdTraceRaysIndirect2KHR CmdTraceRaysIndirect2KHR;
|
||||
PFN_vkGetDeviceBufferMemoryRequirementsKHR GetDeviceBufferMemoryRequirementsKHR;
|
||||
PFN_vkGetDeviceImageMemoryRequirementsKHR GetDeviceImageMemoryRequirementsKHR;
|
||||
PFN_vkGetDeviceImageSparseMemoryRequirementsKHR GetDeviceImageSparseMemoryRequirementsKHR;
|
||||
PFN_vkDebugMarkerSetObjectTagEXT DebugMarkerSetObjectTagEXT;
|
||||
PFN_vkDebugMarkerSetObjectNameEXT DebugMarkerSetObjectNameEXT;
|
||||
PFN_vkCmdDebugMarkerBeginEXT CmdDebugMarkerBeginEXT;
|
||||
PFN_vkCmdDebugMarkerEndEXT CmdDebugMarkerEndEXT;
|
||||
PFN_vkCmdDebugMarkerInsertEXT CmdDebugMarkerInsertEXT;
|
||||
PFN_vkCmdBindTransformFeedbackBuffersEXT CmdBindTransformFeedbackBuffersEXT;
|
||||
PFN_vkCmdBeginTransformFeedbackEXT CmdBeginTransformFeedbackEXT;
|
||||
PFN_vkCmdEndTransformFeedbackEXT CmdEndTransformFeedbackEXT;
|
||||
PFN_vkCmdBeginQueryIndexedEXT CmdBeginQueryIndexedEXT;
|
||||
PFN_vkCmdEndQueryIndexedEXT CmdEndQueryIndexedEXT;
|
||||
PFN_vkCmdDrawIndirectByteCountEXT CmdDrawIndirectByteCountEXT;
|
||||
PFN_vkCreateCuModuleNVX CreateCuModuleNVX;
|
||||
PFN_vkCreateCuFunctionNVX CreateCuFunctionNVX;
|
||||
PFN_vkDestroyCuModuleNVX DestroyCuModuleNVX;
|
||||
PFN_vkDestroyCuFunctionNVX DestroyCuFunctionNVX;
|
||||
PFN_vkCmdCuLaunchKernelNVX CmdCuLaunchKernelNVX;
|
||||
PFN_vkGetImageViewHandleNVX GetImageViewHandleNVX;
|
||||
PFN_vkGetImageViewAddressNVX GetImageViewAddressNVX;
|
||||
PFN_vkCmdDrawIndirectCountAMD CmdDrawIndirectCountAMD;
|
||||
PFN_vkCmdDrawIndexedIndirectCountAMD CmdDrawIndexedIndirectCountAMD;
|
||||
PFN_vkGetShaderInfoAMD GetShaderInfoAMD;
|
||||
#ifdef VK_USE_PLATFORM_WIN32_KHR
|
||||
PFN_vkGetMemoryWin32HandleNV GetMemoryWin32HandleNV;
|
||||
#endif //VK_USE_PLATFORM_WIN32_KHR
|
||||
PFN_vkCmdBeginConditionalRenderingEXT CmdBeginConditionalRenderingEXT;
|
||||
PFN_vkCmdEndConditionalRenderingEXT CmdEndConditionalRenderingEXT;
|
||||
PFN_vkCmdSetViewportWScalingNV CmdSetViewportWScalingNV;
|
||||
PFN_vkDisplayPowerControlEXT DisplayPowerControlEXT;
|
||||
PFN_vkRegisterDeviceEventEXT RegisterDeviceEventEXT;
|
||||
PFN_vkRegisterDisplayEventEXT RegisterDisplayEventEXT;
|
||||
PFN_vkGetSwapchainCounterEXT GetSwapchainCounterEXT;
|
||||
PFN_vkGetRefreshCycleDurationGOOGLE GetRefreshCycleDurationGOOGLE;
|
||||
PFN_vkGetPastPresentationTimingGOOGLE GetPastPresentationTimingGOOGLE;
|
||||
PFN_vkCmdSetDiscardRectangleEXT CmdSetDiscardRectangleEXT;
|
||||
PFN_vkCmdSetDiscardRectangleEnableEXT CmdSetDiscardRectangleEnableEXT;
|
||||
PFN_vkCmdSetDiscardRectangleModeEXT CmdSetDiscardRectangleModeEXT;
|
||||
PFN_vkSetHdrMetadataEXT SetHdrMetadataEXT;
|
||||
PFN_vkSetDebugUtilsObjectNameEXT SetDebugUtilsObjectNameEXT;
|
||||
PFN_vkSetDebugUtilsObjectTagEXT SetDebugUtilsObjectTagEXT;
|
||||
PFN_vkQueueBeginDebugUtilsLabelEXT QueueBeginDebugUtilsLabelEXT;
|
||||
PFN_vkQueueEndDebugUtilsLabelEXT QueueEndDebugUtilsLabelEXT;
|
||||
PFN_vkQueueInsertDebugUtilsLabelEXT QueueInsertDebugUtilsLabelEXT;
|
||||
PFN_vkCmdBeginDebugUtilsLabelEXT CmdBeginDebugUtilsLabelEXT;
|
||||
PFN_vkCmdEndDebugUtilsLabelEXT CmdEndDebugUtilsLabelEXT;
|
||||
PFN_vkCmdInsertDebugUtilsLabelEXT CmdInsertDebugUtilsLabelEXT;
|
||||
#ifdef VK_USE_PLATFORM_ANDROID_KHR
|
||||
PFN_vkGetAndroidHardwareBufferPropertiesANDROID GetAndroidHardwareBufferPropertiesANDROID;
|
||||
#endif //VK_USE_PLATFORM_ANDROID_KHR
|
||||
#ifdef VK_USE_PLATFORM_ANDROID_KHR
|
||||
PFN_vkGetMemoryAndroidHardwareBufferANDROID GetMemoryAndroidHardwareBufferANDROID;
|
||||
#endif //VK_USE_PLATFORM_ANDROID_KHR
|
||||
PFN_vkCmdSetSampleLocationsEXT CmdSetSampleLocationsEXT;
|
||||
PFN_vkGetImageDrmFormatModifierPropertiesEXT GetImageDrmFormatModifierPropertiesEXT;
|
||||
PFN_vkCreateValidationCacheEXT CreateValidationCacheEXT;
|
||||
PFN_vkDestroyValidationCacheEXT DestroyValidationCacheEXT;
|
||||
PFN_vkMergeValidationCachesEXT MergeValidationCachesEXT;
|
||||
PFN_vkGetValidationCacheDataEXT GetValidationCacheDataEXT;
|
||||
PFN_vkCmdBindShadingRateImageNV CmdBindShadingRateImageNV;
|
||||
PFN_vkCmdSetViewportShadingRatePaletteNV CmdSetViewportShadingRatePaletteNV;
|
||||
PFN_vkCmdSetCoarseSampleOrderNV CmdSetCoarseSampleOrderNV;
|
||||
PFN_vkCreateAccelerationStructureNV CreateAccelerationStructureNV;
|
||||
PFN_vkDestroyAccelerationStructureNV DestroyAccelerationStructureNV;
|
||||
PFN_vkGetAccelerationStructureMemoryRequirementsNV GetAccelerationStructureMemoryRequirementsNV;
|
||||
PFN_vkBindAccelerationStructureMemoryNV BindAccelerationStructureMemoryNV;
|
||||
PFN_vkCmdBuildAccelerationStructureNV CmdBuildAccelerationStructureNV;
|
||||
PFN_vkCmdCopyAccelerationStructureNV CmdCopyAccelerationStructureNV;
|
||||
PFN_vkCmdTraceRaysNV CmdTraceRaysNV;
|
||||
PFN_vkCreateRayTracingPipelinesNV CreateRayTracingPipelinesNV;
|
||||
PFN_vkGetRayTracingShaderGroupHandlesKHR GetRayTracingShaderGroupHandlesKHR;
|
||||
PFN_vkGetRayTracingShaderGroupHandlesNV GetRayTracingShaderGroupHandlesNV;
|
||||
PFN_vkGetAccelerationStructureHandleNV GetAccelerationStructureHandleNV;
|
||||
PFN_vkCmdWriteAccelerationStructuresPropertiesNV CmdWriteAccelerationStructuresPropertiesNV;
|
||||
PFN_vkCompileDeferredNV CompileDeferredNV;
|
||||
PFN_vkGetMemoryHostPointerPropertiesEXT GetMemoryHostPointerPropertiesEXT;
|
||||
PFN_vkCmdWriteBufferMarkerAMD CmdWriteBufferMarkerAMD;
|
||||
PFN_vkGetCalibratedTimestampsEXT GetCalibratedTimestampsEXT;
|
||||
PFN_vkCmdDrawMeshTasksNV CmdDrawMeshTasksNV;
|
||||
PFN_vkCmdDrawMeshTasksIndirectNV CmdDrawMeshTasksIndirectNV;
|
||||
PFN_vkCmdDrawMeshTasksIndirectCountNV CmdDrawMeshTasksIndirectCountNV;
|
||||
PFN_vkCmdSetExclusiveScissorEnableNV CmdSetExclusiveScissorEnableNV;
|
||||
PFN_vkCmdSetExclusiveScissorNV CmdSetExclusiveScissorNV;
|
||||
PFN_vkCmdSetCheckpointNV CmdSetCheckpointNV;
|
||||
PFN_vkGetQueueCheckpointDataNV GetQueueCheckpointDataNV;
|
||||
PFN_vkInitializePerformanceApiINTEL InitializePerformanceApiINTEL;
|
||||
PFN_vkUninitializePerformanceApiINTEL UninitializePerformanceApiINTEL;
|
||||
PFN_vkCmdSetPerformanceMarkerINTEL CmdSetPerformanceMarkerINTEL;
|
||||
PFN_vkCmdSetPerformanceStreamMarkerINTEL CmdSetPerformanceStreamMarkerINTEL;
|
||||
PFN_vkCmdSetPerformanceOverrideINTEL CmdSetPerformanceOverrideINTEL;
|
||||
PFN_vkAcquirePerformanceConfigurationINTEL AcquirePerformanceConfigurationINTEL;
|
||||
PFN_vkReleasePerformanceConfigurationINTEL ReleasePerformanceConfigurationINTEL;
|
||||
PFN_vkQueueSetPerformanceConfigurationINTEL QueueSetPerformanceConfigurationINTEL;
|
||||
PFN_vkGetPerformanceParameterINTEL GetPerformanceParameterINTEL;
|
||||
PFN_vkSetLocalDimmingAMD SetLocalDimmingAMD;
|
||||
PFN_vkGetBufferDeviceAddressEXT GetBufferDeviceAddressEXT;
|
||||
#ifdef VK_USE_PLATFORM_WIN32_KHR
|
||||
PFN_vkAcquireFullScreenExclusiveModeEXT AcquireFullScreenExclusiveModeEXT;
|
||||
#endif //VK_USE_PLATFORM_WIN32_KHR
|
||||
#ifdef VK_USE_PLATFORM_WIN32_KHR
|
||||
PFN_vkReleaseFullScreenExclusiveModeEXT ReleaseFullScreenExclusiveModeEXT;
|
||||
#endif //VK_USE_PLATFORM_WIN32_KHR
|
||||
#ifdef VK_USE_PLATFORM_WIN32_KHR
|
||||
PFN_vkGetDeviceGroupSurfacePresentModes2EXT GetDeviceGroupSurfacePresentModes2EXT;
|
||||
#endif //VK_USE_PLATFORM_WIN32_KHR
|
||||
PFN_vkCmdSetLineStippleEXT CmdSetLineStippleEXT;
|
||||
PFN_vkResetQueryPoolEXT ResetQueryPoolEXT;
|
||||
PFN_vkCmdSetCullModeEXT CmdSetCullModeEXT;
|
||||
PFN_vkCmdSetFrontFaceEXT CmdSetFrontFaceEXT;
|
||||
PFN_vkCmdSetPrimitiveTopologyEXT CmdSetPrimitiveTopologyEXT;
|
||||
PFN_vkCmdSetViewportWithCountEXT CmdSetViewportWithCountEXT;
|
||||
PFN_vkCmdSetScissorWithCountEXT CmdSetScissorWithCountEXT;
|
||||
PFN_vkCmdBindVertexBuffers2EXT CmdBindVertexBuffers2EXT;
|
||||
PFN_vkCmdSetDepthTestEnableEXT CmdSetDepthTestEnableEXT;
|
||||
PFN_vkCmdSetDepthWriteEnableEXT CmdSetDepthWriteEnableEXT;
|
||||
PFN_vkCmdSetDepthCompareOpEXT CmdSetDepthCompareOpEXT;
|
||||
PFN_vkCmdSetDepthBoundsTestEnableEXT CmdSetDepthBoundsTestEnableEXT;
|
||||
PFN_vkCmdSetStencilTestEnableEXT CmdSetStencilTestEnableEXT;
|
||||
PFN_vkCmdSetStencilOpEXT CmdSetStencilOpEXT;
|
||||
PFN_vkReleaseSwapchainImagesEXT ReleaseSwapchainImagesEXT;
|
||||
PFN_vkGetGeneratedCommandsMemoryRequirementsNV GetGeneratedCommandsMemoryRequirementsNV;
|
||||
PFN_vkCmdPreprocessGeneratedCommandsNV CmdPreprocessGeneratedCommandsNV;
|
||||
PFN_vkCmdExecuteGeneratedCommandsNV CmdExecuteGeneratedCommandsNV;
|
||||
PFN_vkCmdBindPipelineShaderGroupNV CmdBindPipelineShaderGroupNV;
|
||||
PFN_vkCreateIndirectCommandsLayoutNV CreateIndirectCommandsLayoutNV;
|
||||
PFN_vkDestroyIndirectCommandsLayoutNV DestroyIndirectCommandsLayoutNV;
|
||||
PFN_vkCmdSetDepthBias2EXT CmdSetDepthBias2EXT;
|
||||
PFN_vkCreatePrivateDataSlotEXT CreatePrivateDataSlotEXT;
|
||||
PFN_vkDestroyPrivateDataSlotEXT DestroyPrivateDataSlotEXT;
|
||||
PFN_vkSetPrivateDataEXT SetPrivateDataEXT;
|
||||
PFN_vkGetPrivateDataEXT GetPrivateDataEXT;
|
||||
#ifdef VK_USE_PLATFORM_METAL_EXT
|
||||
PFN_vkExportMetalObjectsEXT ExportMetalObjectsEXT;
|
||||
#endif //VK_USE_PLATFORM_METAL_EXT
|
||||
PFN_vkGetDescriptorSetLayoutSizeEXT GetDescriptorSetLayoutSizeEXT;
|
||||
PFN_vkGetDescriptorSetLayoutBindingOffsetEXT GetDescriptorSetLayoutBindingOffsetEXT;
|
||||
PFN_vkGetDescriptorEXT GetDescriptorEXT;
|
||||
PFN_vkCmdBindDescriptorBuffersEXT CmdBindDescriptorBuffersEXT;
|
||||
PFN_vkCmdSetDescriptorBufferOffsetsEXT CmdSetDescriptorBufferOffsetsEXT;
|
||||
PFN_vkCmdBindDescriptorBufferEmbeddedSamplersEXT CmdBindDescriptorBufferEmbeddedSamplersEXT;
|
||||
PFN_vkGetBufferOpaqueCaptureDescriptorDataEXT GetBufferOpaqueCaptureDescriptorDataEXT;
|
||||
PFN_vkGetImageOpaqueCaptureDescriptorDataEXT GetImageOpaqueCaptureDescriptorDataEXT;
|
||||
PFN_vkGetImageViewOpaqueCaptureDescriptorDataEXT GetImageViewOpaqueCaptureDescriptorDataEXT;
|
||||
PFN_vkGetSamplerOpaqueCaptureDescriptorDataEXT GetSamplerOpaqueCaptureDescriptorDataEXT;
|
||||
PFN_vkGetAccelerationStructureOpaqueCaptureDescriptorDataEXT GetAccelerationStructureOpaqueCaptureDescriptorDataEXT;
|
||||
PFN_vkCmdSetFragmentShadingRateEnumNV CmdSetFragmentShadingRateEnumNV;
|
||||
PFN_vkGetImageSubresourceLayout2EXT GetImageSubresourceLayout2EXT;
|
||||
PFN_vkGetDeviceFaultInfoEXT GetDeviceFaultInfoEXT;
|
||||
PFN_vkCmdSetVertexInputEXT CmdSetVertexInputEXT;
|
||||
#ifdef VK_USE_PLATFORM_FUCHSIA
|
||||
PFN_vkGetMemoryZirconHandleFUCHSIA GetMemoryZirconHandleFUCHSIA;
|
||||
#endif //VK_USE_PLATFORM_FUCHSIA
|
||||
#ifdef VK_USE_PLATFORM_FUCHSIA
|
||||
PFN_vkGetMemoryZirconHandlePropertiesFUCHSIA GetMemoryZirconHandlePropertiesFUCHSIA;
|
||||
#endif //VK_USE_PLATFORM_FUCHSIA
|
||||
#ifdef VK_USE_PLATFORM_FUCHSIA
|
||||
PFN_vkImportSemaphoreZirconHandleFUCHSIA ImportSemaphoreZirconHandleFUCHSIA;
|
||||
#endif //VK_USE_PLATFORM_FUCHSIA
|
||||
#ifdef VK_USE_PLATFORM_FUCHSIA
|
||||
PFN_vkGetSemaphoreZirconHandleFUCHSIA GetSemaphoreZirconHandleFUCHSIA;
|
||||
#endif //VK_USE_PLATFORM_FUCHSIA
|
||||
#ifdef VK_USE_PLATFORM_FUCHSIA
|
||||
PFN_vkCreateBufferCollectionFUCHSIA CreateBufferCollectionFUCHSIA;
|
||||
#endif //VK_USE_PLATFORM_FUCHSIA
|
||||
#ifdef VK_USE_PLATFORM_FUCHSIA
|
||||
PFN_vkSetBufferCollectionImageConstraintsFUCHSIA SetBufferCollectionImageConstraintsFUCHSIA;
|
||||
#endif //VK_USE_PLATFORM_FUCHSIA
|
||||
#ifdef VK_USE_PLATFORM_FUCHSIA
|
||||
PFN_vkSetBufferCollectionBufferConstraintsFUCHSIA SetBufferCollectionBufferConstraintsFUCHSIA;
|
||||
#endif //VK_USE_PLATFORM_FUCHSIA
|
||||
#ifdef VK_USE_PLATFORM_FUCHSIA
|
||||
PFN_vkDestroyBufferCollectionFUCHSIA DestroyBufferCollectionFUCHSIA;
|
||||
#endif //VK_USE_PLATFORM_FUCHSIA
|
||||
#ifdef VK_USE_PLATFORM_FUCHSIA
|
||||
PFN_vkGetBufferCollectionPropertiesFUCHSIA GetBufferCollectionPropertiesFUCHSIA;
|
||||
#endif //VK_USE_PLATFORM_FUCHSIA
|
||||
PFN_vkGetDeviceSubpassShadingMaxWorkgroupSizeHUAWEI GetDeviceSubpassShadingMaxWorkgroupSizeHUAWEI;
|
||||
PFN_vkCmdSubpassShadingHUAWEI CmdSubpassShadingHUAWEI;
|
||||
PFN_vkCmdBindInvocationMaskHUAWEI CmdBindInvocationMaskHUAWEI;
|
||||
PFN_vkGetMemoryRemoteAddressNV GetMemoryRemoteAddressNV;
|
||||
PFN_vkGetPipelinePropertiesEXT GetPipelinePropertiesEXT;
|
||||
PFN_vkCmdSetPatchControlPointsEXT CmdSetPatchControlPointsEXT;
|
||||
PFN_vkCmdSetRasterizerDiscardEnableEXT CmdSetRasterizerDiscardEnableEXT;
|
||||
PFN_vkCmdSetDepthBiasEnableEXT CmdSetDepthBiasEnableEXT;
|
||||
PFN_vkCmdSetLogicOpEXT CmdSetLogicOpEXT;
|
||||
PFN_vkCmdSetPrimitiveRestartEnableEXT CmdSetPrimitiveRestartEnableEXT;
|
||||
PFN_vkCmdSetColorWriteEnableEXT CmdSetColorWriteEnableEXT;
|
||||
PFN_vkCmdDrawMultiEXT CmdDrawMultiEXT;
|
||||
PFN_vkCmdDrawMultiIndexedEXT CmdDrawMultiIndexedEXT;
|
||||
PFN_vkCreateMicromapEXT CreateMicromapEXT;
|
||||
PFN_vkDestroyMicromapEXT DestroyMicromapEXT;
|
||||
PFN_vkCmdBuildMicromapsEXT CmdBuildMicromapsEXT;
|
||||
PFN_vkBuildMicromapsEXT BuildMicromapsEXT;
|
||||
PFN_vkCopyMicromapEXT CopyMicromapEXT;
|
||||
PFN_vkCopyMicromapToMemoryEXT CopyMicromapToMemoryEXT;
|
||||
PFN_vkCopyMemoryToMicromapEXT CopyMemoryToMicromapEXT;
|
||||
PFN_vkWriteMicromapsPropertiesEXT WriteMicromapsPropertiesEXT;
|
||||
PFN_vkCmdCopyMicromapEXT CmdCopyMicromapEXT;
|
||||
PFN_vkCmdCopyMicromapToMemoryEXT CmdCopyMicromapToMemoryEXT;
|
||||
PFN_vkCmdCopyMemoryToMicromapEXT CmdCopyMemoryToMicromapEXT;
|
||||
PFN_vkCmdWriteMicromapsPropertiesEXT CmdWriteMicromapsPropertiesEXT;
|
||||
PFN_vkGetDeviceMicromapCompatibilityEXT GetDeviceMicromapCompatibilityEXT;
|
||||
PFN_vkGetMicromapBuildSizesEXT GetMicromapBuildSizesEXT;
|
||||
PFN_vkCmdDrawClusterHUAWEI CmdDrawClusterHUAWEI;
|
||||
PFN_vkCmdDrawClusterIndirectHUAWEI CmdDrawClusterIndirectHUAWEI;
|
||||
PFN_vkSetDeviceMemoryPriorityEXT SetDeviceMemoryPriorityEXT;
|
||||
PFN_vkGetDescriptorSetLayoutHostMappingInfoVALVE GetDescriptorSetLayoutHostMappingInfoVALVE;
|
||||
PFN_vkGetDescriptorSetHostMappingVALVE GetDescriptorSetHostMappingVALVE;
|
||||
PFN_vkCmdCopyMemoryIndirectNV CmdCopyMemoryIndirectNV;
|
||||
PFN_vkCmdCopyMemoryToImageIndirectNV CmdCopyMemoryToImageIndirectNV;
|
||||
PFN_vkCmdDecompressMemoryNV CmdDecompressMemoryNV;
|
||||
PFN_vkCmdDecompressMemoryIndirectCountNV CmdDecompressMemoryIndirectCountNV;
|
||||
PFN_vkCmdSetTessellationDomainOriginEXT CmdSetTessellationDomainOriginEXT;
|
||||
PFN_vkCmdSetDepthClampEnableEXT CmdSetDepthClampEnableEXT;
|
||||
PFN_vkCmdSetPolygonModeEXT CmdSetPolygonModeEXT;
|
||||
PFN_vkCmdSetRasterizationSamplesEXT CmdSetRasterizationSamplesEXT;
|
||||
PFN_vkCmdSetSampleMaskEXT CmdSetSampleMaskEXT;
|
||||
PFN_vkCmdSetAlphaToCoverageEnableEXT CmdSetAlphaToCoverageEnableEXT;
|
||||
PFN_vkCmdSetAlphaToOneEnableEXT CmdSetAlphaToOneEnableEXT;
|
||||
PFN_vkCmdSetLogicOpEnableEXT CmdSetLogicOpEnableEXT;
|
||||
PFN_vkCmdSetColorBlendEnableEXT CmdSetColorBlendEnableEXT;
|
||||
PFN_vkCmdSetColorBlendEquationEXT CmdSetColorBlendEquationEXT;
|
||||
PFN_vkCmdSetColorWriteMaskEXT CmdSetColorWriteMaskEXT;
|
||||
PFN_vkCmdSetRasterizationStreamEXT CmdSetRasterizationStreamEXT;
|
||||
PFN_vkCmdSetConservativeRasterizationModeEXT CmdSetConservativeRasterizationModeEXT;
|
||||
PFN_vkCmdSetExtraPrimitiveOverestimationSizeEXT CmdSetExtraPrimitiveOverestimationSizeEXT;
|
||||
PFN_vkCmdSetDepthClipEnableEXT CmdSetDepthClipEnableEXT;
|
||||
PFN_vkCmdSetSampleLocationsEnableEXT CmdSetSampleLocationsEnableEXT;
|
||||
PFN_vkCmdSetColorBlendAdvancedEXT CmdSetColorBlendAdvancedEXT;
|
||||
PFN_vkCmdSetProvokingVertexModeEXT CmdSetProvokingVertexModeEXT;
|
||||
PFN_vkCmdSetLineRasterizationModeEXT CmdSetLineRasterizationModeEXT;
|
||||
PFN_vkCmdSetLineStippleEnableEXT CmdSetLineStippleEnableEXT;
|
||||
PFN_vkCmdSetDepthClipNegativeOneToOneEXT CmdSetDepthClipNegativeOneToOneEXT;
|
||||
PFN_vkCmdSetViewportWScalingEnableNV CmdSetViewportWScalingEnableNV;
|
||||
PFN_vkCmdSetViewportSwizzleNV CmdSetViewportSwizzleNV;
|
||||
PFN_vkCmdSetCoverageToColorEnableNV CmdSetCoverageToColorEnableNV;
|
||||
PFN_vkCmdSetCoverageToColorLocationNV CmdSetCoverageToColorLocationNV;
|
||||
PFN_vkCmdSetCoverageModulationModeNV CmdSetCoverageModulationModeNV;
|
||||
PFN_vkCmdSetCoverageModulationTableEnableNV CmdSetCoverageModulationTableEnableNV;
|
||||
PFN_vkCmdSetCoverageModulationTableNV CmdSetCoverageModulationTableNV;
|
||||
PFN_vkCmdSetShadingRateImageEnableNV CmdSetShadingRateImageEnableNV;
|
||||
PFN_vkCmdSetRepresentativeFragmentTestEnableNV CmdSetRepresentativeFragmentTestEnableNV;
|
||||
PFN_vkCmdSetCoverageReductionModeNV CmdSetCoverageReductionModeNV;
|
||||
PFN_vkGetShaderModuleIdentifierEXT GetShaderModuleIdentifierEXT;
|
||||
PFN_vkGetShaderModuleCreateInfoIdentifierEXT GetShaderModuleCreateInfoIdentifierEXT;
|
||||
PFN_vkCreateOpticalFlowSessionNV CreateOpticalFlowSessionNV;
|
||||
PFN_vkDestroyOpticalFlowSessionNV DestroyOpticalFlowSessionNV;
|
||||
PFN_vkBindOpticalFlowSessionImageNV BindOpticalFlowSessionImageNV;
|
||||
PFN_vkCmdOpticalFlowExecuteNV CmdOpticalFlowExecuteNV;
|
||||
PFN_vkCreateShadersEXT CreateShadersEXT;
|
||||
PFN_vkDestroyShaderEXT DestroyShaderEXT;
|
||||
PFN_vkGetShaderBinaryDataEXT GetShaderBinaryDataEXT;
|
||||
PFN_vkCmdBindShadersEXT CmdBindShadersEXT;
|
||||
PFN_vkGetFramebufferTilePropertiesQCOM GetFramebufferTilePropertiesQCOM;
|
||||
PFN_vkGetDynamicRenderingTilePropertiesQCOM GetDynamicRenderingTilePropertiesQCOM;
|
||||
PFN_vkCmdSetAttachmentFeedbackLoopEnableEXT CmdSetAttachmentFeedbackLoopEnableEXT;
|
||||
#ifdef VK_USE_PLATFORM_SCREEN_QNX
|
||||
PFN_vkGetScreenBufferPropertiesQNX GetScreenBufferPropertiesQNX;
|
||||
#endif //VK_USE_PLATFORM_SCREEN_QNX
|
||||
PFN_vkCreateAccelerationStructureKHR CreateAccelerationStructureKHR;
|
||||
PFN_vkDestroyAccelerationStructureKHR DestroyAccelerationStructureKHR;
|
||||
PFN_vkCmdBuildAccelerationStructuresKHR CmdBuildAccelerationStructuresKHR;
|
||||
PFN_vkCmdBuildAccelerationStructuresIndirectKHR CmdBuildAccelerationStructuresIndirectKHR;
|
||||
PFN_vkBuildAccelerationStructuresKHR BuildAccelerationStructuresKHR;
|
||||
PFN_vkCopyAccelerationStructureKHR CopyAccelerationStructureKHR;
|
||||
PFN_vkCopyAccelerationStructureToMemoryKHR CopyAccelerationStructureToMemoryKHR;
|
||||
PFN_vkCopyMemoryToAccelerationStructureKHR CopyMemoryToAccelerationStructureKHR;
|
||||
PFN_vkWriteAccelerationStructuresPropertiesKHR WriteAccelerationStructuresPropertiesKHR;
|
||||
PFN_vkCmdCopyAccelerationStructureKHR CmdCopyAccelerationStructureKHR;
|
||||
PFN_vkCmdCopyAccelerationStructureToMemoryKHR CmdCopyAccelerationStructureToMemoryKHR;
|
||||
PFN_vkCmdCopyMemoryToAccelerationStructureKHR CmdCopyMemoryToAccelerationStructureKHR;
|
||||
PFN_vkGetAccelerationStructureDeviceAddressKHR GetAccelerationStructureDeviceAddressKHR;
|
||||
PFN_vkCmdWriteAccelerationStructuresPropertiesKHR CmdWriteAccelerationStructuresPropertiesKHR;
|
||||
PFN_vkGetDeviceAccelerationStructureCompatibilityKHR GetDeviceAccelerationStructureCompatibilityKHR;
|
||||
PFN_vkGetAccelerationStructureBuildSizesKHR GetAccelerationStructureBuildSizesKHR;
|
||||
PFN_vkCmdTraceRaysKHR CmdTraceRaysKHR;
|
||||
PFN_vkCreateRayTracingPipelinesKHR CreateRayTracingPipelinesKHR;
|
||||
PFN_vkGetRayTracingCaptureReplayShaderGroupHandlesKHR GetRayTracingCaptureReplayShaderGroupHandlesKHR;
|
||||
PFN_vkCmdTraceRaysIndirectKHR CmdTraceRaysIndirectKHR;
|
||||
PFN_vkGetRayTracingShaderGroupStackSizeKHR GetRayTracingShaderGroupStackSizeKHR;
|
||||
PFN_vkCmdSetRayTracingPipelineStackSizeKHR CmdSetRayTracingPipelineStackSizeKHR;
|
||||
PFN_vkCmdDrawMeshTasksEXT CmdDrawMeshTasksEXT;
|
||||
PFN_vkCmdDrawMeshTasksIndirectEXT CmdDrawMeshTasksIndirectEXT;
|
||||
PFN_vkCmdDrawMeshTasksIndirectCountEXT CmdDrawMeshTasksIndirectCountEXT;
|
||||
} VkLayerDispatchTable;
|
||||
// NOLINTEND
|
110
scripts/generate_source.py
Normal file
110
scripts/generate_source.py
Normal file
|
@ -0,0 +1,110 @@
|
|||
#!/usr/bin/env python3
|
||||
# Copyright (c) 2023 Valve Corporation
|
||||
# Copyright (c) 2023 LunarG, Inc.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
import argparse
|
||||
import os
|
||||
import sys
|
||||
from xml.etree import ElementTree
|
||||
|
||||
def RunGenerators(api: str, registry: str, targetFilter: str) -> None:
|
||||
|
||||
# These live in the Vulkan-Docs repo, but are pulled in via the
|
||||
# Vulkan-Headers/registry folder
|
||||
# At runtime we inject python path to find these helper scripts
|
||||
scripts = os.path.dirname(registry)
|
||||
scripts_directory_path = os.path.dirname(os.path.abspath(__file__))
|
||||
registry_headers_path = os.path.join(scripts_directory_path, scripts)
|
||||
sys.path.insert(0, registry_headers_path)
|
||||
from reg import Registry
|
||||
|
||||
from generators.base_generator import BaseGeneratorOptions
|
||||
from generators.dispatch_table_helper_generator import DispatchTableHelperOutputGenerator
|
||||
from generators.layer_dispatch_table_generator import LayerDispatchTableOutputGenerator
|
||||
from generators.enum_string_helper_generator import EnumStringHelperOutputGenerator
|
||||
|
||||
# Build up a list of all generators and custom options
|
||||
generators = {
|
||||
'vk_dispatch_table_helper.h' : {
|
||||
'generator' : DispatchTableHelperOutputGenerator,
|
||||
'directory' : 'include/vulkan',
|
||||
},
|
||||
'vk_layer_dispatch_table.h' : {
|
||||
'generator' : LayerDispatchTableOutputGenerator,
|
||||
'directory' : 'include/vulkan',
|
||||
},
|
||||
'vk_enum_string_helper.h' : {
|
||||
'generator' : EnumStringHelperOutputGenerator,
|
||||
'directory' : 'include/vulkan',
|
||||
},
|
||||
}
|
||||
|
||||
if (targetFilter and targetFilter not in generators.keys()):
|
||||
print(f'ERROR: No generator options for unknown target: {targetFilter}', file=sys.stderr)
|
||||
sys.exit(1)
|
||||
|
||||
# Filter if --target is passed in
|
||||
targets = [x for x in generators.keys() if not targetFilter or x == targetFilter]
|
||||
|
||||
for index, target in enumerate(targets, start=1):
|
||||
print(f'[{index}|{len(targets)}] Generating {target}')
|
||||
|
||||
# First grab a class contructor object and create an instance
|
||||
generator = generators[target]['generator']
|
||||
gen = generator()
|
||||
|
||||
outDirectory = os.path.abspath(os.path.join(os.path.dirname(__file__), '..', generators[target]['directory']))
|
||||
options = BaseGeneratorOptions(
|
||||
customFileName = target,
|
||||
customDirectory = outDirectory,
|
||||
customApiName = 'vulkan')
|
||||
|
||||
# Create the registry object with the specified generator and generator
|
||||
# options. The options are set before XML loading as they may affect it.
|
||||
reg = Registry(gen, options)
|
||||
|
||||
# Parse the specified registry XML into an ElementTree object
|
||||
tree = ElementTree.parse(registry)
|
||||
|
||||
# Filter out non-Vulkan extensions
|
||||
if api == 'vulkan':
|
||||
[exts.remove(e) for exts in tree.findall('extensions') for e in exts.findall('extension') if (sup := e.get('supported')) is not None and options.apiname not in sup.split(',')]
|
||||
|
||||
# Load the XML tree into the registry object
|
||||
reg.loadElementTree(tree)
|
||||
|
||||
# Finally, use the output generator to create the requested target
|
||||
reg.apiGen()
|
||||
|
||||
|
||||
def main(argv):
|
||||
parser = argparse.ArgumentParser(description='Generate source code for this repository')
|
||||
parser.add_argument('--api',
|
||||
default='vulkan',
|
||||
choices=['vulkan'],
|
||||
help='Specify API name to generate')
|
||||
parser.add_argument('registry', metavar='REGISTRY_PATH', help='path to the Vulkan-Headers registry directory')
|
||||
group = parser.add_mutually_exclusive_group()
|
||||
group.add_argument('--target', help='only generate file name passed in')
|
||||
args = parser.parse_args(argv)
|
||||
|
||||
registry = os.path.abspath(os.path.join(args.registry, 'vk.xml'))
|
||||
RunGenerators(args.api, registry, args.target)
|
||||
|
||||
return 0
|
||||
|
||||
if __name__ == '__main__':
|
||||
sys.exit(main(sys.argv[1:]))
|
||||
|
691
scripts/generators/base_generator.py
Normal file
691
scripts/generators/base_generator.py
Normal file
|
@ -0,0 +1,691 @@
|
|||
#!/usr/bin/python3 -i
|
||||
#
|
||||
# Copyright (c) 2023 Valve Corporation
|
||||
# Copyright (c) 2023 LunarG, Inc.
|
||||
# Copyright (c) 2023 RasterGrid Kft.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
from generators.vulkan_object import (VulkanObject,
|
||||
Extension, Version, Handle, Param, Queues, CommandScope, Command,
|
||||
EnumField, Enum, Flag, Bitmask, Member, Struct,
|
||||
FormatComponent, FormatPlane, Format,
|
||||
SyncSupport, SyncEquivalent, SyncStage, SyncAccess, SyncPipelineStage, SyncPipeline,
|
||||
SpirvEnables, Spirv)
|
||||
|
||||
# These live in the Vulkan-Docs repo, but are pulled in via the
|
||||
# Vulkan-Headers/registry folder
|
||||
from generator import OutputGenerator, GeneratorOptions, write
|
||||
from vkconventions import VulkanConventions
|
||||
|
||||
# An API style convention object
|
||||
vulkanConventions = VulkanConventions()
|
||||
|
||||
# Helpers to keep things cleaner
|
||||
def splitIfGet(elem, name):
|
||||
return elem.get(name).split(',') if elem.get(name) is not None else None
|
||||
|
||||
def textIfFind(elem, name):
|
||||
return elem.find(name).text if elem.find(name) is not None else None
|
||||
|
||||
def intIfGet(elem, name):
|
||||
return None if elem.get(name) is None else int(elem.get(name), 0)
|
||||
|
||||
def boolGet(elem, name) -> bool:
|
||||
return elem.get(name) is not None and elem.get(name) == "true"
|
||||
|
||||
def getQueues(elem) -> Queues:
|
||||
queues = 0
|
||||
queues_list = splitIfGet(elem, 'queues')
|
||||
if queues_list is not None:
|
||||
queues |= Queues.TRANSFER if 'transfer' in queues_list else 0
|
||||
queues |= Queues.GRAPHICS if 'graphics' in queues_list else 0
|
||||
queues |= Queues.COMPUTE if 'compute' in queues_list else 0
|
||||
queues |= Queues.PROTECTED if 'protected' in queues_list else 0
|
||||
queues |= Queues.SPARSE_BINDING if 'sparse_binding' in queues_list else 0
|
||||
queues |= Queues.OPTICAL_FLOW if 'opticalflow' in queues_list else 0
|
||||
queues |= Queues.DECODE if 'decode' in queues_list else 0
|
||||
queues |= Queues.ENCODE if 'encode' in queues_list else 0
|
||||
return queues
|
||||
|
||||
# Shared object used by Sync elements that don't have ones
|
||||
maxSyncSupport = SyncSupport(None, None, True)
|
||||
maxSyncEquivalent = SyncEquivalent(None, None, True)
|
||||
|
||||
# Helpers to set GeneratorOptions options globally
|
||||
def SetOutputFileName(fileName: str) -> None:
|
||||
global globalFileName
|
||||
globalFileName = fileName
|
||||
|
||||
def SetOutputDirectory(directory: str) -> None:
|
||||
global globalDirectory
|
||||
globalDirectory = directory
|
||||
|
||||
def SetTargetApiName(apiname: str) -> None:
|
||||
global globalApiName
|
||||
globalApiName = apiname
|
||||
|
||||
# This Generator Option is used across all generators.
|
||||
# After years of use, it has shown that most the options are unified across each generator (file)
|
||||
# as it is easier to modifiy things per-file that need the difference
|
||||
class BaseGeneratorOptions(GeneratorOptions):
|
||||
def __init__(self,
|
||||
customFileName = None,
|
||||
customDirectory = None,
|
||||
customApiName = None):
|
||||
GeneratorOptions.__init__(self,
|
||||
conventions = vulkanConventions,
|
||||
filename = customFileName if customFileName else globalFileName,
|
||||
directory = customDirectory if customDirectory else globalDirectory,
|
||||
apiname = customApiName if customApiName else globalApiName,
|
||||
mergeApiNames = None,
|
||||
defaultExtensions = customApiName if customApiName else globalApiName,
|
||||
emitExtensions = '.*',
|
||||
emitSpirv = '.*',
|
||||
emitFormats = '.*')
|
||||
# These are used by the generator.py script
|
||||
self.apicall = 'VKAPI_ATTR '
|
||||
self.apientry = 'VKAPI_CALL '
|
||||
self.apientryp = 'VKAPI_PTR *'
|
||||
self.alignFuncParam = 48
|
||||
|
||||
#
|
||||
# This object handles all the parsing from reg.py generator scripts in the Vulkan-Headers
|
||||
# It will grab all the data and form it into a single object the rest of the generators will use
|
||||
class BaseGenerator(OutputGenerator):
|
||||
def __init__(self):
|
||||
OutputGenerator.__init__(self, None, None, None)
|
||||
self.vk = VulkanObject()
|
||||
|
||||
# reg.py has a `self.featureName` but this is nicer because
|
||||
# it will be either the Version or Extension object
|
||||
self.currentExtension = None
|
||||
self.currentVersion = None
|
||||
|
||||
# Will map alias to promoted name
|
||||
# ex. ['VK_FILTER_CUBIC_IMG' : 'VK_FILTER_CUBIC_EXT']
|
||||
# When generating any code, there is no reason so use the old name
|
||||
self.enumAliasMap = dict()
|
||||
self.enumFieldAliasMap = dict()
|
||||
self.bitmaskAliasMap = dict()
|
||||
self.flagAliasMap = dict()
|
||||
|
||||
def write(self, data):
|
||||
# Prevents having to check before writting
|
||||
if data is not None and data != "":
|
||||
write(data, file=self.outFile)
|
||||
|
||||
|
||||
def beginFile(self, genOpts):
|
||||
OutputGenerator.beginFile(self, genOpts)
|
||||
self.filename = genOpts.filename
|
||||
|
||||
# No gen*() command to get these, so do it manually
|
||||
for platform in self.registry.tree.findall('platforms/platform'):
|
||||
self.vk.platforms[platform.get('name')] = platform.get('protect')
|
||||
|
||||
for tag in self.registry.tree.findall('tags'):
|
||||
self.vk.vendorTags.append(tag.get('name'))
|
||||
|
||||
# No way known to get this from the XML
|
||||
self.vk.queueBits[Queues.TRANSFER] = 'VK_QUEUE_TRANSFER_BIT'
|
||||
self.vk.queueBits[Queues.GRAPHICS] = 'VK_QUEUE_GRAPHICS_BIT'
|
||||
self.vk.queueBits[Queues.COMPUTE] = 'VK_QUEUE_COMPUTE_BIT'
|
||||
self.vk.queueBits[Queues.PROTECTED] = 'VK_QUEUE_PROTECTED_BIT'
|
||||
self.vk.queueBits[Queues.SPARSE_BINDING] = 'VK_QUEUE_SPARSE_BINDING_BIT'
|
||||
self.vk.queueBits[Queues.OPTICAL_FLOW] = 'VK_QUEUE_OPTICAL_FLOW_BIT_NV'
|
||||
self.vk.queueBits[Queues.DECODE] = 'VK_QUEUE_VIDEO_DECODE_BIT_KHR'
|
||||
self.vk.queueBits[Queues.ENCODE] = 'VK_QUEUE_VIDEO_ENCODE_BIT_KHR'
|
||||
|
||||
# This function should be overloaded
|
||||
def generate(self):
|
||||
print("WARNING: This should not be called from the child class")
|
||||
return
|
||||
|
||||
# This function is dense, it does all the magic to set the right extensions dependencies!
|
||||
#
|
||||
# The issue is if 2 extension expose a command, genCmd() will only
|
||||
# show one of the extension, at endFile() we can finally go through
|
||||
# and update which things depend on which extensions
|
||||
#
|
||||
# self.featureDictionary is built for use in the reg.py framework
|
||||
# Details found in Vulkan-Docs/scripts/scriptgenerator.py
|
||||
def applyExtensionDependency(self):
|
||||
for extension in self.vk.extensions.values():
|
||||
# dict.key() can be None, so need to double loop
|
||||
dict = self.featureDictionary[extension.name]['command']
|
||||
|
||||
# "required" == None
|
||||
# or
|
||||
# an additional feature dependency, which is a boolean expression of
|
||||
# one or more extension and/or core version names
|
||||
for required in dict:
|
||||
for commandName in dict[required]:
|
||||
command = self.vk.commands[commandName]
|
||||
# Make sure list is unique
|
||||
command.extensions.extend([extension] if extension not in command.extensions else [])
|
||||
extension.commands.extend([command] if command not in extension.commands else [])
|
||||
|
||||
# While genGroup() will call twice with aliased value, it doesn't provide all the information we need
|
||||
dict = self.featureDictionary[extension.name]['enumconstant']
|
||||
for required in dict:
|
||||
# group can be a Enum or Bitmask
|
||||
for group in dict[required]:
|
||||
if group in self.vk.enums:
|
||||
if group not in extension.enumFields:
|
||||
extension.enumFields[group] = [] # Dict needs init
|
||||
enum = self.vk.enums[group]
|
||||
# Need to convert all alias so they match what is in EnumField
|
||||
enumList = list(map(lambda x: x if x not in self.enumFieldAliasMap else self.enumFieldAliasMap[x], dict[required][group]))
|
||||
|
||||
for enumField in [x for x in enum.fields if x.name in enumList]:
|
||||
# Make sure list is unique
|
||||
enum.fieldExtensions.extend([extension] if extension not in enum.fieldExtensions else [])
|
||||
enumField.extensions.extend([extension] if extension not in enumField.extensions else [])
|
||||
extension.enumFields[group].extend([enumField] if enumField not in extension.enumFields[group] else [])
|
||||
|
||||
if group in self.vk.bitmasks:
|
||||
if group not in extension.flags:
|
||||
extension.flags[group] = [] # Dict needs init
|
||||
bitmask = self.vk.bitmasks[group]
|
||||
# Need to convert all alias so they match what is in Flags
|
||||
flagList = list(map(lambda x: x if x not in self.flagAliasMap else self.flagAliasMap[x], dict[required][group]))
|
||||
|
||||
for flags in [x for x in bitmask.flags if x.name in flagList]:
|
||||
# Make sure list is unique
|
||||
bitmask.extensions.extend([extension] if extension not in bitmask.extensions else [])
|
||||
flags.extensions.extend([extension] if extension not in flags.extensions else [])
|
||||
extension.flags[group].extend([flags] if flags not in extension.flags[group] else [])
|
||||
|
||||
|
||||
# Need to do 'enum'/'bitmask' after 'enumconstant' has applied everything so we can add implicit extensions
|
||||
#
|
||||
# Sometimes two extensions enable an Enum, but the newer extension version has extra flags allowed
|
||||
# This information seems to be implicit, so need to update it here
|
||||
# Go through each Flag and append the Enum extension to it
|
||||
#
|
||||
# ex. VkAccelerationStructureTypeKHR where GENERIC_KHR is not allowed with just VK_NV_ray_tracing
|
||||
# This only works because the values are aliased as well, making the KHR a superset enum
|
||||
for extension in self.vk.extensions.values():
|
||||
dict = self.featureDictionary[extension.name]['enum']
|
||||
for required in dict:
|
||||
for group in dict[required]:
|
||||
for enumName in dict[required][group]:
|
||||
isAlias = enumName in self.enumAliasMap
|
||||
enumName = self.enumAliasMap[enumName] if isAlias else enumName
|
||||
if enumName in self.vk.enums:
|
||||
enum = self.vk.enums[enumName]
|
||||
enum.extensions.extend([extension] if extension not in enum.extensions else [])
|
||||
extension.enums.extend([enum] if enum not in extension.enums else [])
|
||||
# Update fields with implicit base extension
|
||||
if isAlias:
|
||||
continue
|
||||
enum.fieldExtensions.extend([extension] if extension not in enum.fieldExtensions else [])
|
||||
for enumField in [x for x in enum.fields if (not x.extensions or (x.extensions and all(e in enum.extensions for e in x.extensions)))]:
|
||||
enumField.extensions.extend([extension] if extension not in enumField.extensions else [])
|
||||
if enumName not in extension.enumFields:
|
||||
extension.enumFields[enumName] = [] # Dict needs init
|
||||
extension.enumFields[enumName].extend([enumField] if enumField not in extension.enumFields[enumName] else [])
|
||||
|
||||
dict = self.featureDictionary[extension.name]['bitmask']
|
||||
for required in dict:
|
||||
for group in dict[required]:
|
||||
for bitmaskName in dict[required][group]:
|
||||
isAlias = bitmaskName in self.enumAliasMap
|
||||
bitmaskName = self.bitmaskAliasMap[bitmaskName] if isAlias else bitmaskName
|
||||
if bitmaskName in self.vk.bitmasks:
|
||||
bitmask = self.vk.bitmasks[bitmaskName]
|
||||
bitmask.extensions.extend([extension] if extension not in bitmask.extensions else [])
|
||||
extension.bitmask.extend([bitmask] if bitmask not in extension.bitmasks else [])
|
||||
# Update flags with implicit base extension
|
||||
if isAlias:
|
||||
continue
|
||||
bitmask.flagExtensions.extend([extension] if extension not in enum.flagExtensions else [])
|
||||
for flag in [x for x in enum.flags if (not x.extensions or (x.extensions and all(e in enum.extensions for e in x.extensions)))]:
|
||||
flag.extensions.extend([extension] if extension not in flag.extensions else [])
|
||||
if bitmaskName not in extension.flags:
|
||||
extension.flags[bitmaskName] = [] # Dict needs init
|
||||
extension.flags[bitmaskName].extend([flag] if flag not in extension.flags[bitmaskName] else [])
|
||||
|
||||
def endFile(self):
|
||||
# This is the point were reg.py has ran, everything is collected
|
||||
# We do some post processing now
|
||||
self.applyExtensionDependency()
|
||||
|
||||
# Use structs and commands to find which things are returnedOnly
|
||||
for struct in [x for x in self.vk.structs.values() if not x.returnedOnly]:
|
||||
for enum in [self.vk.enums[x.type] for x in struct.members if x.type in self.vk.enums]:
|
||||
enum.returnedOnly = False
|
||||
for command in self.vk.commands.values():
|
||||
for enum in [self.vk.enums[x.type] for x in command.params if x.type in self.vk.enums]:
|
||||
enum.returnedOnly = False
|
||||
|
||||
# Turn handle parents into pointers to classess
|
||||
for handle in [x for x in self.vk.handles.values() if x.parent is not None]:
|
||||
handle.parent = self.vk.handles[handle.parent]
|
||||
|
||||
maxSyncSupport.queues = Queues.ALL
|
||||
maxSyncSupport.stages = self.vk.bitmasks['VkPipelineStageFlagBits2'].flags
|
||||
maxSyncEquivalent.accesses = self.vk.bitmasks['VkAccessFlagBits2'].flags
|
||||
maxSyncEquivalent.stages = self.vk.bitmasks['VkPipelineStageFlagBits2'].flags
|
||||
|
||||
# All inherited generators should run from here
|
||||
self.generate()
|
||||
|
||||
# This should not have to do anything but call into OutputGenerator
|
||||
OutputGenerator.endFile(self)
|
||||
|
||||
#
|
||||
# Processing point at beginning of each extension definition
|
||||
def beginFeature(self, interface, emit):
|
||||
OutputGenerator.beginFeature(self, interface, emit)
|
||||
platform = interface.get('platform')
|
||||
self.featureExtraProtec = self.vk.platforms[platform] if platform in self.vk.platforms else None
|
||||
protect = self.vk.platforms[platform] if platform in self.vk.platforms else None
|
||||
|
||||
name = interface.get('name')
|
||||
|
||||
if interface.tag == 'extension':
|
||||
instance = interface.get('type') == 'instance'
|
||||
device = not instance
|
||||
depends = interface.get('depends')
|
||||
vendorTag = interface.get('author')
|
||||
platform = interface.get('platform')
|
||||
provisional = boolGet(interface, 'provisional')
|
||||
promotedto = interface.get('promotedto')
|
||||
deprecatedby = interface.get('deprecatedby')
|
||||
obsoletedby = interface.get('obsoletedby')
|
||||
specialuse = splitIfGet(interface, 'specialuse')
|
||||
# Not sure if better way to get this info
|
||||
nameString = self.featureDictionary[name]['enumconstant'][None][None][1]
|
||||
|
||||
self.currentExtension = Extension(name, nameString, instance, device, depends, vendorTag,
|
||||
platform, protect, provisional, promotedto, deprecatedby,
|
||||
obsoletedby, specialuse)
|
||||
self.vk.extensions[name] = self.currentExtension
|
||||
else: # version
|
||||
number = interface.get('number')
|
||||
if number != '1.0':
|
||||
nameApi = name.replace('VK_', 'VK_API_')
|
||||
nameString = f'"{name}"'
|
||||
self.currentVersion = Version(name, nameString, nameApi, number)
|
||||
self.vk.versions[name] = self.currentVersion
|
||||
|
||||
def endFeature(self):
|
||||
OutputGenerator.endFeature(self)
|
||||
self.currentExtension = None
|
||||
self.currentVersion = None
|
||||
|
||||
#
|
||||
# All <command> from XML
|
||||
def genCmd(self, cmdinfo, name, alias):
|
||||
OutputGenerator.genCmd(self, cmdinfo, name, alias)
|
||||
|
||||
params = []
|
||||
for param in cmdinfo.elem.findall('param'):
|
||||
paramName = param.find('name').text
|
||||
paramType = textIfFind(param, 'type')
|
||||
paramAlias = param.get('alias')
|
||||
|
||||
cdecl = self.makeCParamDecl(param, 0)
|
||||
pointer = '*' in cdecl or paramType.startswith('PFN_')
|
||||
paramConst = 'const' in cdecl
|
||||
fixedSizeArray = [x[:-1] for x in cdecl.split('[') if x.endswith(']')]
|
||||
|
||||
paramNoautovalidity = boolGet(param, 'noautovalidity')
|
||||
|
||||
nullTerminated = False
|
||||
length = param.get('altlen') if param.get('altlen') is not None else param.get('len')
|
||||
if length:
|
||||
# we will either find it like "null-terminated" or "enabledExtensionCount,null-terminated"
|
||||
# This finds both
|
||||
nullTerminated = 'null-terminated' in length
|
||||
length = length.replace(',null-terminated', '') if 'null-terminated' in length else length
|
||||
length = None if length == 'null-terminated' else length
|
||||
|
||||
if fixedSizeArray and not length:
|
||||
length = ','.join(fixedSizeArray)
|
||||
|
||||
# See Member::optional code for details of this
|
||||
optionalValues = splitIfGet(param, 'optional')
|
||||
optional = optionalValues is not None and optionalValues[0].lower() == "true"
|
||||
optionalPointer = optionalValues is not None and len(optionalValues) > 1 and optionalValues[1].lower() == "true"
|
||||
|
||||
# externsync will be 'true' or expression
|
||||
# if expression, it should be same as 'true'
|
||||
externSync = boolGet(param, 'externsync')
|
||||
externSyncPointer = None if externSync else splitIfGet(param, 'externsync')
|
||||
if not externSync and externSyncPointer is not None:
|
||||
externSync = True
|
||||
|
||||
params.append(Param(paramName, paramAlias, paramType, paramNoautovalidity,
|
||||
paramConst, length, nullTerminated, pointer, fixedSizeArray,
|
||||
optional, optionalPointer,
|
||||
externSync, externSyncPointer, cdecl))
|
||||
|
||||
attrib = cmdinfo.elem.attrib
|
||||
alias = attrib.get('alias')
|
||||
tasks = splitIfGet(attrib, 'tasks')
|
||||
|
||||
queues = getQueues(attrib)
|
||||
successcodes = splitIfGet(attrib, 'successcodes')
|
||||
errorcodes = splitIfGet(attrib, 'errorcodes')
|
||||
cmdbufferlevel = attrib.get('cmdbufferlevel')
|
||||
primary = cmdbufferlevel is not None and 'primary' in cmdbufferlevel
|
||||
secondary = cmdbufferlevel is not None and 'secondary' in cmdbufferlevel
|
||||
|
||||
renderpass = attrib.get('renderpass')
|
||||
renderpass = CommandScope.NONE if renderpass is None else getattr(CommandScope, renderpass.upper())
|
||||
videocoding = attrib.get('videocoding')
|
||||
videocoding = CommandScope.NONE if videocoding is None else getattr(CommandScope, videocoding.upper())
|
||||
|
||||
protoElem = cmdinfo.elem.find('proto')
|
||||
returnType = textIfFind(protoElem, 'type')
|
||||
|
||||
decls = self.makeCDecls(cmdinfo.elem)
|
||||
cPrototype = decls[0]
|
||||
cFunctionPointer = decls[1]
|
||||
|
||||
protect = self.currentExtension.protect if self.currentExtension is not None else None
|
||||
|
||||
# These coammds have no way from the XML to detect they would be an instance command
|
||||
specialInstanceCommand = ['vkCreateInstance', 'vkEnumerateInstanceExtensionProperties','vkEnumerateInstanceLayerProperties', 'vkEnumerateInstanceVersion']
|
||||
instance = len(params) > 0 and (params[0].type == 'VkInstance' or params[0].type == 'VkPhysicalDevice' or name in specialInstanceCommand)
|
||||
device = not instance
|
||||
|
||||
implicitElem = cmdinfo.elem.find('implicitexternsyncparams')
|
||||
implicitExternSyncParams = [x.text for x in implicitElem.findall('param')] if implicitElem else []
|
||||
|
||||
self.vk.commands[name] = Command(name, alias, protect, [], self.currentVersion,
|
||||
returnType, params, instance, device,
|
||||
tasks, queues, successcodes, errorcodes,
|
||||
primary, secondary, renderpass, videocoding,
|
||||
implicitExternSyncParams, cPrototype, cFunctionPointer)
|
||||
|
||||
#
|
||||
# List the enum for the commands
|
||||
# TODO - Seems empty groups like `VkDeviceDeviceMemoryReportCreateInfoEXT` don't show up in here
|
||||
def genGroup(self, groupinfo, groupName, alias):
|
||||
# There can be case where the Enum/Bitmask is in a protect, but the individual
|
||||
# fields also have their own protect
|
||||
groupProtect = self.currentExtension.protect if hasattr(self.currentExtension, 'protect') and self.currentExtension.protect is not None else None
|
||||
enumElem = groupinfo.elem
|
||||
bitwidth = 32 if enumElem.get('bitwidth') is None else enumElem.get('bitwidth')
|
||||
fields = []
|
||||
if enumElem.get('type') == "enum":
|
||||
if alias is not None:
|
||||
self.enumAliasMap[groupName] = alias
|
||||
return
|
||||
|
||||
for elem in enumElem.findall('enum'):
|
||||
fieldName = elem.get('name')
|
||||
|
||||
if elem.get('alias') is not None:
|
||||
self.enumFieldAliasMap[fieldName] = elem.get('alias')
|
||||
continue
|
||||
|
||||
negative = elem.get('dir') is not None
|
||||
protect = elem.get('protect')
|
||||
|
||||
# Some values have multiple extensions (ex VK_DESCRIPTOR_UPDATE_TEMPLATE_TYPE_PUSH_DESCRIPTORS_KHR)
|
||||
# genGroup() lists them twice
|
||||
if next((x for x in fields if x.name == fieldName), None) is None:
|
||||
fields.append(EnumField(fieldName, negative, protect, []))
|
||||
|
||||
self.vk.enums[groupName] = Enum(groupName, groupProtect, bitwidth, True, fields, [], [])
|
||||
|
||||
else: # "bitmask"
|
||||
if alias is not None:
|
||||
self.bitmaskAliasMap[groupName] = alias
|
||||
return
|
||||
|
||||
for elem in enumElem.findall('enum'):
|
||||
flagName = elem.get('name')
|
||||
|
||||
if elem.get('alias') is not None:
|
||||
self.flagAliasMap[flagName] = elem.get('alias')
|
||||
continue
|
||||
|
||||
flagMultiBit = False
|
||||
flagZero = False
|
||||
flagValue = intIfGet(elem, 'bitpos')
|
||||
if flagValue is None:
|
||||
flagValue = intIfGet(elem, 'value')
|
||||
flagMultiBit = flagValue != 0
|
||||
flagZero = flagValue == 0
|
||||
protect = elem.get('protect')
|
||||
|
||||
# Some values have multiple extensions (ex VK_TOOL_PURPOSE_DEBUG_REPORTING_BIT_EXT)
|
||||
# genGroup() lists them twice
|
||||
if next((x for x in fields if x.name == flagName), None) is None:
|
||||
fields.append(Flag(flagName, protect, flagValue, flagMultiBit, flagZero, []))
|
||||
|
||||
flagName = groupName.replace('FlagBits', 'Flags')
|
||||
self.vk.bitmasks[groupName] = Bitmask(groupName, flagName, groupProtect, bitwidth, fields, [], [])
|
||||
|
||||
def genType(self, typeInfo, typeName, alias):
|
||||
OutputGenerator.genType(self, typeInfo, typeName, alias)
|
||||
typeElem = typeInfo.elem
|
||||
protect = self.currentExtension.protect if hasattr(self.currentExtension, 'protect') and self.currentExtension.protect is not None else None
|
||||
category = typeElem.get('category')
|
||||
if (category == 'struct' or category == 'union'):
|
||||
extension = [self.currentExtension] if self.currentExtension is not None else []
|
||||
if alias is not None:
|
||||
struct = self.vk.structs[alias]
|
||||
# Some structs (ex VkAttachmentSampleCountInfoAMD) can have multiple alias pointing to same extension
|
||||
struct.extensions += extension if extension and extension[0] not in struct.extensions else []
|
||||
struct.version = self.currentVersion if struct.version is None else struct.version
|
||||
return
|
||||
|
||||
union = category == 'union'
|
||||
|
||||
returnedOnly = boolGet(typeElem, 'returnedonly')
|
||||
allowDuplicate = boolGet(typeElem, 'allowduplicate')
|
||||
|
||||
extends = splitIfGet(typeElem, 'structextends')
|
||||
extendedBy = self.registry.validextensionstructs[typeName] if len(self.registry.validextensionstructs[typeName]) > 0 else None
|
||||
|
||||
membersElem = typeInfo.elem.findall('.//member')
|
||||
members = []
|
||||
sType = None
|
||||
|
||||
for member in membersElem:
|
||||
for comment in member.findall('comment'):
|
||||
member.remove(comment)
|
||||
|
||||
name = textIfFind(member, 'name')
|
||||
type = textIfFind(member, 'type')
|
||||
sType = member.get('values') if member.get('values') is not None else sType
|
||||
externSync = boolGet(member, 'externsync')
|
||||
noautovalidity = boolGet(member, 'noautovalidity')
|
||||
limittype = member.get('limittype')
|
||||
|
||||
nullTerminated = False
|
||||
length = member.get('altlen') if member.get('altlen') is not None else member.get('len')
|
||||
if length:
|
||||
# we will either find it like "null-terminated" or "enabledExtensionCount,null-terminated"
|
||||
# This finds both
|
||||
nullTerminated = 'null-terminated' in length
|
||||
length = length.replace(',null-terminated', '') if 'null-terminated' in length else length
|
||||
length = None if length == 'null-terminated' else length
|
||||
|
||||
cdecl = self.makeCParamDecl(member, 0)
|
||||
pointer = '*' in cdecl or type.startswith('PFN_')
|
||||
const = 'const' in cdecl
|
||||
# Some structs like VkTransformMatrixKHR have a 2D array
|
||||
fixedSizeArray = [x[:-1] for x in cdecl.split('[') if x.endswith(']')]
|
||||
|
||||
if fixedSizeArray and not length:
|
||||
length = ','.join(fixedSizeArray)
|
||||
|
||||
# if a pointer, this can be a something like:
|
||||
# optional="true,false" for ppGeometries
|
||||
# optional="false,true" for pPhysicalDeviceCount
|
||||
# the first is if the variable itself is optional
|
||||
# the second is the value of the pointer is optiona;
|
||||
optionalValues = splitIfGet(member, 'optional')
|
||||
optional = optionalValues is not None and optionalValues[0].lower() == "true"
|
||||
optionalPointer = optionalValues is not None and len(optionalValues) > 1 and optionalValues[1].lower() == "true"
|
||||
|
||||
members.append(Member(name, type, noautovalidity, limittype,
|
||||
const, length, nullTerminated, pointer, fixedSizeArray,
|
||||
optional, optionalPointer,
|
||||
externSync, cdecl))
|
||||
|
||||
self.vk.structs[typeName] = Struct(typeName, extension, self.currentVersion, protect, members,
|
||||
union, returnedOnly, sType, allowDuplicate, extends, extendedBy)
|
||||
|
||||
elif category == 'handle':
|
||||
if alias is not None:
|
||||
return
|
||||
type = typeElem.get('objtypeenum')
|
||||
parent = typeElem.get('parent') # will resolve later
|
||||
instance = parent == 'VkInstance'
|
||||
device = not instance
|
||||
dispatchable = typeElem.find('type').text == 'VK_DEFINE_HANDLE'
|
||||
|
||||
self.vk.handles[typeName] = Handle(typeName, type, protect, parent, instance, device, dispatchable)
|
||||
|
||||
elif category == 'define':
|
||||
if typeName == 'VK_HEADER_VERSION':
|
||||
self.vk.headerVersion = typeElem.find('name').tail.strip()
|
||||
|
||||
else:
|
||||
# not all categories are used
|
||||
# 'group'/'enum'/'bitmask' are routed to genGroup instead
|
||||
# 'basetype'/'include' are only for headers
|
||||
# 'funcpointer` ingore until needed
|
||||
return
|
||||
|
||||
def genSpirv(self, spirvinfo, spirvName, alias):
|
||||
OutputGenerator.genSpirv(self, spirvinfo, spirvName, alias)
|
||||
spirvElem = spirvinfo.elem
|
||||
name = spirvElem.get('name')
|
||||
extension = True if spirvElem.tag == 'spirvextension' else False
|
||||
capability = not extension
|
||||
|
||||
enables = []
|
||||
for elem in spirvElem:
|
||||
version = elem.attrib.get('version')
|
||||
extensionEnable = elem.attrib.get('extension')
|
||||
struct = elem.attrib.get('struct')
|
||||
feature = elem.attrib.get('feature')
|
||||
requires = elem.attrib.get('requires')
|
||||
propertyEnable = elem.attrib.get('property')
|
||||
member = elem.attrib.get('member')
|
||||
value = elem.attrib.get('value')
|
||||
enables.append(SpirvEnables(version, extensionEnable, struct, feature,
|
||||
requires, propertyEnable, member, value))
|
||||
|
||||
self.vk.spirv.append(Spirv(name, extension, capability, enables))
|
||||
|
||||
def genFormat(self, format, formatinfo, alias):
|
||||
OutputGenerator.genFormat(self, format, formatinfo, alias)
|
||||
formatElem = format.elem
|
||||
name = formatElem.get('name')
|
||||
|
||||
components = []
|
||||
for component in formatElem.iterfind('component'):
|
||||
type = component.get('name')
|
||||
bits = component.get('bits')
|
||||
numericFormat = component.get('numericFormat')
|
||||
planeIndex = intIfGet(component, 'planeIndex')
|
||||
components.append(FormatComponent(type, bits, numericFormat, planeIndex))
|
||||
|
||||
planes = []
|
||||
for plane in formatElem.iterfind('plane'):
|
||||
index = int(plane.get('index'))
|
||||
widthDivisor = int(plane.get('widthDivisor'))
|
||||
heightDivisor = int(plane.get('heightDivisor'))
|
||||
compatible = plane.get('compatible')
|
||||
planes.append(FormatPlane(index, widthDivisor, heightDivisor, compatible))
|
||||
|
||||
className = formatElem.get('class')
|
||||
blockSize = int(formatElem.get('blockSize'))
|
||||
texelsPerBlock = int(formatElem.get('texelsPerBlock'))
|
||||
blockExtent = splitIfGet(formatElem, 'blockExtent')
|
||||
packed = intIfGet(formatElem, 'packed')
|
||||
chroma = formatElem.get('chroma')
|
||||
compressed = formatElem.get('compressed')
|
||||
spirvImageFormat = formatElem.find('spirvimageformat')
|
||||
if spirvImageFormat is not None:
|
||||
spirvImageFormat = spirvImageFormat.get('name')
|
||||
|
||||
self.vk.formats[name] = Format(name, className, blockSize, texelsPerBlock,
|
||||
blockExtent, packed, chroma, compressed,
|
||||
components, planes, spirvImageFormat)
|
||||
|
||||
def genSyncStage(self, sync):
|
||||
OutputGenerator.genSyncStage(self, sync)
|
||||
syncElem = sync.elem
|
||||
|
||||
support = maxSyncSupport
|
||||
supportElem = syncElem.find('syncsupport')
|
||||
if supportElem is not None:
|
||||
queues = getQueues(supportElem)
|
||||
stageNames = splitIfGet(supportElem, 'stage')
|
||||
stages = [x for x in self.vk.bitmasks['VkPipelineStageFlagBits2'].flags if x.name in stageNames] if stageNames is not None else None
|
||||
support = SyncSupport(queues, stages, False)
|
||||
|
||||
equivalent = maxSyncEquivalent
|
||||
equivalentElem = syncElem.find('syncequivalent')
|
||||
if equivalentElem is not None:
|
||||
stageNames = splitIfGet(equivalentElem, 'stage')
|
||||
stages = [x for x in self.vk.bitmasks['VkPipelineStageFlagBits2'].flags if x.name in stageNames] if stageNames is not None else None
|
||||
accessNames = splitIfGet(equivalentElem, 'access')
|
||||
accesses = [x for x in self.vk.bitmasks['VkAccessFlagBits2'].flags if x.name in accessNames] if accessNames is not None else None
|
||||
equivalent = SyncEquivalent(stages, accesses, False)
|
||||
|
||||
flagName = syncElem.get('name')
|
||||
flag = [x for x in self.vk.bitmasks['VkPipelineStageFlagBits2'].flags if x.name == flagName][0]
|
||||
self.vk.syncStage.append(SyncStage(flag, support, equivalent))
|
||||
|
||||
def genSyncAccess(self, sync):
|
||||
OutputGenerator.genSyncAccess(self, sync)
|
||||
syncElem = sync.elem
|
||||
|
||||
support = maxSyncSupport
|
||||
supportElem = syncElem.find('syncsupport')
|
||||
if supportElem is not None:
|
||||
queues = getQueues(supportElem)
|
||||
stageNames = splitIfGet(supportElem, 'stage')
|
||||
stages = [x for x in self.vk.bitmasks['VkPipelineStageFlagBits2'].flags if x.name in stageNames] if stageNames is not None else None
|
||||
support = SyncSupport(queues, stages, False)
|
||||
|
||||
equivalent = maxSyncEquivalent
|
||||
equivalentElem = syncElem.find('syncequivalent')
|
||||
if equivalentElem is not None:
|
||||
stageNames = splitIfGet(equivalentElem, 'stage')
|
||||
stages = [x for x in self.vk.bitmasks['VkPipelineStageFlagBits2'].flags if x.name in stageNames] if stageNames is not None else None
|
||||
accessNames = splitIfGet(equivalentElem, 'access')
|
||||
accesses = [x for x in self.vk.bitmasks['VkAccessFlagBits2'].flags if x.name in accessNames] if accessNames is not None else None
|
||||
equivalent = SyncEquivalent(stages, accesses, False)
|
||||
|
||||
flagName = syncElem.get('name')
|
||||
flag = [x for x in self.vk.bitmasks['VkAccessFlagBits2'].flags if x.name == flagName][0]
|
||||
self.vk.syncAccess.append(SyncAccess(flag, support, equivalent))
|
||||
|
||||
def genSyncPipeline(self, sync):
|
||||
OutputGenerator.genSyncPipeline(self, sync)
|
||||
syncElem = sync.elem
|
||||
name = syncElem.get('name')
|
||||
depends = splitIfGet(syncElem, 'depends')
|
||||
stages = []
|
||||
for stageElem in syncElem.findall('syncpipelinestage'):
|
||||
order = stageElem.get('order')
|
||||
before = stageElem.get('before')
|
||||
after = stageElem.get('after')
|
||||
value = stageElem.text
|
||||
stages.append(SyncPipelineStage(order, before, after, value))
|
||||
|
||||
self.vk.syncPipeline.append(SyncPipeline(name, depends, stages))
|
158
scripts/generators/dispatch_table_helper_generator.py
Normal file
158
scripts/generators/dispatch_table_helper_generator.py
Normal file
|
@ -0,0 +1,158 @@
|
|||
#!/usr/bin/python3 -i
|
||||
#
|
||||
# Copyright (c) 2015-2023 The Khronos Group Inc.
|
||||
# Copyright (c) 2015-2023 Valve Corporation
|
||||
# Copyright (c) 2015-2023 LunarG, Inc.
|
||||
# Copyright (c) 2015-2023 Google Inc.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
import os
|
||||
from generators.base_generator import BaseGenerator
|
||||
|
||||
class DispatchTableHelperOutputGenerator(BaseGenerator):
|
||||
"""Generate dispatch tables header based on XML element attributes"""
|
||||
def __init__(self):
|
||||
BaseGenerator.__init__(self)
|
||||
|
||||
def generate(self):
|
||||
out = []
|
||||
out.append(f'''// *** THIS FILE IS GENERATED - DO NOT EDIT ***
|
||||
// See {os.path.basename(__file__)} for modifications
|
||||
/***************************************************************************
|
||||
*
|
||||
* Copyright (c) 2015-2023 The Khronos Group Inc.
|
||||
* Copyright (c) 2015-2023 Valve Corporation
|
||||
* Copyright (c) 2015-2023 LunarG, Inc.
|
||||
* Copyright (c) 2015-2023 Google Inc.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
****************************************************************************/\n''')
|
||||
out.append('// NOLINTBEGIN') # Wrap for clang-tidy to ignore
|
||||
|
||||
out.append('''
|
||||
#pragma once
|
||||
|
||||
#include <vulkan/vulkan.h>
|
||||
#include <vulkan/vk_layer.h>
|
||||
#include <cstring>
|
||||
#include <string>
|
||||
#include "vk_layer_dispatch_table.h"
|
||||
#include "vk_extension_helper.h"
|
||||
\n''')
|
||||
|
||||
for command in [x for x in self.vk.commands.values() if x.extensions or x.version]:
|
||||
if command.name == 'vkEnumerateInstanceVersion':
|
||||
continue # TODO - Figure out how this can be automatically detected
|
||||
out.extend([f'#ifdef {command.protect}\n'] if command.protect else [])
|
||||
|
||||
prototype = ' '.join(command.cPrototype.split()) # remove duplicate whitespace
|
||||
prototype = prototype.replace('\n', '').replace('( ', '(').replace(');', ')').replace(' vk', ' Stub')
|
||||
|
||||
result = '' if command.returnType == 'void' else 'return 0;'
|
||||
result = 'return VK_SUCCESS;' if command.returnType == 'VkResult' else result
|
||||
result = 'return VK_FALSE;' if command.returnType == 'VkBool32' else result
|
||||
|
||||
out.append(f'static {prototype} {{ {result} }}\n')
|
||||
out.extend([f'#endif // {command.protect}\n'] if command.protect else [])
|
||||
out.append('\n')
|
||||
|
||||
out.append('const vvl::unordered_map<std::string, small_vector<std::string, 2, size_t>> api_extension_map {\n')
|
||||
for command in [x for x in self.vk.commands.values() if x.version and x.device]:
|
||||
out.append(f' {{ "{command.name}", {{ "{command.version.name}" }} }},\n')
|
||||
for command in [x for x in self.vk.commands.values() if x.extensions and x.device]:
|
||||
extensions = ', '.join(f'"{x.name}"' for x in command.extensions)
|
||||
out.append(f' {{ "{command.name}", {{ {extensions} }} }},\n')
|
||||
out.append('};\n')
|
||||
|
||||
out.append('''
|
||||
// Using the above code-generated map of APINames-to-parent extension names, this function will:
|
||||
// o Determine if the API has an associated extension
|
||||
// o If it does, determine if that extension name is present in the passed-in set of device or instance enabled_ext_names
|
||||
// If the APIname has no parent extension, OR its parent extension name is IN one of the sets, return TRUE, else FALSE
|
||||
static inline bool ApiParentExtensionEnabled(const std::string api_name, const DeviceExtensions *device_extension_info) {
|
||||
auto has_ext = api_extension_map.find(api_name);
|
||||
// Is this API part of an extension or feature group?
|
||||
if (has_ext != api_extension_map.end()) {
|
||||
|
||||
// Was the extension for this API enabled in the CreateDevice call?
|
||||
for (const auto& ext : has_ext->second) {
|
||||
auto info = device_extension_info->get_info(ext.c_str());
|
||||
if (info.state) {
|
||||
return device_extension_info->*(info.state) == kEnabledByCreateinfo || device_extension_info->*(info.state) == kEnabledByInteraction;
|
||||
}
|
||||
}
|
||||
|
||||
// Was the extension for this API enabled in the CreateInstance call?
|
||||
auto instance_extension_info = static_cast<const InstanceExtensions*>(device_extension_info);
|
||||
for (const auto& ext : has_ext->second) {
|
||||
auto inst_info = instance_extension_info->get_info(ext.c_str());
|
||||
if (inst_info.state) {
|
||||
return instance_extension_info->*(inst_info.state) == kEnabledByCreateinfo || device_extension_info->*(inst_info.state) == kEnabledByInteraction;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
''')
|
||||
out.append('''
|
||||
static inline void layer_init_device_dispatch_table(VkDevice device, VkLayerDispatchTable *table, PFN_vkGetDeviceProcAddr gpa) {
|
||||
memset(table, 0, sizeof(*table));
|
||||
// Device function pointers
|
||||
table->GetDeviceProcAddr = gpa;
|
||||
''')
|
||||
for command in [x for x in self.vk.commands.values() if x.device and x.name != 'vkGetDeviceProcAddr']:
|
||||
out.extend([f'#ifdef {command.protect}\n'] if command.protect else [])
|
||||
out.append(f' table->{command.name[2:]} = (PFN_{command.name}) gpa(device, "{command.name}");\n')
|
||||
if command.version or command.extensions:
|
||||
out.append(f' if (table->{command.name[2:]} == nullptr) {{ table->{command.name[2:]} = (PFN_{command.name})Stub{command.name[2:]}; }}\n')
|
||||
out.extend([f'#endif // {command.protect}\n'] if command.protect else [])
|
||||
out.append('}\n')
|
||||
|
||||
out.append('''
|
||||
static inline void layer_init_instance_dispatch_table(VkInstance instance, VkLayerInstanceDispatchTable *table, PFN_vkGetInstanceProcAddr gpa) {
|
||||
memset(table, 0, sizeof(*table));
|
||||
// Instance function pointers
|
||||
table->GetInstanceProcAddr = gpa;
|
||||
table->GetPhysicalDeviceProcAddr = (PFN_GetPhysicalDeviceProcAddr) gpa(instance, "vk_layerGetPhysicalDeviceProcAddr");
|
||||
''')
|
||||
ignoreList = [
|
||||
'vkCreateInstance',
|
||||
'vkCreateDevice',
|
||||
'vkGetPhysicalDeviceProcAddr',
|
||||
'vkEnumerateInstanceExtensionProperties',
|
||||
'vkEnumerateInstanceLayerProperties',
|
||||
'vkEnumerateInstanceVersion',
|
||||
'vkGetInstanceProcAddr',
|
||||
]
|
||||
for command in [x for x in self.vk.commands.values() if x.instance and x.name not in ignoreList]:
|
||||
out.extend([f'#ifdef {command.protect}\n'] if command.protect else [])
|
||||
out.append(f' table->{command.name[2:]} = (PFN_{command.name}) gpa(instance, "{command.name}");\n')
|
||||
if command.version or command.extensions:
|
||||
out.append(f' if (table->{command.name[2:]} == nullptr) {{ table->{command.name[2:]} = (PFN_{command.name})Stub{command.name[2:]}; }}\n')
|
||||
out.extend([f'#endif // {command.protect}\n'] if command.protect else [])
|
||||
out.append('}\n')
|
||||
|
||||
out.append('// NOLINTEND') # Wrap for clang-tidy to ignore
|
||||
self.write("".join(out))
|
132
scripts/generators/enum_string_helper_generator.py
Normal file
132
scripts/generators/enum_string_helper_generator.py
Normal file
|
@ -0,0 +1,132 @@
|
|||
#!/usr/bin/python3 -i
|
||||
#
|
||||
# Copyright (c) 2015-2023 The Khronos Group Inc.
|
||||
# Copyright (c) 2015-2023 Valve Corporation
|
||||
# Copyright (c) 2015-2023 LunarG, Inc.
|
||||
# Copyright (c) 2015-2023 Google Inc.
|
||||
# Copyright (c) 2023-2023 RasterGrid Kft.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
import os
|
||||
from generators.base_generator import BaseGenerator
|
||||
|
||||
class EnumStringHelperOutputGenerator(BaseGenerator):
|
||||
def __init__(self):
|
||||
BaseGenerator.__init__(self)
|
||||
|
||||
def generate(self):
|
||||
out = []
|
||||
out.append(f'''// *** THIS FILE IS GENERATED - DO NOT EDIT ***
|
||||
// See {os.path.basename(__file__)} for modifications
|
||||
/***************************************************************************
|
||||
*
|
||||
* Copyright (c) 2015-2023 The Khronos Group Inc.
|
||||
* Copyright (c) 2015-2023 Valve Corporation
|
||||
* Copyright (c) 2015-2023 LunarG, Inc.
|
||||
* Copyright (c) 2015-2023 Google Inc.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
****************************************************************************/
|
||||
''')
|
||||
out.append('// NOLINTBEGIN') # Wrap for clang-tidy to ignore
|
||||
|
||||
out.append('''
|
||||
#pragma once
|
||||
#include <string>
|
||||
#include <vulkan/vulkan.h>
|
||||
''')
|
||||
|
||||
# TODO - this should be moved into different generated util file
|
||||
out.append('\nstatic inline bool IsDuplicatePnext(VkStructureType input_value) {\n')
|
||||
out.append(' switch (input_value) {\n')
|
||||
|
||||
for struct in [x for x in self.vk.structs.values() if x.allowDuplicate and x.sType is not None]:
|
||||
# The sType will always be first member of struct
|
||||
out.append(f' case {struct.sType}:\n')
|
||||
out.append(' return true;\n')
|
||||
out.append(' default:\n')
|
||||
out.append(' return false;\n')
|
||||
out.append(' }\n')
|
||||
out.append('}\n')
|
||||
out.append('\n')
|
||||
|
||||
# If there are no fields (empty enum) ignore
|
||||
for enum in [x for x in self.vk.enums.values() if len(x.fields) > 0]:
|
||||
groupType = enum.name if enum.bitWidth == 32 else 'uint64_t'
|
||||
out.extend([f'#ifdef {enum.protect}\n'] if enum.protect else [])
|
||||
out.append(f'static inline const char* string_{enum.name}({groupType} input_value) {{\n')
|
||||
out.append(' switch (input_value) {\n')
|
||||
for field in enum.fields:
|
||||
out.extend([f'#ifdef {field.protect}\n'] if field.protect else [])
|
||||
out.append(f' case {field.name}:\n')
|
||||
out.append(f' return "{field.name}";\n')
|
||||
out.extend([f'#endif //{field.protect}\n'] if field.protect else [])
|
||||
out.append(' default:\n')
|
||||
out.append(f' return "Unhandled {enum.name}";\n')
|
||||
out.append(' }\n')
|
||||
out.append('}\n')
|
||||
out.extend([f'#endif //{enum.protect}\n'] if enum.protect else [])
|
||||
out.append('\n')
|
||||
|
||||
# For bitmask, first create a string for FlagBits, then a Flags version that calls into it
|
||||
# If there are no flags (empty bitmask) ignore
|
||||
for bitmask in [x for x in self.vk.bitmasks.values() if len(x.flags) > 0]:
|
||||
groupType = bitmask.name if bitmask.bitWidth == 32 else 'uint64_t'
|
||||
out.extend([f'#ifdef {bitmask.protect}\n'] if bitmask.protect else [])
|
||||
out.append(f'static inline const char* string_{bitmask.name}({groupType} input_value) {{\n')
|
||||
out.append(' switch (input_value) {\n')
|
||||
for flag in [x for x in bitmask.flags if not x.multiBit]:
|
||||
out.extend([f'#ifdef {flag.protect}\n'] if flag.protect else [])
|
||||
out.append(f' case {flag.name}:\n')
|
||||
out.append(f' return "{flag.name}";\n')
|
||||
out.extend([f'#endif //{flag.protect}\n'] if flag.protect else [])
|
||||
out.append(' default:\n')
|
||||
out.append(f' return "Unhandled {bitmask.name}";\n')
|
||||
out.append(' }\n')
|
||||
out.append('}\n')
|
||||
|
||||
mulitBitChecks = ''
|
||||
for flag in [x for x in bitmask.flags if x.multiBit]:
|
||||
mulitBitChecks += f' if (input_value == {flag.name}) {{ return "{flag.name}"; }}\n'
|
||||
intSuffix = 'U' if bitmask.bitWidth == 32 else 'ULL'
|
||||
|
||||
out.append(f'''
|
||||
static inline std::string string_{bitmask.flagName}({bitmask.flagName} input_value) {{
|
||||
{mulitBitChecks} std::string ret;
|
||||
int index = 0;
|
||||
while(input_value) {{
|
||||
if (input_value & 1) {{
|
||||
if( !ret.empty()) ret.append("|");
|
||||
ret.append(string_{bitmask.name}(static_cast<{groupType}>(1{intSuffix} << index)));
|
||||
}}
|
||||
++index;
|
||||
input_value >>= 1;
|
||||
}}
|
||||
if (ret.empty()) ret.append("{bitmask.flagName}(0)");
|
||||
return ret;
|
||||
}}\n''')
|
||||
out.extend([f'#endif //{bitmask.protect}\n'] if bitmask.protect else [])
|
||||
|
||||
out.append('// NOLINTEND') # Wrap for clang-tidy to ignore
|
||||
self.write("".join(out))
|
80
scripts/generators/layer_dispatch_table_generator.py
Normal file
80
scripts/generators/layer_dispatch_table_generator.py
Normal file
|
@ -0,0 +1,80 @@
|
|||
#!/usr/bin/python3 -i
|
||||
#
|
||||
# Copyright (c) 2015-2023 The Khronos Group Inc.
|
||||
# Copyright (c) 2015-2023 Valve Corporation
|
||||
# Copyright (c) 2015-2023 LunarG, Inc.
|
||||
# Copyright (c) 2015-2023 Google Inc.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
import os
|
||||
from generators.base_generator import BaseGenerator
|
||||
|
||||
class LayerDispatchTableOutputGenerator(BaseGenerator):
|
||||
def __init__(self):
|
||||
BaseGenerator.__init__(self)
|
||||
|
||||
def generate(self):
|
||||
out = []
|
||||
out.append(f'''// *** THIS FILE IS GENERATED - DO NOT EDIT ***
|
||||
// See {os.path.basename(__file__)} for modifications
|
||||
/***************************************************************************
|
||||
*
|
||||
* Copyright (c) 2015-2023 The Khronos Group Inc.
|
||||
* Copyright (c) 2015-2023 Valve Corporation
|
||||
* Copyright (c) 2015-2023 LunarG, Inc.
|
||||
* Copyright (c) 2015-2023 Google Inc.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
****************************************************************************/\n''')
|
||||
out.append('// NOLINTBEGIN') # Wrap for clang-tidy to ignore
|
||||
|
||||
out.append('''
|
||||
#pragma once
|
||||
|
||||
typedef PFN_vkVoidFunction (VKAPI_PTR *PFN_GetPhysicalDeviceProcAddr)(VkInstance instance, const char* pName);
|
||||
''')
|
||||
out.append('''
|
||||
// Instance function pointer dispatch table
|
||||
typedef struct VkLayerInstanceDispatchTable_ {
|
||||
PFN_GetPhysicalDeviceProcAddr GetPhysicalDeviceProcAddr;
|
||||
|
||||
''')
|
||||
for command in [x for x in self.vk.commands.values() if x.instance]:
|
||||
out.extend([f'#ifdef {command.protect}\n'] if command.protect else [])
|
||||
out.append(f' PFN_{command.name} {command.name[2:]};\n')
|
||||
out.extend([f'#endif //{command.protect}\n'] if command.protect else [])
|
||||
out.append('} VkLayerInstanceDispatchTable;\n')
|
||||
|
||||
out.append('''
|
||||
// Device function pointer dispatch table
|
||||
typedef struct VkLayerDispatchTable_ {
|
||||
''')
|
||||
for command in [x for x in self.vk.commands.values() if x.device]:
|
||||
out.extend([f'#ifdef {command.protect}\n'] if command.protect else [])
|
||||
out.append(f' PFN_{command.name} {command.name[2:]};\n')
|
||||
out.extend([f'#endif //{command.protect}\n'] if command.protect else [])
|
||||
out.append('} VkLayerDispatchTable;\n')
|
||||
|
||||
out.append('// NOLINTEND') # Wrap for clang-tidy to ignore
|
||||
self.write("".join(out))
|
386
scripts/generators/vulkan_object.py
Normal file
386
scripts/generators/vulkan_object.py
Normal file
|
@ -0,0 +1,386 @@
|
|||
#!/usr/bin/python3 -i
|
||||
#
|
||||
# Copyright (c) 2023 Valve Corporation
|
||||
# Copyright (c) 2023 LunarG, Inc.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
from dataclasses import dataclass, field
|
||||
from enum import IntFlag, Enum, auto
|
||||
|
||||
@dataclass
|
||||
class Extension:
|
||||
"""<extension>"""
|
||||
name: str # ex) VK_KHR_SURFACE
|
||||
nameString: str # marco with string, ex) VK_KHR_SURFACE_EXTENSION_NAME
|
||||
|
||||
# Only one will be True, the other is False
|
||||
instance: bool
|
||||
device: bool
|
||||
|
||||
depends: (str | None)
|
||||
vendorTag: (str | None) # ex) EXT, KHR, etc
|
||||
platform: (str | None) # ex) android
|
||||
protect: (str | None) # ex) VK_USE_PLATFORM_ANDROID_KHR
|
||||
provisional: bool
|
||||
promotedTo: (str | None) # ex) VK_VERSION_1_1
|
||||
deprecatedBy: (str | None)
|
||||
obsoletedBy: (str | None)
|
||||
specialUse: list[str]
|
||||
|
||||
# These are here to allow for easy reverse lookups
|
||||
# Quotes allow us to forward declare the dataclass
|
||||
commands: list['Command'] = field(default_factory=list, init=False)
|
||||
enums: list['Enum'] = field(default_factory=list, init=False)
|
||||
bitmask: list['Bitmask'] = field(default_factory=list, init=False)
|
||||
# Use the Enum name to see what fields are extended
|
||||
enumFields: dict[str, list['EnumField']] = field(default_factory=dict, init=False)
|
||||
# Use the Bitmaks name to see what flags are extended
|
||||
flags: dict[str, list['Flag']] = field(default_factory=dict, init=False)
|
||||
|
||||
@dataclass
|
||||
class Version:
|
||||
"""
|
||||
<feature> which represents a version
|
||||
This will NEVER be Version 1.0, since having 'no version' is same as being 1.0
|
||||
"""
|
||||
name: str # ex) VK_VERSION_1_1
|
||||
nameString: str # ex) "VK_VERSION_1_1" (no marco, so has quotes)
|
||||
nameApi: str # ex) VK_API_VERSION_1_1
|
||||
number: str # ex) 1.1
|
||||
|
||||
@dataclass
|
||||
class Handle:
|
||||
"""<type> which represents a dispatch handle"""
|
||||
name: str # ex) VkBuffer
|
||||
type: str # ex) VK_OBJECT_TYPE_BUFFER
|
||||
protect: (str | None) # ex) VK_USE_PLATFORM_ANDROID_KHR
|
||||
|
||||
parent: 'Handle' # Chain of parent handles, can be None
|
||||
|
||||
# Only one will be True, the other is False
|
||||
instance: bool
|
||||
device: bool
|
||||
|
||||
dispatchable: bool
|
||||
|
||||
@dataclass
|
||||
class Param:
|
||||
"""<command/param>"""
|
||||
name: str
|
||||
alias: str
|
||||
type: str # ex) void, VkFormat, etc
|
||||
|
||||
noAutoValidity: bool
|
||||
|
||||
const: bool # type contains 'const'
|
||||
length: (str | None) # the known length of pointer, will never be 'null-terminated'
|
||||
nullTerminated: bool # If a UTF-8 string, it will be null-terminated
|
||||
pointer: bool # type contains a pointer (include 'PFN' function pointers)
|
||||
fixedSizeArray: list[str] # for VkTransformMatrixKHR:matrix this is [3, 4]
|
||||
|
||||
optional: bool
|
||||
optionalPointer: bool # if type contains a pointer, is the pointer value optional
|
||||
|
||||
externSync: bool
|
||||
externSyncPointer: list[str] # if type contains a pointer, might only specific members modified
|
||||
|
||||
# C string of member, example:
|
||||
# - const void* pNext
|
||||
# - VkFormat format
|
||||
# - VkStructureType sType
|
||||
cDeclaration: str
|
||||
|
||||
class Queues(IntFlag):
|
||||
TRANSFER = auto() # VK_QUEUE_TRANSFER_BIT
|
||||
GRAPHICS = auto() # VK_QUEUE_GRAPHICS_BIT
|
||||
COMPUTE = auto() # VK_QUEUE_COMPUTE_BIT
|
||||
PROTECTED = auto() # VK_QUEUE_PROTECTED_BIT
|
||||
SPARSE_BINDING = auto() # VK_QUEUE_SPARSE_BINDING_BIT
|
||||
OPTICAL_FLOW = auto() # VK_QUEUE_OPTICAL_FLOW_BIT_NV
|
||||
DECODE = auto() # VK_QUEUE_VIDEO_DECODE_BIT_KHR
|
||||
ENCODE = auto() # VK_QUEUE_VIDEO_ENCODE_BIT_KHR
|
||||
ALL = TRANSFER | GRAPHICS | COMPUTE | PROTECTED | SPARSE_BINDING | OPTICAL_FLOW | DECODE | ENCODE
|
||||
|
||||
class CommandScope(Enum):
|
||||
NONE = auto()
|
||||
INSIDE = auto()
|
||||
OUTSIDE = auto()
|
||||
BOTH = auto()
|
||||
|
||||
@dataclass
|
||||
class Command:
|
||||
"""<command>"""
|
||||
name: str # ex) vkCmdDraw
|
||||
alias: str # Because commands are interfaces into layers/drivers, we need all command alias
|
||||
protect: (str | None) # ex) 'VK_ENABLE_BETA_EXTENSIONS'
|
||||
|
||||
extensions: list[Extension] # All extensions that enable the struct
|
||||
version: (Version | None) # None if Version 1.0
|
||||
|
||||
returnType: str # ex) void, VkResult, etc
|
||||
|
||||
params: list[Param] # Each parameter of the command
|
||||
|
||||
# Only one will be True, the other is False
|
||||
instance: bool
|
||||
device: bool
|
||||
|
||||
tasks: list[str] # ex) [ action, state, synchronization ]
|
||||
queues: Queues # zero == No Queues found
|
||||
successCodes: list[str] # ex) [ VK_SUCCESS, VK_INCOMPLETE ]
|
||||
errorCodes: list[str] # ex) [ VK_ERROR_OUT_OF_HOST_MEMORY ]
|
||||
|
||||
# Shows support if command can be in a primary and/or secondary command buffer
|
||||
primary: bool
|
||||
secondary: bool
|
||||
|
||||
renderPass: CommandScope
|
||||
videoCoding: CommandScope
|
||||
|
||||
implicitExternSyncParams: list[str]
|
||||
|
||||
# C prototype string - ex:
|
||||
# VKAPI_ATTR VkResult VKAPI_CALL vkCreateInstance(
|
||||
# const VkInstanceCreateInfo* pCreateInfo,
|
||||
# const VkAllocationCallbacks* pAllocator,
|
||||
# VkInstance* pInstance);
|
||||
cPrototype: str
|
||||
|
||||
# function pointer typedef - ex:
|
||||
# typedef VkResult (VKAPI_PTR *PFN_vkCreateInstance)
|
||||
# (const VkInstanceCreateInfo* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkInstance* pInstance);
|
||||
cFunctionPointer: str
|
||||
|
||||
@dataclass
|
||||
class Member:
|
||||
"""<member>"""
|
||||
name: str # ex) sharingMode
|
||||
type: str # ex) VkSharingMode
|
||||
|
||||
noAutoValidity: bool
|
||||
limitType: (str | None) # ex) 'max', 'bitmask', 'bits', 'min,mul'
|
||||
|
||||
const: bool # type contains 'const'
|
||||
length: (str | None) # the known length of pointer, will never be 'null-terminated'
|
||||
nullTerminated: bool # If a UTF-8 string, it will be null-terminated
|
||||
pointer: bool # type contains a pointer (include 'PFN' function pointers)
|
||||
fixedSizeArray: list[str] # for VkTransformMatrixKHR:matrix this is [3, 4]
|
||||
|
||||
optional: bool
|
||||
optionalPointer: bool # if type contains a pointer, is the pointer value optional
|
||||
|
||||
externSync: bool
|
||||
|
||||
# C string of member, example:
|
||||
# - const void* pNext
|
||||
# - VkFormat format
|
||||
# - VkStructureType sType
|
||||
cDeclaration: str
|
||||
|
||||
@dataclass
|
||||
class Struct:
|
||||
"""<type category="struct"> or <type category="union">"""
|
||||
name: str # ex. VkBufferCreateInfo
|
||||
extensions: list[Extension] # All extensions that enable the struct
|
||||
version: (Version | None) # None if Version 1.0
|
||||
protect: (str | None) # ex) VK_ENABLE_BETA_EXTENSIONS
|
||||
|
||||
members: list[Member]
|
||||
|
||||
union: bool # Unions are just a subset of a Structs
|
||||
returnedOnly: bool
|
||||
|
||||
sType: (str | None) # ex) VK_STRUCTURE_TYPE_BUFFER_CREATE_INFO
|
||||
allowDuplicate: bool # can have a pNext point to itself
|
||||
|
||||
# These use to be list['Struct'] but some circular loops occur and cause
|
||||
# pydevd warnings and made debugging slow (30 seconds to index a Struct)
|
||||
extends: list[str] # Struct names that this struct extends
|
||||
extendedBy: list[str] # Struct names that can be extended by this struct
|
||||
|
||||
@dataclass
|
||||
class EnumField:
|
||||
"""<enum> of type enum"""
|
||||
name: str # ex) VK_DYNAMIC_STATE_SCISSOR
|
||||
negative: bool # True if negative values are allowed (ex. VkResult)
|
||||
protect: (str | None) # ex) VK_ENABLE_BETA_EXTENSIONS
|
||||
|
||||
# some fields are enabled from 2 extensions (ex) VK_DESCRIPTOR_UPDATE_TEMPLATE_TYPE_PUSH_DESCRIPTORS_KHR)
|
||||
extensions: list[Extension] # None if part of 1.0 core
|
||||
|
||||
@dataclass
|
||||
class Enum:
|
||||
"""<enums> of type enum"""
|
||||
name: str # ex) VkDynamicState
|
||||
protect: (str | None) # ex) VK_ENABLE_BETA_EXTENSIONS
|
||||
|
||||
bitWidth: int # 32 or 64
|
||||
returnedOnly: bool
|
||||
|
||||
fields: list[EnumField]
|
||||
|
||||
extensions: list[Extension] # None if part of 1.0 core
|
||||
# Unique list of all extension that are involved in 'fields' (superset of 'extensions')
|
||||
fieldExtensions: list[Extension]
|
||||
|
||||
@dataclass
|
||||
class Flag:
|
||||
"""<enum> of type bitmask"""
|
||||
name: str # ex) VK_ACCESS_2_SHADER_READ_BIT
|
||||
protect: (str | None) # ex) VK_ENABLE_BETA_EXTENSIONS
|
||||
|
||||
value: int
|
||||
multiBit: bool # if true, more than one bit is set (ex) VK_SHADER_STAGE_ALL_GRAPHICS)
|
||||
zero: bool # if true, the value is zero (ex) VK_PIPELINE_STAGE_NONE)
|
||||
|
||||
# some fields are enabled from 2 extensions (ex) VK_TOOL_PURPOSE_DEBUG_REPORTING_BIT_EXT)
|
||||
extensions: list[str] # None if part of 1.0 core
|
||||
|
||||
@dataclass
|
||||
class Bitmask:
|
||||
"""<enums> of type bitmask"""
|
||||
name: str # ex) VkAccessFlagBits2
|
||||
flagName: str # ex) VkAccessFlags2
|
||||
protect: (str | None) # ex) VK_ENABLE_BETA_EXTENSIONS
|
||||
|
||||
bitWidth: int # 32 or 64
|
||||
flags: list[Flag]
|
||||
|
||||
extensions: list[Extension] # None if part of 1.0 core
|
||||
# Unique list of all extension that are involved in 'flag' (superset of 'extensions')
|
||||
flagExtensions: list[Extension]
|
||||
|
||||
@dataclass
|
||||
class FormatComponent:
|
||||
"""<format/component>"""
|
||||
type: str # ex) R, G, B, A, D, S, etc
|
||||
bits: str # will be an INT or 'compressed'
|
||||
numericFormat: str # ex) UNORM, SINT, etc
|
||||
planeIndex: (int | None) # None if no planeIndex in format
|
||||
|
||||
@dataclass
|
||||
class FormatPlane:
|
||||
"""<format/plane>"""
|
||||
index: int
|
||||
widthDivisor: int
|
||||
heightDivisor: int
|
||||
compatible: str
|
||||
|
||||
@dataclass
|
||||
class Format:
|
||||
"""<format>"""
|
||||
name: str
|
||||
className: str
|
||||
blockSize: int
|
||||
texelsPerBlock: int
|
||||
blockExtent: list[str]
|
||||
packed: (int | None) # None == not-packed
|
||||
chroma: (str | None)
|
||||
compressed: (str | None)
|
||||
components: list[FormatComponent] # <format/component>
|
||||
planes: list[FormatPlane] # <format/plane>
|
||||
spirvImageFormat: (str | None)
|
||||
|
||||
@dataclass
|
||||
class SyncSupport:
|
||||
"""<syncsupport>"""
|
||||
queues: Queues
|
||||
stages: list[Flag] # VkPipelineStageFlagBits2
|
||||
max: bool # If this supports max values
|
||||
|
||||
@dataclass
|
||||
class SyncEquivalent:
|
||||
"""<syncequivalent>"""
|
||||
stages: list[Flag] # VkPipelineStageFlagBits2
|
||||
accesses: list[Flag] # VkAccessFlagBits2
|
||||
max: bool # If this equivalent to everything
|
||||
|
||||
@dataclass
|
||||
class SyncStage:
|
||||
"""<syncstage>"""
|
||||
flag: Flag # VkPipelineStageFlagBits2
|
||||
support: SyncSupport
|
||||
equivalent: SyncEquivalent
|
||||
|
||||
@dataclass
|
||||
class SyncAccess:
|
||||
"""<syncaccess>"""
|
||||
flag: Flag # VkAccessFlagBits2
|
||||
support: SyncSupport
|
||||
equivalent: SyncEquivalent
|
||||
|
||||
@dataclass
|
||||
class SyncPipelineStage:
|
||||
"""<syncpipelinestage>"""
|
||||
order: (str | None)
|
||||
before: (str | None)
|
||||
after: (str | None)
|
||||
value: str
|
||||
|
||||
@dataclass
|
||||
class SyncPipeline:
|
||||
"""<syncpipeline>"""
|
||||
name: str
|
||||
depends: list[str]
|
||||
stages: list[SyncPipelineStage]
|
||||
|
||||
@dataclass
|
||||
class SpirvEnables:
|
||||
"""What is needed to enable the SPIR-V element"""
|
||||
version: (str | None)
|
||||
extension: (str | None)
|
||||
struct: (str | None)
|
||||
feature: (str | None)
|
||||
requires: (str | None)
|
||||
property: (str | None)
|
||||
member: (str | None)
|
||||
value: (str | None)
|
||||
|
||||
@dataclass
|
||||
class Spirv:
|
||||
"""<spirvextension> and <spirvcapability>"""
|
||||
name: str
|
||||
# Only one will be True, the other is False
|
||||
extension: bool
|
||||
capability: bool
|
||||
enable: list[SpirvEnables]
|
||||
|
||||
# This is the global Vulkan Object that holds all the information from parsing the XML
|
||||
# This class is designed so all generator scripts can use this to obtain data
|
||||
@dataclass
|
||||
class VulkanObject():
|
||||
headerVersion: int = 0 # value of VK_HEADER_VERSION
|
||||
|
||||
extensions: dict[str, Extension] = field(default_factory=dict, init=False)
|
||||
versions: dict[str, Version] = field(default_factory=dict, init=False)
|
||||
|
||||
handles: dict[str, Handle] = field(default_factory=dict, init=False)
|
||||
commands: dict[str, Command] = field(default_factory=dict, init=False)
|
||||
structs: dict[str, Struct] = field(default_factory=dict, init=False)
|
||||
enums: dict[str, Enum] = field(default_factory=dict, init=False)
|
||||
bitmasks: dict[str, Bitmask] = field(default_factory=dict, init=False)
|
||||
formats: dict[str, Format] = field(default_factory=dict, init=False)
|
||||
|
||||
syncStage: list[SyncStage] = field(default_factory=list, init=False)
|
||||
syncAccess: list[SyncAccess] = field(default_factory=list, init=False)
|
||||
syncPipeline: list[SyncPipeline] = field(default_factory=list, init=False)
|
||||
|
||||
spirv: list[Spirv] = field(default_factory=list, init=False)
|
||||
|
||||
# ex) [ xlib : VK_USE_PLATFORM_XLIB_KHR ]
|
||||
platforms: dict[str, str] = field(default_factory=dict, init=False)
|
||||
# list of all vendor Sufix names (KHR, EXT, etc. )
|
||||
vendorTags: list[str] = field(default_factory=list, init=False)
|
||||
# ex) [ Queues.COMPUTE : VK_QUEUE_COMPUTE_BIT ]
|
||||
queueBits: dict[IntFlag, str] = field(default_factory=dict, init=False)
|
Loading…
Add table
Add a link
Reference in a new issue