diff options
author | Dan Goodliffe <dan@randomdan.homeip.net> | 2021-01-16 18:09:15 +0000 |
---|---|---|
committer | Dan Goodliffe <dan@randomdan.homeip.net> | 2021-01-16 18:09:15 +0000 |
commit | 400410fcd436d5e4310bfa779f0309c5fae5b2c2 (patch) | |
tree | 89661918c487e63b6c71f2e9281b553928010606 /display.h | |
download | ilt-400410fcd436d5e4310bfa779f0309c5fae5b2c2.tar.bz2 ilt-400410fcd436d5e4310bfa779f0309c5fae5b2c2.tar.xz ilt-400410fcd436d5e4310bfa779f0309c5fae5b2c2.zip |
Initial commit
Stripped back and formatted from https://github.com/BennyQBD/ModernOpenGLTutorial/
Diffstat (limited to 'display.h')
-rw-r--r-- | display.h | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/display.h b/display.h new file mode 100644 index 0000000..2573130 --- /dev/null +++ b/display.h @@ -0,0 +1,28 @@ +#ifndef DISPLAY_INCLUDED_H
+#define DISPLAY_INCLUDED_H
+
+#include <SDL2/SDL.h>
+#include <string>
+
+class Display {
+public:
+ Display(int width, int height, const std::string & title);
+
+ void Clear(float r, float g, float b, float a);
+ void SwapBuffers();
+
+ virtual ~Display();
+
+protected:
+private:
+ void
+ operator=(const Display & display)
+ {
+ }
+ Display(const Display & display) { }
+
+ SDL_Window * m_window;
+ SDL_GLContext m_glContext;
+};
+
+#endif
|