summaryrefslogtreecommitdiff
path: root/src/graphicsmanager.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-06-14 16:31:01 +0300
committerAndrei Karas <akaras@inbox.ru>2014-06-14 16:36:05 +0300
commit51a88d35e9b5e473eae80916a894ee95dc0e05d8 (patch)
treede206d344459c96cc5bc8ca3c9a863299922c63b /src/graphicsmanager.cpp
parent75402569f455321e5fd078a57c35b2032a3bdbaf (diff)
downloadmv-51a88d35e9b5e473eae80916a894ee95dc0e05d8.tar.gz
mv-51a88d35e9b5e473eae80916a894ee95dc0e05d8.tar.bz2
mv-51a88d35e9b5e473eae80916a894ee95dc0e05d8.tar.xz
mv-51a88d35e9b5e473eae80916a894ee95dc0e05d8.zip
Add --renderer command flag to override renderer
Diffstat (limited to 'src/graphicsmanager.cpp')
-rw-r--r--src/graphicsmanager.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/graphicsmanager.cpp b/src/graphicsmanager.cpp
index 257d4233e..938c0ccf1 100644
--- a/src/graphicsmanager.cpp
+++ b/src/graphicsmanager.cpp
@@ -254,7 +254,12 @@ void GraphicsManager::createRenderers()
{
RenderType useOpenGL = RENDER_SOFTWARE;
if (!settings.options.noOpenGL)
- useOpenGL = intToRenderType(config.getIntValue("opengl"));
+ {
+ if (settings.options.renderer < 0)
+ useOpenGL = intToRenderType(config.getIntValue("opengl"));
+ else
+ useOpenGL = intToRenderType(settings.options.renderer);
+ }
// Setup image loading for the right image format
ImageHelper::setOpenGlMode(useOpenGL);