Project::OSiRiON - Git repositories
Project::OSiRiON
News . About . Screenshots . Downloads . Forum . Wiki . Tracker . Git
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'src/client/video.cc')
-rw-r--r--src/client/video.cc10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/client/video.cc b/src/client/video.cc
index f7ae792..19555ec 100644
--- a/src/client/video.cc
+++ b/src/client/video.cc
@@ -84,7 +84,8 @@ bool init()
SDL_GL_SetAttribute( SDL_GL_ALPHA_SIZE, 2);
SDL_GL_SetAttribute( SDL_GL_DOUBLEBUFFER, 1 );
- flags = SDL_OPENGL | SDL_FULLSCREEN;
+ if (r_fullscreen->value()) flags = SDL_OPENGL | SDL_FULLSCREEN;
+ else flags = SDL_OPENGL;
if(!SDL_SetVideoMode(width, height, bpp, flags )) {
con_warn << "Failed to set video mode " << width << "x" << height << "x" << bpp << "bpp" << std::endl;
@@ -101,14 +102,15 @@ bool init()
con_print << " video mode " << width << "x" << height << "x" << bpp << "bpp" << std::endl;
aspect = (float) width / (float) height;
-
+ (*r_width) = width;
+ (*r_height) = height;
render::init();
+ video::reset();
+
view::init();
- video::reset();
-
return true;
}