Display class

This commit is contained in:
Ben
2019-02-21 17:40:45 +00:00
parent 77426b504c
commit 684c14eda0
7 changed files with 136 additions and 33 deletions

View File

@@ -2,9 +2,9 @@
#include <chrono>
#include <vector>
#include <glm/glm.hpp>
#include <glm/gtc/matrix_transform.hpp>
#include <glm/gtc/type_ptr.hpp>
// #include <glm/glm.hpp>
// #include <glm/gtc/matrix_transform.hpp>
// #include <glm/gtc/type_ptr.hpp>
// Custom includes
#define LOGGER_DEFINITION
@@ -13,10 +13,22 @@
#include "display.h"
int main (int argc, char** argv) {
Logger logger;
Display display {"SMH Engine", 1280, 720, logger, MXAA_8X, VSYNC_ENABLED};
std::cout << "-----------------------------\n"
<< "----- SMH Render Engine -----\n"
<< "-------- Version 0.0 --------\n"
<< "----- ©Benjamin Kyd 2019 ----\n"
<< "-----------------------------\n\n";
Logger logger;
Display display {"SMH Engine", logger, 1280, 720, MXAA_4X, VSYNC_ENABLED};
SDL_Event e;
while (!display.isClosed)
while (SDL_PollEvent(&e))
if (e.type == SDL_QUIT || e.key.keysym.sym == SDLK_ESCAPE)
display.isClosed = true;
return 0;
}