Silence some warnings

This commit is contained in:
Georg Hagen
2024-07-02 21:29:15 +02:00
parent c008c98311
commit fa51f868b7
10 changed files with 36 additions and 13 deletions

View File

@@ -13,8 +13,9 @@
namespace OpenVulkano::Vulkan
{
struct VulkanNode : IRecordable, ICloseable
class VulkanNode : public IRecordable, public ICloseable
{
public:
Scene::Node* node = nullptr;
UniformBuffer* buffer = nullptr;

View File

@@ -10,6 +10,7 @@
#include "Image.hpp"
#include "FrameBuffer.hpp"
#include "Base/UI/IWindow.hpp"
#include "Base/Logger.hpp"
#include <vulkan/vulkan.hpp>
namespace OpenVulkano
@@ -90,15 +91,19 @@ namespace OpenVulkano
void Present(vk::Queue& queue ,std::vector<vk::Semaphore>& semaphores) const
{
queue.presentKHR(vk::PresentInfoKHR(semaphores.size(), semaphores.data(),
const vk::Result result = queue.presentKHR(vk::PresentInfoKHR(semaphores.size(), semaphores.data(),
1, &swapChain, &currentFrameBufferId));
if (result != vk::Result::eSuccess) [[unlikely]]
{
Logger::RENDER->error("Failed to preset swap chain image: {}", to_string(result));
}
}
[[nodiscard]] bool UseVsync() const { return useVsync; }
void SetVsync(bool useVsync)
void SetVsync(bool vsync)
{ //TODO change swap chain
this->useVsync = useVsync;
this->useVsync = vsync;
}
[[nodiscard]] uint32_t GetImageCount() const