X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fapp.hpp;h=6bd4e0d9a14a65e615eb62f9f14df5f8b33f5c9b;hb=9c2baccb84195b7a2858c2b967c94d15cd31836b;hp=4e381a2a2fa6d7e388ab3884ad7dc33f0227eaf5;hpb=d18be10ef3f0a7b61c6f5c4c4096ca2b776c75b3;p=blank.git diff --git a/src/app.hpp b/src/app.hpp index 4e381a2..6bd4e0d 100644 --- a/src/app.hpp +++ b/src/app.hpp @@ -1,13 +1,11 @@ #ifndef BLANK_APP_HPP_ #define BLANK_APP_HPP_ -#include -#include - #include "camera.hpp" #include "init.hpp" -#include "model.hpp" +#include "interface.hpp" #include "shader.hpp" +#include "world.hpp" namespace blank { @@ -16,15 +14,23 @@ class Application { public: Application(); - ~Application(); Application(const Application &) = delete; Application &operator =(const Application &) = delete; + /// run until user quits void Run(); void Loop(int dt); + /// run for n frames + void RunN(size_t n); + /// run for t milliseconds + void RunT(size_t t); + /// run for n frames, assuming t milliseconds for each + void RunS(size_t n, size_t t); + void HandleEvents(); + void Update(int dt); void Render(); private: @@ -34,13 +40,11 @@ private: Window window; GLContext ctx; InitGLEW init_glew; - Program program; + DirectionalLighting program; Camera cam; - Model model; - - GLuint vtx_buf; - GLuint mvp_handle; + World world; + Interface interface; bool running;