The parameters basePipelineHandle and basePipelineIndex are described in more detail in Pipeline Derivatives.
When PIPELINE_CREATE_LIBRARY_BIT_KHR is specified, this pipeline defines a pipeline library which cannot be bound as a ray tracing pipeline directly. Instead, pipeline libraries define common shaders and shader groups which can be included in future pipeline creation.
If pipeline libraries are included in pLibraryInfo, shaders defined in those libraries are treated as if they were defined as additional entries in pStages, appended in the order they appear in the pLibraries array and in the pStages array when those libraries were defined.
When referencing shader groups in order to obtain a shader group handle, groups defined in those libraries are treated as if they were defined as additional entries in pGroups, appended in the order they appear in the pLibraries array and in the pGroups array when those libraries were defined. The shaders these groups reference are set when the pipeline library is created, referencing those specified in the pipeline library, not in the pipeline that includes it.
The default stack size for a pipeline if DYNAMIC_STATE_RAY_TRACING_PIPELINE_STACK_SIZE_KHR is not provided is computed as described in Ray Tracing Pipeline Stack.
If a VkPipelineCreateFlags2CreateInfoKHR structure is present in the pNext chain, VkPipelineCreateFlags2CreateInfoKHR::flags from that structure is used instead of flags from this structure.
flags contains the PIPELINE_CREATE_DERIVATIVE_BIT flag, and basePipelineIndex is -1, basePipelineHandle must be a valid ray tracing VkPipeline handleflags contains the PIPELINE_CREATE_DERIVATIVE_BIT flag, and basePipelineHandle is NULL_HANDLE, basePipelineIndex must be a valid index into the calling command’s pCreateInfos parameterflags contains the PIPELINE_CREATE_DERIVATIVE_BIT flag, basePipelineIndex must be -1 or basePipelineHandle must be NULL_HANDLElayout must match both the shader stage and rangelayout must match the shader stageDESCRIPTOR_TYPE_MUTABLE_EXT, a descriptor slot in layout must match the descriptor typelayout must match the descriptor countpStages, and the rest of the state identified by this structure must adhere to the pipeline linking rules described in the Shader Interfaces chapterlayout accessible to each shader stage that is used by the pipeline must be less than or equal to VkPhysicalDeviceLimits::maxPerStageResourcesflags must not include PIPELINE_CREATE_INDIRECT_BINDABLE_BIT_NVpipelineCreationCacheControl feature is not enabled, flags must not include PIPELINE_CREATE_FAIL_ON_PIPELINE_COMPILE_REQUIRED_BIT or PIPELINE_CREATE_EARLY_RETURN_ON_FAILURE_BITflags does not include PIPELINE_CREATE_LIBRARY_BIT_KHR, the stage member of at least one element of pStages, including those implicitly added by pLibraryInfo, must be SHADER_STAGE_RAYGEN_BIT_KHRmaxPipelineRayRecursionDepth must be less than or equal to VkPhysicalDeviceRayTracingPipelinePropertiesKHR::maxRayRecursionDepthflags includes PIPELINE_CREATE_LIBRARY_BIT_KHR, pLibraryInterface must not be NULLpLibraryInfo is not NULL and its libraryCount member is greater than 0, pLibraryInterface must not be NULLpLibraryInfo→pLibraries must have been created with the value of maxPipelineRayRecursionDepth equal to that in this pipelinepLibraryInfo is not NULL, each element of its pLibraries member must have been created with a layout that is compatible with the layout in this pipelinepLibraryInfo is not NULL, each element of its pLibraries member must have been created with values of the maxPipelineRayPayloadSize and maxPipelineRayHitAttributeSize members of pLibraryInterface equal to those in this pipelineflags includes PIPELINE_CREATE_RAY_TRACING_SHADER_GROUP_HANDLE_CAPTURE_REPLAY_BIT_KHR, each element of pLibraryInfo→pLibraries must have been created with the PIPELINE_CREATE_RAY_TRACING_SHADER_GROUP_HANDLE_CAPTURE_REPLAY_BIT_KHR bit setflags includes PIPELINE_CREATE_RAY_TRACING_SKIP_AABBS_BIT_KHR, each element of pLibraryInfo→pLibraries must have been created with the PIPELINE_CREATE_RAY_TRACING_SKIP_AABBS_BIT_KHR bit setflags includes PIPELINE_CREATE_RAY_TRACING_SKIP_TRIANGLES_BIT_KHR, each element of pLibraryInfo→pLibraries must have been created with the PIPELINE_CREATE_RAY_TRACING_SKIP_TRIANGLES_BIT_KHR bit setflags includes PIPELINE_CREATE_RAY_TRACING_NO_NULL_ANY_HIT_SHADERS_BIT_KHR, each element of pLibraryInfo→pLibraries must have been created with the PIPELINE_CREATE_RAY_TRACING_NO_NULL_ANY_HIT_SHADERS_BIT_KHR bit setflags includes PIPELINE_CREATE_RAY_TRACING_NO_NULL_CLOSEST_HIT_SHADERS_BIT_KHR, each element of pLibraryInfo→pLibraries must have been created with the PIPELINE_CREATE_RAY_TRACING_NO_NULL_CLOSEST_HIT_SHADERS_BIT_KHR bit setflags includes PIPELINE_CREATE_RAY_TRACING_NO_NULL_INTERSECTION_SHADERS_BIT_KHR, each element of pLibraryInfo→pLibraries must have been created with the PIPELINE_CREATE_RAY_TRACING_NO_NULL_INTERSECTION_SHADERS_BIT_KHR bit setflags includes PIPELINE_CREATE_RAY_TRACING_NO_NULL_MISS_SHADERS_BIT_KHR, each element of pLibraryInfo→pLibraries must have been created with the PIPELINE_CREATE_RAY_TRACING_NO_NULL_MISS_SHADERS_BIT_KHR bit setVK_KHR_pipeline_library extension is not enabled, pLibraryInfo and pLibraryInterface must be NULLflags includes PIPELINE_CREATE_RAY_TRACING_NO_NULL_ANY_HIT_SHADERS_BIT_KHR, for any element of pGroups with a type of RAY_TRACING_SHADER_GROUP_TYPE_TRIANGLES_HIT_GROUP_KHR or RAY_TRACING_SHADER_GROUP_TYPE_PROCEDURAL_HIT_GROUP_KHR, the anyHitShader of that element must not be SHADER_UNUSED_KHRflags includes PIPELINE_CREATE_RAY_TRACING_NO_NULL_CLOSEST_HIT_SHADERS_BIT_KHR, for any element of pGroups with a type of RAY_TRACING_SHADER_GROUP_TYPE_TRIANGLES_HIT_GROUP_KHR or RAY_TRACING_SHADER_GROUP_TYPE_PROCEDURAL_HIT_GROUP_KHR, the closestHitShader of that element must not be SHADER_UNUSED_KHRrayTraversalPrimitiveCulling feature is not enabled, flags must not include PIPELINE_CREATE_RAY_TRACING_SKIP_AABBS_BIT_KHRrayTraversalPrimitiveCulling feature is not enabled, flags must not include PIPELINE_CREATE_RAY_TRACING_SKIP_TRIANGLES_BIT_KHRflags must not include both PIPELINE_CREATE_RAY_TRACING_SKIP_TRIANGLES_BIT_KHR and PIPELINE_CREATE_RAY_TRACING_SKIP_AABBS_BIT_KHRflags includes PIPELINE_CREATE_RAY_TRACING_SHADER_GROUP_HANDLE_CAPTURE_REPLAY_BIT_KHR, rayTracingPipelineShaderGroupHandleCaptureReplay must be enabledVkPhysicalDeviceRayTracingPipelineFeaturesKHR::rayTracingPipelineShaderGroupHandleCaptureReplay is TRUE and the pShaderGroupCaptureReplayHandle member of any element of pGroups is not NULL, flags must include PIPELINE_CREATE_RAY_TRACING_SHADER_GROUP_HANDLE_CAPTURE_REPLAY_BIT_KHRpLibraryInfo is NULL or its libraryCount is 0, stageCount must not be 0flags does not include PIPELINE_CREATE_LIBRARY_BIT_KHR and either pLibraryInfo is NULL or its libraryCount is 0, groupCount must not be 0pDynamicStates member of pDynamicState must be DYNAMIC_STATE_RAY_TRACING_PIPELINE_STACK_SIZE_KHRVkPipelineCreationFeedbackCreateInfo::pipelineStageCreationFeedbackCount is not 0, it must be equal to stageCountstage value in all pStages elements must be one of SHADER_STAGE_RAYGEN_BIT_KHR, SHADER_STAGE_ANY_HIT_BIT_KHR, SHADER_STAGE_CLOSEST_HIT_BIT_KHR, SHADER_STAGE_MISS_BIT_KHR, SHADER_STAGE_INTERSECTION_BIT_KHR, or SHADER_STAGE_CALLABLE_BIT_KHRflags includes PIPELINE_CREATE_RAY_TRACING_OPACITY_MICROMAP_BIT_EXT, each element of pLibraryInfo→pLibraries must have been created with the PIPELINE_CREATE_RAY_TRACING_OPACITY_MICROMAP_BIT_EXT bit setflags includes PIPELINE_CREATE_RAY_TRACING_DISPLACEMENT_MICROMAP_BIT_NV, each element of pLibraryInfo→pLibraries must have been created with the PIPELINE_CREATE_RAY_TRACING_DISPLACEMENT_MICROMAP_BIT_NV bit setsType must be STRUCTURE_TYPE_RAY_TRACING_PIPELINE_CREATE_INFO_KHRpNext member of any structure (including this one) in the pNext chain must be either NULL or a pointer to a valid instance of VkPipelineCreateFlags2CreateInfoKHR, VkPipelineCreationFeedbackCreateInfo, or VkPipelineRobustnessCreateInfoEXTsType value of each struct in the pNext chain must be uniqueflags must be a valid combination of VkPipelineCreateFlagBits valuesstageCount is not 0, pStages must be a valid pointer to an array of stageCount valid VkPipelineShaderStageCreateInfo structuresgroupCount is not 0, pGroups must be a valid pointer to an array of groupCount valid VkRayTracingShaderGroupCreateInfoKHR structurespLibraryInfo is not NULL, pLibraryInfo must be a valid pointer to a valid VkPipelineLibraryCreateInfoKHR structurepLibraryInterface is not NULL, pLibraryInterface must be a valid pointer to a valid VkRayTracingPipelineInterfaceCreateInfoKHR structurepDynamicState is not NULL, pDynamicState must be a valid pointer to a valid VkPipelineDynamicStateCreateInfo structurelayout must be a valid VkPipelineLayout handlebasePipelineHandle, and layout that are valid handles of non-ignored parameters must have been created, allocated, or retrieved from the same VkDeviceVkPipelineDynamicStateCreateInfo, VkPipelineLibraryCreateInfoKHR, VkPipelineShaderStageCreateInfo, VkRayTracingPipelineInterfaceCreateInfoKHR, VkRayTracingShaderGroupCreateInfoKHR, CreateRayTracingPipelinesKHR
struct VkRayTracingPipelineCreateInfoKHR {
VkStructureType sType;
void const * pNext;
VkPipelineCreateFlags flags;
uint32_t stageCount;
VkPipelineShaderStageCreateInfo const * pStages;
uint32_t groupCount;
VkRayTracingShaderGroupCreateInfoKHR const * pGroups;
uint32_t maxPipelineRayRecursionDepth;
VkPipelineLibraryCreateInfoKHR const * pLibraryInfo;
VkRayTracingPipelineInterfaceCreateInfoKHR const * pLibraryInterface;
VkPipelineDynamicStateCreateInfo const * pDynamicState;
VkPipelineLayout layout;
VkPipeline basePipelineHandle;
int32_t basePipelineIndex;
}
| Modifier and Type | Class and Description |
|---|---|
| public static class | VkRayTracingPipelineCreateInfoKHR.
An array of |
| Modifier and Type | Field and Description |
|---|---|
| public static final int | ALIGNOF
The struct alignment in bytes. |
| public static final int | BASEPIPELINEHANDLE
The struct member offsets. |
| public static final int | BASEPIPELINEINDEX
The struct member offsets. |
| public static final int | FLAGS
The struct member offsets. |
| public static final int | GROUPCOUNT
The struct member offsets. |
| public static final int | LAYOUT
The struct member offsets. |
| public static final int | MAXPIPELINERAYRECURSIONDEPTH
The struct member offsets. |
| public static final int | PDYNAMICSTATE
The struct member offsets. |
| public static final int | PGROUPS
The struct member offsets. |
| public static final int | PLIBRARYINFO
The struct member offsets. |
| public static final int | PLIBRARYINTERFACE
The struct member offsets. |
| public static final int | PNEXT
The struct member offsets. |
| public static final int | PSTAGES
The struct member offsets. |
| public static final int | SIZEOF
The struct size in bytes. |
| public static final int | STAGECOUNT
The struct member offsets. |
| public static final int | STYPE
The struct member offsets. |
| Access | Constructor and Description |
|---|---|
| protected | |
| public | VkRayTracingPipelineCreateInfoKHR(ByteBuffer container)
Creates a |
| Modifier and Type | Method and Description |
|---|---|
| public long | |
| public VkRayTracingPipelineCreateInfoKHR | |
| public int | |
| public VkRayTracingPipelineCreateInfoKHR | |
| public static VkRayTracingPipelineCreateInfoKHR | |
| public static VkRayTracingPipelineCreateInfoKHR. | calloc(int
the buffer capacity capacity)Returns a new |
| public static VkRayTracingPipelineCreateInfoKHR | calloc(MemoryStack
the stack from which to allocate stack)Returns a new |
| public static VkRayTracingPipelineCreateInfoKHR. | calloc(int
the buffer capacity capacity, MemoryStack the stack from which to allocate stack)Returns a new |
| protected VkRayTracingPipelineCreateInfoKHR | create(long
the struct memory address address, ByteBuffer an optional container buffer, to be referenced strongly by the struct instance. container)Implements abstract org. the constructor, but returns the exact type of the Struct subclass.
|
| public static VkRayTracingPipelineCreateInfoKHR | |
| public static VkRayTracingPipelineCreateInfoKHR | create(long address)
Returns a new |
| public static VkRayTracingPipelineCreateInfoKHR. | create(int
the buffer capacity capacity)Returns a new |
| public static VkRayTracingPipelineCreateInfoKHR. | create(long
the memory address address, int the buffer capacity capacity)Create a |
| public static VkRayTracingPipelineCreateInfoKHR | |
| public static VkRayTracingPipelineCreateInfoKHR. | |
| public int | |
| public VkRayTracingPipelineCreateInfoKHR | |
| public int | |
| public long | layout()
the description of binding locations used by both the pipeline and descriptor sets used with the pipeline. |
| public VkRayTracingPipelineCreateInfoKHR | |
| public static VkRayTracingPipelineCreateInfoKHR | |
| public static VkRayTracingPipelineCreateInfoKHR. | malloc(int
the buffer capacity capacity)Returns a new |
| public static VkRayTracingPipelineCreateInfoKHR | malloc(MemoryStack
the stack from which to allocate stack)Returns a new |
| public static VkRayTracingPipelineCreateInfoKHR. | malloc(int
the buffer capacity capacity, MemoryStack the stack from which to allocate stack)Returns a new |
| public int | |
| public VkRayTracingPipelineCreateInfoKHR | maxPipelineRayRecursionDepth(int value)
Sets the specified value to the |
| public static long | |
| public static void | |
| public static int | |
| public static void | |
| public static int | |
| public static void | |
| public static int | |
| public static void | ngroupCount(long struct, int value)
Sets the specified value to the |
| public static long | |
| public static void | |
| public static int | |
| public static void | nmaxPipelineRayRecursionDepth(long struct, int value)
Unsafe version of |
| public static VkPipelineDynamicStateCreateInfo | |
| public static void | |
| public static VkRayTracingShaderGroupCreateInfoKHR. | |
| public static void | |
| public static VkPipelineLibraryCreateInfoKHR | |
| public static void | |
| public static VkRayTracingPipelineInterfaceCreateInfoKHR | |
| public static void | npLibraryInterface(long struct, VkRayTracingPipelineInterfaceCreateInfoKHR value)
Unsafe version of |
| public static long | |
| public static void | |
| public static VkPipelineShaderStageCreateInfo. | |
| public static void | |
| public static int | |
| public static void | nstageCount(long struct, int value)
Sets the specified value to the |
| public static int | |
| public static void | |
| public VkPipelineDynamicStateCreateInfo | pDynamicState()
a pointer to a |
| public VkRayTracingPipelineCreateInfoKHR | pDynamicState(VkPipelineDynamicStateCreateInfo value)
Sets the address of the specified |
| public VkRayTracingShaderGroupCreateInfoKHR. | pGroups()
a pointer to an array of |
| public VkRayTracingPipelineCreateInfoKHR | pGroups(VkRayTracingShaderGroupCreateInfoKHR.
Sets the address of the specified |
| public VkPipelineLibraryCreateInfoKHR | pLibraryInfo()
a pointer to a |
| public VkRayTracingPipelineCreateInfoKHR | pLibraryInfo(VkPipelineLibraryCreateInfoKHR value)
Sets the address of the specified |
| public VkRayTracingPipelineInterfaceCreateInfoKHR | pLibraryInterface()
a pointer to a |
| public VkRayTracingPipelineCreateInfoKHR | pLibraryInterface(VkRayTracingPipelineInterfaceCreateInfoKHR value)
Sets the address of the specified |
| public long | |
| public VkRayTracingPipelineCreateInfoKHR | |
| public VkRayTracingPipelineCreateInfoKHR | pNext(VkPipelineCreateFlags2CreateInfoKHR value)
Prepends the specified |
| public VkRayTracingPipelineCreateInfoKHR | pNext(VkPipelineCreationFeedbackCreateInfo value)
Prepends the specified |
| public VkRayTracingPipelineCreateInfoKHR | pNext(VkPipelineCreationFeedbackCreateInfoEXT value)
Prepends the specified |
| public VkRayTracingPipelineCreateInfoKHR | pNext(VkPipelineRobustnessCreateInfoEXT value)
Prepends the specified |
| public VkPipelineShaderStageCreateInfo. | pStages()
a pointer to an array of |
| public VkRayTracingPipelineCreateInfoKHR | pStages(VkPipelineShaderStageCreateInfo.
Sets the address of the specified |
| public VkRayTracingPipelineCreateInfoKHR | set(int sType, long pNext, int flags, VkPipelineShaderStageCreateInfo.
Initializes this struct with the specified values. |
| public VkRayTracingPipelineCreateInfoKHR | Returns: this structthe source struct src)Copies the specified struct data to this struct. |
| public int | |
| public int | |
| public int | |
| public VkRayTracingPipelineCreateInfoKHR | |
| public VkRayTracingPipelineCreateInfoKHR | sType$Default()
Sets the |
| public static void |