summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVegard Storheil Eriksen <zyp@jvnv.net>2010-05-20 20:18:04 +0200
committerVegard Storheil Eriksen <zyp@jvnv.net>2010-05-20 20:18:04 +0200
commit4a8b02adbc01bad1a20bcdc16b858d879cf47e11 (patch)
treee0cdf870a1f723b05810b1f8777862977a1af7ef
parent66edbd1db3e2b0edf2e3e00136719bb664aaf489 (diff)
Enabled vsync.
-rw-r--r--application.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/application.cpp b/application.cpp
index c2f5f71..38448ec 100644
--- a/application.cpp
+++ b/application.cpp
@@ -105,6 +105,8 @@ Application::Application() {
SDL_GL_SetAttribute(SDL_GL_DEPTH_SIZE, 24);
+ SDL_GL_SetAttribute(SDL_GL_SWAP_CONTROL, 1);
+
// Get our surface
surface = SDL_SetVideoMode(Config::window_w, Config::window_h, 32, flags);
if(!surface) {
@@ -178,7 +180,7 @@ void Application::run() {
main_loop(tick, step);
- SDL_Delay(10);
+ //SDL_Delay(10);
}
}