O'Reilly logo

Learning Vulkan by Parminder Singh

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Implementing devices and queues all together

In this section, we will revisit all of the knowledge we've gathered in this chapter so far and implement a program to create the device and queues from an application's view. Let's look at a step-by-step process that describes the flow of information.

First, enumerate the physical devices on the system using enumeratePhysicalDevices(); the retrieved physical device is stored in the gpuList vector. For the sake of simplicity, we are assuming the system has only one GPU (using the first element of gpuList). Next, we handshake with the device using the handShakeWithDevice() function:

/********** VulkanApplication.cpp **********/

// Get the list of physical devices on the system vector<VkPhysicalDevice> ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required