Changeset 2509 for code/branches/buildsystem2/src/orxonox
- Timestamp:
- Dec 17, 2008, 8:59:48 PM (16 years ago)
- Location:
- code/branches/buildsystem2
- Files:
-
- 1 deleted
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/buildsystem2
- Property svn:ignore deleted
- Property svn:mergeinfo changed
/code/branches/buildsystem (added) merged: 1875,1882-1886,1975-1982,1991,1999,2054,2061,2135,2137-2139,2197-2199,2204,2214-2220,2223-2224,2229,2233-2244,2248-2249,2252-2253,2260,2275
-
code/branches/buildsystem2/src/orxonox/CMakeLists.txt
r2171 r2509 6 6 PlayerManager.cc 7 7 Settings.cc 8 9 tolua/tolua_bind.cc10 8 ) 11 9 … … 16 14 ADD_SOURCE_DIRECTORY(ORXONOX_SRC_FILES tools) 17 15 18 GET_TARGET_PROPERTY(TOLUA_EXE tolua_orxonox LOCATION) 19 ADD_CUSTOM_COMMAND( 20 OUTPUT ${CMAKE_CURRENT_SOURCE_DIR}/tolua/tolua_bind.cc ${CMAKE_CURRENT_SOURCE_DIR}/tolua/tolua_bind.h 21 COMMAND ${TOLUA_EXE} -n Orxonox -o ../../src/orxonox/tolua/tolua_bind.cc -H ../../src/orxonox/tolua/tolua_bind.h ../../src/orxonox/tolua/tolua.pkg 22 DEPENDS 23 tolua_orxonox 24 tolua/tolua.pkg 25 gui/GUIManager.h 26 WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/bin/lib 27 ) 16 INCLUDE(UseTolua) 17 TOLUA(Orxonox ORXONOX_SRC_FILES INPUTFILES gui/GUIManager.h) 28 18 29 19 … … 42 32 43 33 TARGET_LINK_LIBRARIES( orxonox 44 ${OGRE_LIBRARIES} 45 ${CEGUI_LIBRARIES} 46 lua_orxonox 34 ${OGRE_LIBRARY} 35 ${CEGUI_LIBRARY} 36 ${LUA_LIBRARIES} 37 #${CEGUI_SCRIPT_LIBRARIES} 47 38 ceguilua_orxonox 48 39 tinyxml_orxonox … … 53 44 network 54 45 ) 55 -
code/branches/buildsystem2/src/orxonox/Settings.cc
r2087 r2509 63 63 void Settings::setConfigValues() 64 64 { 65 SetConfigValue(dataPath_, "../../ media/").description("Relative path to the game data.").callback(this, &Settings::dataPathChanged);65 SetConfigValue(dataPath_, "../../../media/").description("Relative path to the game data.").callback(this, &Settings::dataPathChanged); 66 66 } 67 67 -
code/branches/buildsystem2/src/orxonox/gamestates/GSGraphics.cc
r2171 r2509 44 44 #include "util/Debug.h" 45 45 #include "util/Exception.h" 46 #include "util/String.h" 47 #include "util/SubString.h" 46 48 #include "core/ConsoleCommand.h" 47 49 #include "core/ConfigValueIncludes.h" … … 96 98 SetConfigValue(ogreConfigFile_, "ogre.cfg") 97 99 .description("Location of the Ogre config file"); 98 SetConfigValue(ogrePluginsFile_, "plugins.cfg") 99 .description("Location of the Ogre plugins file"); 100 SetConfigValue(ogrePluginsFolder_, ".") 101 .description("Folder where the Ogre plugins are located."); 102 SetConfigValue(ogrePlugins_, "RenderSystem_GL, Plugin_ParticleFX") 103 .description("Comma separated list of all plugins to load."); 100 104 SetConfigValue(ogreLogFile_, "ogre.log") 101 105 .description("Logfile for messages from Ogre. Use \"\" to suppress log file creation."); … … 121 125 // Ogre setup procedure 122 126 setupOgre(); 127 // load all the required plugins for Ogre 128 loadOgrePlugins(); 129 // read resource declaration file 123 130 this->declareResources(); 124 this->loadRenderer(); // creates the render window 131 // Reads ogre config and creates the render window 132 this->loadRenderer(); 133 125 134 // TODO: Spread this so that this call only initialises things needed for the Console and GUI 126 135 this->initialiseResources(); … … 345 354 probe.close(); 346 355 347 ogreRoot_ = new Ogre::Root(ogrePluginsFile_, ogreConfigFile_, ogreLogFile_); 356 // Leave plugins file empty. We're going to do that part manually later 357 ogreRoot_ = new Ogre::Root("", ogreConfigFile_, ogreLogFile_); 348 358 349 359 #if 0 // Ogre 1.4.3 doesn't yet support setDebugOutputEnabled(.) … … 358 368 359 369 COUT(3) << "Ogre set up done." << std::endl; 370 } 371 372 void GSGraphics::loadOgrePlugins() 373 { 374 // just to make sure the next statement doesn't segfault 375 if (ogrePluginsFolder_ == "") 376 ogrePluginsFolder_ = "."; 377 378 #if ORXONOX_PLATFORM == ORXONOX_PLATFORM_WIN32 379 convertToWindowsPath(&ogrePluginsFolder_); 380 #else 381 convertToUnixPath(&ogrePluginsFolder_); 382 #endif 383 384 // Do some SubString magic to get the comma separated list of plugins 385 SubString plugins(ogrePlugins_, ",", " ", false, 92, false, 34, false, 40, 41, false, '\0'); 386 for (unsigned int i = 0; i < plugins.size(); ++i) 387 ogreRoot_->loadPlugin(ogrePluginsFolder_ + plugins[i]); 360 388 } 361 389 -
code/branches/buildsystem2/src/orxonox/gamestates/GSGraphics.h
r2103 r2509 60 60 61 61 void setupOgre(); 62 void loadOgrePlugins(); 62 63 void declareResources(); 63 64 void loadRenderer(); … … 105 106 std::string resourceFile_; //!< resources file name 106 107 std::string ogreConfigFile_; //!< ogre config file name 107 std::string ogrePluginsFile_; //!< ogre plugins file name 108 std::string ogrePluginsFolder_; //!< Folder where the Ogre plugins are located 109 std::string ogrePlugins_; //!< Comma separated list of all plugins to load 108 110 std::string ogreLogFile_; //!< log file name for Ogre log messages 109 111 int ogreLogLevelTrivial_; //!< Corresponding Orxonx debug level for LL_TRIVIAL -
code/branches/buildsystem2/src/orxonox/gui/GUIManager.cc
r2087 r2509 39 39 #include <OgreRoot.h> 40 40 #include <CEGUI.h> 41 #include "ceguilua/CEGUILua.h"41 #include <CEGUILua.h> 42 42 #include "util/Exception.h" 43 43 #include "core/input/InputManager.h" 44 44 #include "core/input/SimpleInputState.h" 45 #include "core/tolua/tolua_bind.h"46 45 #include "core/ConsoleCommand.h" 47 46 #include "core/Core.h" 48 #include "tolua/tolua_bind.h" 47 #include "core/ToluaBindCore.h" 48 #include "orxonox/ToluaBindOrxonox.h" 49 49 #include "OgreCEGUIRenderer.h" 50 50 51 #include "lua/lua.hpp" 51 extern "C" { 52 #include "lua.h" 53 } 52 54 53 55 namespace orxonox -
code/branches/buildsystem2/src/orxonox/gui/GUIManager.h
r1887 r2509 42 42 #include "core/input/InputInterfaces.h" 43 43 44 namespace orxonox // tolua_export 45 { // tolua_export 44 // tolua_begin 45 namespace orxonox 46 { 46 47 /** 47 48 @brief 48 49 Provides a simple interface to CEGUI with tolua methods and console commands 49 50 */ 50 class _OrxonoxExport GUIManager : public KeyHandler, public MouseHandler51 /* 52 class GUIManager { // tolua_export53 */ 51 class _OrxonoxExport GUIManager 52 // tolua_end 53 : public KeyHandler, public MouseHandler 54 // tolua_begin 54 55 { 56 // tolua_end 55 57 public: 56 58 enum State
Note: See TracChangeset
for help on using the changeset viewer.