3
Building a Vulkan Renderer
Welcome to Chapter 3! In the previous chapter, we took a deeper look into OpenGL as a method to get some polygons onto your screen. In this chapter, we will move on to its successor, Vulkan, which aims to give you much more control of your graphics hardware, thus resulting in improved performance.
Vulkan is a quite complex and also verbose API. You will have to create a lot of objects to get even a single colored triangle onto your screen, resulting in the creation of hundreds of C++ lines before you see anything. But you also get advanced error handling and debugging with an extra validation layer, allowing you to easily see where you have missed something or where an operation failed.
Due to the extensive amount of code needed for the basics, this chapter gives only a broad overview of the internals of Vulkan, plus some code snippets to explain how to initialize some of the objects. The complete rendering code for this chapter can be found in...