summaryrefslogtreecommitdiff
path: root/inc/sdl/window.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'inc/sdl/window.hpp')
-rw-r--r--inc/sdl/window.hpp27
1 files changed, 27 insertions, 0 deletions
diff --git a/inc/sdl/window.hpp b/inc/sdl/window.hpp
new file mode 100644
index 0000000..fc0f325
--- /dev/null
+++ b/inc/sdl/window.hpp
@@ -0,0 +1,27 @@
+#ifndef window_h
+#define window_h
+
+#include <SDL2/SDL.h>
+#include <string>
+#include <iostream>
+#include <GL/glew.h>
+
+#include "constants.hpp"
+
+class Window
+{
+ public:
+ Window(int width, int height, const std::string& title);
+ void Clear(float r, float g, float b, float a);
+ void swapBuffers();
+ bool getClosed(){return closed;};
+
+ virtual ~Window();
+
+ private:
+ SDL_Window* main;
+ SDL_GLContext glContext;
+ bool closed;
+};
+
+#endif