summaryrefslogtreecommitdiff
path: root/src/client.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2012-05-19 21:34:11 +0300
committerAndrei Karas <akaras@inbox.ru>2012-05-19 21:45:37 +0300
commitf0a7d551bad15085c1f72df38b6a216c8bf3127d (patch)
tree46812143c8d811c8cf43897d4fa1898d3c83ad5e /src/client.cpp
parentcc7e9dc6e6f7a006db7417fd9b7d93d587e27529 (diff)
downloadmv-f0a7d551bad15085c1f72df38b6a216c8bf3127d.tar.gz
mv-f0a7d551bad15085c1f72df38b6a216c8bf3127d.tar.bz2
mv-f0a7d551bad15085c1f72df38b6a216c8bf3127d.tar.xz
mv-f0a7d551bad15085c1f72df38b6a216c8bf3127d.zip
Auto detect better video mode at first start.
Diffstat (limited to 'src/client.cpp')
-rw-r--r--src/client.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/client.cpp b/src/client.cpp
index 383a40da1..e7083f943 100644
--- a/src/client.cpp
+++ b/src/client.cpp
@@ -508,6 +508,15 @@ void Client::gameInit()
}
#endif
+#ifdef WIN32
+ if (mOptions.test.empty() && !config.getBoolValue("videodetected"))
+ {
+ int val = graphicsManager.startDetection();
+ if (val >= 0 && val <= 2)
+ config.setValue("opengl", val);
+ config.setValue("videodetected", true);
+ }
+#endif
graphicsManager.initGraphics(mOptions.noOpenGL);
runCounters = config.getBoolValue("packetcounters");