stories/engine/physicaldevice.h

32 lines
671 B
C
Raw Permalink Normal View History

2023-09-24 16:16:10 +00:00
#pragma once
#include <set>
#include <string>
#include <vector>
#include <vulkan/vulkan.h>
#include "utils.h"
#include "surface.h"
2023-09-24 16:16:10 +00:00
namespace Engine {
class LogicalDevice;
class PhysicalDevice {
friend class LogicalDevice;
public:
PhysicalDevice(VkPhysicalDevice raw, const QueueFamilyIndices& indices, const SwapChainSupportDetails& swapChainSupport);
void recreateSwapChainSupportDetails(const Surface* surface);
2023-09-24 16:16:10 +00:00
static bool checkDeviceExtensionSupport(VkPhysicalDevice device, std::set<std::string> requiredExtensions);
const QueueFamilyIndices indices;
SwapChainSupportDetails swapChainSupport;
2023-09-24 16:16:10 +00:00
private:
VkPhysicalDevice vk;
};
}