Drawing is the operation we usually want to perform using graphics APIs such as OpenGL or Vulkan. It sends the geometry (vertices) provided by the application through a vertex buffer down the graphics pipeline, where it is processed step by step by programmable shaders and fixed-function stages.
Drawing requires us to provide the number of vertices we would like to process (display). It also allows us to display multiple instances of the same geometry at once.
Drawing a geometry
How to do it...
- Store the handle of a command buffer in a variable of type VkCommandBuffer named command_buffer. Make sure the command buffer is currently being recorded and that the parameters of all the states used during rendering are already set in it (bound to it). Also, make sure that...