VkRayTracingShaderGroupCreateInfoNV
The VkRayTracingShaderGroupCreateInfoNV
structure is defined as:
typedef struct VkRayTracingShaderGroupCreateInfoNV {
VkStructureType sType;
const void* pNext;
VkRayTracingShaderGroupTypeKHR type;
uint32_t generalShader;
uint32_t closestHitShader;
uint32_t anyHitShader;
uint32_t intersectionShader;
} VkRayTracingShaderGroupCreateInfoNV;
sType
is a VkStructureType value identifying this structure.pNext
isNULL
or a pointer to a structure extending this structure.type
is the type of hit group specified in this structure.generalShader
is the index of the ray generation, miss, or callable shader from VkRayTracingPipelineCreateInfoNV::pStages
in the group if the shader group hastype
ofVK_RAY_TRACING_SHADER_GROUP_TYPE_GENERAL_NV
, andVK_SHADER_UNUSED_NV
otherwise.closestHitShader
is the optional index of the closest hit shader from VkRayTracingPipelineCreateInfoNV::pStages
in the group if the shader group hastype
ofVK_RAY_TRACING_SHADER_GROUP_TYPE_TRIANGLES_HIT_GROUP_NV
orVK_RAY_TRACING_SHADER_GROUP_TYPE_PROCEDURAL_HIT_GROUP_NV
, andVK_SHADER_UNUSED_NV
otherwise.anyHitShader
is the optional index of the any-hit shader from VkRayTracingPipelineCreateInfoNV::pStages
in the group if the shader group hastype
ofVK_RAY_TRACING_SHADER_GROUP_TYPE_TRIANGLES_HIT_GROUP_NV
orVK_RAY_TRACING_SHADER_GROUP_TYPE_PROCEDURAL_HIT_GROUP_NV
, andVK_SHADER_UNUSED_NV
otherwise.intersectionShader
is the index of the intersection shader from VkRayTracingPipelineCreateInfoNV::pStages
in the group if the shader group hastype
ofVK_RAY_TRACING_SHADER_GROUP_TYPE_PROCEDURAL_HIT_GROUP_NV
, andVK_SHADER_UNUSED_NV
otherwise.
Valid Usage
VUID-VkRayTracingShaderGroupCreateInfoNV-type-02413
If type
is VK_RAY_TRACING_SHADER_GROUP_TYPE_GENERAL_NV
then
generalShader
must be a valid index into
VkRayTracingPipelineCreateInfoNV::pStages
referring to a
shader of VK_SHADER_STAGE_RAYGEN_BIT_NV
,
VK_SHADER_STAGE_MISS_BIT_NV
, or
VK_SHADER_STAGE_CALLABLE_BIT_NV
VUID-VkRayTracingShaderGroupCreateInfoNV-type-02414
If type
is VK_RAY_TRACING_SHADER_GROUP_TYPE_GENERAL_NV
then
closestHitShader
, anyHitShader
, and intersectionShader
must be VK_SHADER_UNUSED_NV
VUID-VkRayTracingShaderGroupCreateInfoNV-type-02415
If type
is
VK_RAY_TRACING_SHADER_GROUP_TYPE_PROCEDURAL_HIT_GROUP_NV
then
intersectionShader
must be a valid index into
VkRayTracingPipelineCreateInfoNV::pStages
referring to a
shader of VK_SHADER_STAGE_INTERSECTION_BIT_NV
VUID-VkRayTracingShaderGroupCreateInfoNV-type-02416
If type
is
VK_RAY_TRACING_SHADER_GROUP_TYPE_TRIANGLES_HIT_GROUP_NV
then
intersectionShader
must be VK_SHADER_UNUSED_NV
VUID-VkRayTracingShaderGroupCreateInfoNV-closestHitShader-02417
closestHitShader
must be either VK_SHADER_UNUSED_NV
or a
valid index into VkRayTracingPipelineCreateInfoNV::pStages
referring to a shader of VK_SHADER_STAGE_CLOSEST_HIT_BIT_NV
VUID-VkRayTracingShaderGroupCreateInfoNV-anyHitShader-02418
anyHitShader
must be either VK_SHADER_UNUSED_NV
or a valid
index into VkRayTracingPipelineCreateInfoNV::pStages
referring to a shader of VK_SHADER_STAGE_ANY_HIT_BIT_NV
Valid Usage (Implicit)
VUID-VkRayTracingShaderGroupCreateInfoNV-sType-sType
sType
must be VK_STRUCTURE_TYPE_RAY_TRACING_SHADER_GROUP_CREATE_INFO_NV
VUID-VkRayTracingShaderGroupCreateInfoNV-pNext-pNext
pNext
must be NULL
VUID-VkRayTracingShaderGroupCreateInfoNV-type-parameter
type
must be a valid VkRayTracingShaderGroupTypeKHR value