From 290e4c3c33f9af401c0565b840de3514d199faf5 Mon Sep 17 00:00:00 2001 From: ladevieq Date: Thu, 9 Feb 2023 08:26:40 +0100 Subject: Presentation abstraction --- include/api-test/vk-device.hpp | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'include/api-test/vk-device.hpp') diff --git a/include/api-test/vk-device.hpp b/include/api-test/vk-device.hpp index fd69d60..9e42b38 100644 --- a/include/api-test/vk-device.hpp +++ b/include/api-test/vk-device.hpp @@ -72,7 +72,7 @@ class vkdevice { return pipelines[handle.id]; } - [[nodiscard]] inline const device_surface& get_surface(handle handle) const { + [[nodiscard]] inline device_surface& get_surface(handle handle) { return surfaces[handle.id]; } @@ -88,6 +88,10 @@ class vkdevice { return device; } + inline VmaAllocator get_allocator() { + return gpu_allocator; + } + void wait(handle semaphore_handle); void submit(std::span buffers, handle wait_handle, handle signal_handle); @@ -102,8 +106,6 @@ class vkdevice { VkShaderModule create_shader_module(const std::span& shader_code); - void create_views(const texture_desc& desc, device_texture& texture); - void create_swapchain(const surface_desc& desc, device_surface& surface); // TODO: Wrap in a struct called adapter ? @@ -134,9 +136,6 @@ class vkdevice { static constexpr size_t max_allocable_command_buffers = 16; static constexpr size_t max_submitable_command_buffers = 16; - freelist storage_indices; - freelist sampled_indices; - freelist textures; freelist buffers; freelist pipelines; -- cgit v1.3