hachem.wtf
aboutsummaryrefslogtreecommitdiff
path: root/src/platform/vulkan/vulkan_renderer.h
diff options
context:
space:
mode:
authorhachem <im@hachem.wtf>2026-08-19 20:27:03 +0200
committerhachem <im@hachem.wtf>2026-08-19 20:27:03 +0200
commit62ae550170402a0fa0dbbbb2b739176d5c4bcf1e (patch)
treecd2c100676c4d2965d2d3788ba00c7778810c40c /src/platform/vulkan/vulkan_renderer.h
parent0576daa044696e62636a09ad035618dc856a6e8f (diff)
feat: Vulkan renderer and test pipeline
Diffstat (limited to 'src/platform/vulkan/vulkan_renderer.h')
-rw-r--r--src/platform/vulkan/vulkan_renderer.h29
1 files changed, 29 insertions, 0 deletions
diff --git a/src/platform/vulkan/vulkan_renderer.h b/src/platform/vulkan/vulkan_renderer.h
new file mode 100644
index 0000000..0bf2395
--- /dev/null
+++ b/src/platform/vulkan/vulkan_renderer.h
@@ -0,0 +1,29 @@
+#pragma once
+
+#include <glm/glm.hpp>
+#include <functional>
+
+namespace Donut
+{
+ void vulkan_prepare_glfw();
+
+ class VulkanRenderer
+ {
+ public:
+ VulkanRenderer();
+ ~VulkanRenderer();
+
+ bool init(void* glfwWindow, int width, int height);
+ void shutdown();
+
+ bool init_im_gui();
+
+ void draw_frame(const glm::vec4& clear_color, const std::function<void()>& build_ui = {});
+
+ void on_resize(int width, int height);
+
+ private:
+ struct Impl;
+ Impl* m_impl = nullptr;
+ };
+}