summaryrefslogtreecommitdiff
path: root/graphics.hpp
diff options
context:
space:
mode:
authorOxore <oxore@protonmail.com>2022-10-19 02:28:03 +0300
committerOxore <oxore@protonmail.com>2022-10-19 02:28:03 +0300
commiteddd0a826b1720c26b0ac5df0269db3982bc8f35 (patch)
tree94548f986eb190c734315db252e57a79c118031f /graphics.hpp
parentae9a7aef2f0422f6872e6ae27e4e4e2084d8ce8f (diff)
Begin implementing VDP rendering
Diffstat (limited to 'graphics.hpp')
-rw-r--r--graphics.hpp26
1 files changed, 26 insertions, 0 deletions
diff --git a/graphics.hpp b/graphics.hpp
new file mode 100644
index 0000000..a88cd61
--- /dev/null
+++ b/graphics.hpp
@@ -0,0 +1,26 @@
+/* SPDX-License-Identifier: Unlicense
+ */
+
+#pragma once
+
+class VDP;
+
+#if defined(HAS_GRAPHICS) && HAS_GRAPHICS == 1
+# include "SDL.h"
+#endif
+
+class Graphics {
+public:
+ Graphics();
+ ~Graphics();
+ bool IsOk() const { return _initialized_ok; }
+ void Render(const VDP&);
+
+private:
+ bool _initialized_ok{};
+#if defined(HAS_GRAPHICS) && HAS_GRAPHICS == 1
+ SDL_Renderer* _renderer{};
+ SDL_Window* _window{};
+ SDL_Texture* _render_texture{};
+#endif
+};