X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fapp.cpp;h=a6f81f1210ecb677e0043341792ab8a0f9dba8ae;hb=d2d3cb877984b97fafb97254f5005cbf4bcf47a6;hp=cfb16822897a01027da39d62c3624da6fe7fd52b;hpb=46509f82dcea114b004c53a7f3a9608f2518077f;p=blank.git diff --git a/src/app.cpp b/src/app.cpp index cfb1682..a6f81f1 100644 --- a/src/app.cpp +++ b/src/app.cpp @@ -6,20 +6,22 @@ namespace blank { -Application::Application() +Application::Application(const Config &config) : init_sdl() , init_img() -, init_gl() +, init_gl(config.doublebuf, config.multisampling) , window() , ctx(window.CreateContext()) , init_glew() , program() , cam() -, world() -, interface(world) +, world(config.world) +, interface(config.interface, world) , test_controller(MakeTestEntity(world)) , running(false) { - GLContext::EnableVSync(); + if (config.vsync) { + GLContext::EnableVSync(); + } glClearColor(0.0, 0.0, 0.0, 1.0); }