From d2b5fc5b3bc648afffa42375706429685ac63794 Mon Sep 17 00:00:00 2001 From: Mel Date: Mon, 12 Feb 2024 12:55:11 +0100 Subject: Split rendering into own thread and sync through render action lists --- src/Game.hpp | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 src/Game.hpp (limited to 'src/Game.hpp') diff --git a/src/Game.hpp b/src/Game.hpp new file mode 100644 index 0000000..ccb0013 --- /dev/null +++ b/src/Game.hpp @@ -0,0 +1,20 @@ +#pragma once +#include "Render.hpp" + +namespace MC { + +class Game { +public: + explicit Game(GFX::Window& window, std::shared_ptr control) + : m_window(window) + , m_render_control(std::move(control)) {} + + void run() const; +private: + void fix_macos_render() const; + + GFX::Window& m_window; + std::shared_ptr m_render_control; +}; + +} -- cgit 1.4.1