| // Copyright 2019-2021 The Khronos Group Inc. |
| // |
| // SPDX-License-Identifier: CC-BY-4.0 |
| |
| // Common Valid Usage |
| // Common to KHR trace rays commands |
| |
| * [[VUID-{refpage}-maxPipelineRayRecursionDepth-03679]] |
| This command must: not cause a shader call instruction to be executed |
| from a shader invocation with a <<ray-tracing-recursion-depth, recursion |
| depth>> greater than the value of pname:maxPipelineRayRecursionDepth |
| used to create the bound ray tracing pipeline |
| * [[VUID-{refpage}-pRayGenShaderBindingTable-03680]] |
| If the buffer from which pname:pRayGenShaderBindingTable->deviceAddress |
| was queried is non-sparse then it must: be bound completely and |
| contiguously to a single sname:VkDeviceMemory object |
| * [[VUID-{refpage}-pRayGenShaderBindingTable-03681]] |
| The buffer from which the pname:pRayGenShaderBindingTable->deviceAddress |
| is queried must: have been created with the |
| ename:VK_BUFFER_USAGE_SHADER_BINDING_TABLE_BIT_KHR usage flag |
| * [[VUID-{refpage}-pRayGenShaderBindingTable-03682]] |
| pname:pRayGenShaderBindingTable->deviceAddress must: be a multiple of |
| sname:VkPhysicalDeviceRayTracingPipelinePropertiesKHR::pname:shaderGroupBaseAlignment |
| * [[VUID-{refpage}-size-04023]] |
| The pname:size member of pname:pRayGenShaderBindingTable must: be equal |
| to its pname:stride member |
| * [[VUID-{refpage}-pMissShaderBindingTable-03683]] |
| If the buffer from which pname:pMissShaderBindingTable->deviceAddress |
| was queried is non-sparse then it must: be bound completely and |
| contiguously to a single sname:VkDeviceMemory object |
| * [[VUID-{refpage}-pMissShaderBindingTable-03684]] |
| The buffer from which the pname:pMissShaderBindingTable->deviceAddress |
| is queried must: have been created with the |
| ename:VK_BUFFER_USAGE_SHADER_BINDING_TABLE_BIT_KHR usage flag |
| * [[VUID-{refpage}-pMissShaderBindingTable-03685]] |
| pname:pMissShaderBindingTable->deviceAddress must: be a multiple of |
| sname:VkPhysicalDeviceRayTracingPipelinePropertiesKHR::pname:shaderGroupBaseAlignment |
| * [[VUID-{refpage}-stride-03686]] |
| The pname:stride member of pname:pMissShaderBindingTable must: be a |
| multiple of |
| sname:VkPhysicalDeviceRayTracingPipelinePropertiesKHR::pname:shaderGroupHandleAlignment |
| * [[VUID-{refpage}-stride-04029]] |
| The pname:stride member of pname:pMissShaderBindingTable must: be less |
| than or equal to |
| sname:VkPhysicalDeviceRayTracingPipelinePropertiesKHR::pname:maxShaderGroupStride |
| * [[VUID-{refpage}-pHitShaderBindingTable-03687]] |
| If the buffer from which pname:pHitShaderBindingTable->deviceAddress was |
| queried is non-sparse then it must: be bound completely and contiguously |
| to a single sname:VkDeviceMemory object |
| * [[VUID-{refpage}-pHitShaderBindingTable-03688]] |
| The buffer from which the pname:pHitShaderBindingTable->deviceAddress is |
| queried must: have been created with the |
| ename:VK_BUFFER_USAGE_SHADER_BINDING_TABLE_BIT_KHR usage flag |
| * [[VUID-{refpage}-pHitShaderBindingTable-03689]] |
| pname:pHitShaderBindingTable->deviceAddress must: be a multiple of |
| sname:VkPhysicalDeviceRayTracingPipelinePropertiesKHR::pname:shaderGroupBaseAlignment |
| * [[VUID-{refpage}-stride-03690]] |
| The pname:stride member of pname:pHitShaderBindingTable must: be a |
| multiple of |
| sname:VkPhysicalDeviceRayTracingPipelinePropertiesKHR::pname:shaderGroupHandleAlignment |
| * [[VUID-{refpage}-stride-04035]] |
| The pname:stride member of pname:pHitShaderBindingTable must: be less |
| than or equal to |
| sname:VkPhysicalDeviceRayTracingPipelinePropertiesKHR::pname:maxShaderGroupStride |
| * [[VUID-{refpage}-pCallableShaderBindingTable-03691]] |
| If the buffer from which |
| pname:pCallableShaderBindingTable->deviceAddress was queried is |
| non-sparse then it must: be bound completely and contiguously to a |
| single sname:VkDeviceMemory object |
| * [[VUID-{refpage}-pCallableShaderBindingTable-03692]] |
| The buffer from which the |
| pname:pCallableShaderBindingTable->deviceAddress is queried must: have |
| been created with the ename:VK_BUFFER_USAGE_SHADER_BINDING_TABLE_BIT_KHR |
| usage flag |
| * [[VUID-{refpage}-pCallableShaderBindingTable-03693]] |
| pname:pCallableShaderBindingTable->deviceAddress must: be a multiple of |
| sname:VkPhysicalDeviceRayTracingPipelinePropertiesKHR::pname:shaderGroupBaseAlignment |
| * [[VUID-{refpage}-stride-03694]] |
| The pname:stride member of pname:pCallableShaderBindingTable must: be a |
| multiple of |
| sname:VkPhysicalDeviceRayTracingPipelinePropertiesKHR::pname:shaderGroupHandleAlignment |
| * [[VUID-{refpage}-stride-04041]] |
| The pname:stride member of pname:pCallableShaderBindingTable must: be |
| less than or equal to |
| sname:VkPhysicalDeviceRayTracingPipelinePropertiesKHR::pname:maxShaderGroupStride |
| * [[VUID-{refpage}-flags-03696]] |
| If the currently bound ray tracing pipeline was created with pname:flags |
| that included |
| ename:VK_PIPELINE_CREATE_RAY_TRACING_NO_NULL_CLOSEST_HIT_SHADERS_BIT_KHR, |
| the pname:deviceAddress member of pname:pHitShaderBindingTable must: not |
| be zero |
| * [[VUID-{refpage}-flags-03697]] |
| If the currently bound ray tracing pipeline was created with pname:flags |
| that included |
| ename:VK_PIPELINE_CREATE_RAY_TRACING_NO_NULL_INTERSECTION_SHADERS_BIT_KHR, |
| the pname:deviceAddress member of pname:pHitShaderBindingTable must: not |
| be zero |
| * [[VUID-{refpage}-flags-03511]] |
| If the currently bound ray tracing pipeline was created with pname:flags |
| that included |
| ename:VK_PIPELINE_CREATE_RAY_TRACING_NO_NULL_MISS_SHADERS_BIT_KHR, the |
| shader group handle identified by pname:pMissShaderBindingTable must: |
| not be set to zero |
| * [[VUID-{refpage}-flags-03512]] |
| If the currently bound ray tracing pipeline was created with pname:flags |
| that included |
| ename:VK_PIPELINE_CREATE_RAY_TRACING_NO_NULL_ANY_HIT_SHADERS_BIT_KHR, |
| entries in pname:pHitShaderBindingTable accessed as a result of this |
| command in order to execute an any-hit shader must: not be set to zero |
| * [[VUID-{refpage}-flags-03513]] |
| If the currently bound ray tracing pipeline was created with pname:flags |
| that included |
| ename:VK_PIPELINE_CREATE_RAY_TRACING_NO_NULL_CLOSEST_HIT_SHADERS_BIT_KHR, |
| entries in pname:pHitShaderBindingTable accessed as a result of this |
| command in order to execute a closest hit shader must: not be set to |
| zero |
| * [[VUID-{refpage}-flags-03514]] |
| If the currently bound ray tracing pipeline was created with pname:flags |
| that included |
| ename:VK_PIPELINE_CREATE_RAY_TRACING_NO_NULL_INTERSECTION_SHADERS_BIT_KHR, |
| entries in pname:pHitShaderBindingTable accessed as a result of this |
| command in order to execute an intersection shader must: not be set to |
| zero |
| * [[VUID-{refpage}-pHitShaderBindingTable-04735]] |
| Any non-zero hit shader group entries in pname:pHitShaderBindingTable |
| accessed by this call from a geometry with a pname:geometryType of |
| ename:VK_GEOMETRY_TYPE_TRIANGLES_KHR must: have been created with |
| ename:VK_RAY_TRACING_SHADER_GROUP_TYPE_TRIANGLES_HIT_GROUP_KHR |
| * [[VUID-{refpage}-pHitShaderBindingTable-04736]] |
| Any non-zero hit shader group entries in pname:pHitShaderBindingTable |
| accessed by this call from a geometry with a pname:geometryType of |
| ename:VK_GEOMETRY_TYPE_AABBS_KHR must: have been created with |
| ename:VK_RAY_TRACING_SHADER_GROUP_TYPE_PROCEDURAL_HIT_GROUP_KHR |
| |
| // Common Valid Usage |