|
Atomic Engine
Atomic Engine is a cross-platform vulkan based 3D Game Engine
|
Manages Vulkan physical devices and their suitability for rendering. More...
#include <device.h>
Public Member Functions | |
| VkDeviceManager (VkInstance instance) | |
| Constructs a VkDeviceManager instance. | |
| ~VkDeviceManager () | |
| Destroys the VkDeviceManager instance and releases resources. | |
Private Member Functions | |
| int | rateDeviceSuitability (VkPhysicalDevice device) |
| Rates the suitability of a Vulkan physical device. | |
| bool | isDeviceSuitable (VkPhysicalDevice device) |
| Checks if a Vulkan physical device is suitable for rendering. | |
Private Attributes | |
| VkPhysicalDevice | physicalDevice = VK_NULL_HANDLE |
| The selected Vulkan physical device. This device is the one that will be used for rendering by vulkan. | |
| uint32_t | deviceCount = 0 |
| The number of Vulkan physical devices available. The number of all the devices available on the system. | |
| std::vector< VkPhysicalDevice > | devices |
| List of all available Vulkan physical devices. Lists all the devices available on the system including those not usable by vulkan. | |
| std::multimap< int, VkPhysicalDevice > | deviceCandidates |
| Ordered map to rank physical devices by their suitability score. This map is used to sort the devices based on their suitability for rendering. It only includes devices usable by vulkan and has them ranked by their suitability score. | |
| atomic::render::vkLib::device::QueueFamilyIndices | queueFamilyIndices |
| Queue family indices for the selected physical device. | |
Manages Vulkan physical devices and their suitability for rendering.
This class is responsible for selecting a suitable Vulkan physical device, managing queue family indices, and maintaining a list of available devices.
| atomic::render::vkLib::VkDeviceManager::VkDeviceManager | ( | VkInstance | instance | ) |
Constructs a VkDeviceManager instance.
| instance | The Vulkan instance used to query physical devices. |
|
private |
Checks if a Vulkan physical device is suitable for rendering.
| device | The Vulkan physical device to check. |
|
private |
Rates the suitability of a Vulkan physical device.
This function evaluates the device based on various criteria :
No geomtry shader support : score = 0
| device | The Vulkan physical device to evaluate. |