Changeset 1652 for code/branches/gui/src/orxonox/GraphicsEngine.cc
- Timestamp:
- Jul 28, 2008, 8:45:31 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/gui/src/orxonox/GraphicsEngine.cc
r1651 r1652 267 267 } 268 268 269 boolGraphicsEngine::loadRenderer()269 void GraphicsEngine::loadRenderer() 270 270 { 271 271 CCOUT(4) << "Configuring Renderer" << std::endl; … … 286 286 if (!root_->restoreConfig()) 287 287 if (!root_->showConfigDialog()) 288 return false;288 ThrowException(InitialisationFailed, "Could not show Ogre configuration dialogue."); 289 289 290 290 CCOUT(4) << "Creating render window" << std::endl; 291 try 292 { 293 this->renderWindow_ = root_->initialise(true, "OrxonoxV2"); 294 } 295 catch (std::exception& ex) 296 { 297 COUT(2) << "Error: There was an exception when initialising Ogre Root." << std::endl; 298 COUT(1) << ex.what() << std::endl; 299 return false; 300 } 301 302 if (!root_->isInitialised()) 303 { 304 CCOUT(2) << "Error: Initialising Ogre root object failed." << std::endl; 305 return false; 306 } 291 292 this->renderWindow_ = root_->initialise(true, "OrxonoxV2"); 293 307 294 Ogre::WindowEventUtilities::addWindowEventListener(this->renderWindow_, this); 295 308 296 //Ogre::TextureManager::getSingleton().setDefaultNumMipmaps(5); 309 297 310 // create a full screen viewport298 // create a full screen default viewport 311 299 this->viewport_ = this->renderWindow_->addViewport(0, 0); 312 313 return true;314 300 } 315 301
Note: See TracChangeset
for help on using the changeset viewer.