C Specification
To create graphics pipelines, call:
// Provided by VK_VERSION_1_0
VkResult vkCreateGraphicsPipelines(
VkDevice device,
VkPipelineCache pipelineCache,
uint32_t createInfoCount,
const VkGraphicsPipelineCreateInfo* pCreateInfos,
const VkAllocationCallbacks* pAllocator,
VkPipeline* pPipelines);
Parameters
-
deviceis the logical device that creates the graphics pipelines. -
pipelineCacheis the handle of a valid VkPipelineCache object. The implementation must not access this object outside of the duration of this command. -
createInfoCountis the length of thepCreateInfosandpPipelinesarrays. -
pCreateInfosis a pointer to an array of VkGraphicsPipelineCreateInfo structures. -
pAllocatorcontrols host memory allocation as described in the Memory Allocation chapter. -
pPipelinesis a pointer to an array of VkPipeline handles in which the resulting graphics pipeline objects are returned.
Description
The VkGraphicsPipelineCreateInfo structure includes an array of VkPipelineShaderStageCreateInfo structures for each of the desired active shader stages, as well as creation information for all relevant fixed-function stages, and a pipeline layout.
Pipelines are created and returned as described for Multiple Pipeline Creation.
If a pipeline creation fails due to:
-
The identified pipeline not being present in
pipelineCache -
The
pNextchain not including a VkPipelineOfflineCreateInfo structure
the operation will continue as specified in Multiple
Pipeline Creation and the command will return
VK_ERROR_NO_PIPELINE_MATCH.
If
VkPhysicalDeviceVulkanSC10Properties::deviceNoDynamicHostAllocations
is VK_TRUE, vkCreateGraphicsPipelines must not return
VK_ERROR_OUT_OF_HOST_MEMORY.
Document Notes
For more information, see the Vulkan Specification
This page is extracted from the Vulkan Specification. Fixes and changes should be made to the Specification, not directly.