From 13d827728ad47f6362258175ac1706ceb6bb8b8d Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Fri, 2 Mar 2012 01:45:23 +0300 Subject: Add opengl settings dump command. Chat command: /dumpogl --- src/commandhandler.cpp | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'src/commandhandler.cpp') diff --git a/src/commandhandler.cpp b/src/commandhandler.cpp index 9f832c021..67b03e78c 100644 --- a/src/commandhandler.cpp +++ b/src/commandhandler.cpp @@ -57,6 +57,10 @@ #include "net/playerhandler.h" #include "net/tradehandler.h" +#if defined USE_OPENGL +#include "openglgraphics.h" +#endif + #ifdef DEBUG_DUMP_LEAKS #include "resources/image.h" #include "resources/resource.h" @@ -207,6 +211,8 @@ void CommandHandler::handleCommand(const std::string &command, ChatTab *tab) handleDumpGraphics(args, tab); else if (type == "dumpt") handleDumpTests(args, tab); + else if (type == "dumpogl") + handleDumpOGL(args, tab); else if (tab->handleCommand(type, args)) ; else if (type == "hack") @@ -1347,3 +1353,11 @@ void CommandHandler::replaceVars(std::string &str) } } } + +void CommandHandler::handleDumpOGL(const std::string &args A_UNUSED, + ChatTab *tab A_UNUSED) +{ +#if defined USE_OPENGL + OpenGLGraphics::dumpSettings(); +#endif +} -- cgit v1.2.3-60-g2f50