Rendering (drawing a geometry) can only be performed inside render passes. When we also want to perform other operations such as image postprocessing or preparing geometry and light prepass data, we need to order these operations into subpasses. For this, we specify descriptions of all the required attachments, all subpasses into which operations are grouped, and the necessary dependencies between those operations. When this data is prepared, we can create a render pass.
Creating a render pass
Getting ready
To lower the number of parameters that need to be provided, in this recipe, we use a custom structure of type SubpassParameters (refer to the Specifying subpass descriptions recipe).