In compute pipelines, we can use only compute shaders. But graphics pipelines may contain multiple shader stages--vertex (which is obligatory), geometry, tessellation control and evaluation, and fragment. So for the pipeline to be properly created, we need to specify what programmable shader stages will be active when a given pipeline is bound to a command buffer. And we also need to provide a source code for all the enabled shaders.
Specifying pipeline shader stages
Getting ready
To simplify the recipe and lower the number of parameters needed to prepare descriptions of all enabled shader stages, a custom ShaderStageParameters type is introduced. It has the following definition:
structShaderStageParameters { VkShaderStageFlagBits ShaderStage; VkShaderModule...