How to do it...

  1. Create a Vulkan instance and a logical device with a set of enabled swapchain extensions. Also store the handle of a physical device from which the logical device was created (refer to the Creating a Vulkan Instance with WSI extensions enabled and Creating a logical device with WSI extensions enabled recipes from Chapter 2, Image Presentation).
  2. Acquire handles of graphics and presentation queues from the logical device (refer to the Getting a device queue recipe from Chapter 1, Instance and Devices).
  3. Create a swapchain with a desired set of parameters. Store the swapchain's size (image dimensions) and format (refer to the Creating a swapchain with R8G8B8A8 format and a MAILBOX present mode recipe from Chapter 2, Image Presentation ...

Get Vulkan Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.