Changeset c559904 in opengl-game for opengl-game.cpp
- Timestamp:
- Sep 14, 2019, 12:58:30 AM (5 years ago)
- Branches:
- feature/imgui-sdl, master, points-test
- Children:
- 09e15a4
- Parents:
- 2e77b3f
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
opengl-game.cpp
r2e77b3f rc559904 4 4 5 5 #include "consts.hpp" 6 #include "logger.hpp" 6 7 7 8 using namespace std; … … 24 25 cout << "OpenGL Game" << endl; 25 26 27 // TODO: Refactor the logger api to be more flexible, 28 // esp. since gl_log() and gl_log_err() have issues printing anything besides stirngs 29 restart_gl_log(); 30 gl_log("starting GLFW\n%s", glfwGetVersionString()); 31 32 open_log(); 33 get_log() << "starting GLFW" << endl; 34 get_log() << glfwGetVersionString() << endl; 35 26 36 if (initWindow(width, height, guiFlags) == RTWO_ERROR) { 27 37 return; … … 31 41 mainLoop(); 32 42 cleanup(); 43 44 close_log(); 33 45 } 34 46 47 // TODO: Make some more initi functions, or call this initUI if the 48 // amount of things initialized here keeps growing 35 49 bool OpenGLGame::initWindow(int width, int height, unsigned char guiFlags) { 50 // TODO: Put all fonts, textures, and images in the assets folder 36 51 gui = new GameGui_GLFW(); 37 52 38 53 if (gui->init() == RTWO_ERROR) { 54 // TODO: Also print these sorts of errors to the log 39 55 cout << "UI library could not be initialized!" << endl; 40 56 cout << gui->getError() << endl;
Note:
See TracChangeset
for help on using the changeset viewer.