Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 4777 in orxonox.OLD for orxonox/trunk/src/lib/graphics


Ignore:
Timestamp:
Jul 2, 2005, 7:21:50 PM (19 years ago)
Author:
bensch
Message:

orxonox/trunk: ability to disable textures

Location:
orxonox/trunk/src/lib/graphics
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/lib/graphics/graphics_engine.cc

    r4770 r4777  
    112112 * @returns nothing usefull
    113113 */
    114 int GraphicsEngine::loadFromIniFile(IniParser* iniParser, const char* section)
     114int GraphicsEngine::loadFromIniFile(IniParser* iniParser)
    115115{
    116116  // searching for a usefull resolution
    117   SubString resolution(iniParser->getVar(CONFIG_NAME_RESOLUTION, section, "640x480"), 'x');
     117  SubString resolution(iniParser->getVar(CONFIG_NAME_RESOLUTION, CONFIG_SECTION_VIDEO, "640x480"), 'x');
    118118  this->setResolution(atoi(resolution.getString(0)), atoi(resolution.getString(1)), 16);
    119119
    120120  // looking if we are in fullscreen-mode
    121   const char* fullscreen = iniParser->getVar(CONFIG_NAME_FULLSCREEN, section, "0");
     121  const char* fullscreen = iniParser->getVar(CONFIG_NAME_FULLSCREEN, CONFIG_SECTION_VIDEO, "0");
    122122  if (strchr(fullscreen, '1'))
    123123    this->setFullscreen(true);
     124
     125  // looking if we are in fullscreen-mode
     126  const char* textures = iniParser->getVar(CONFIG_NAME_TEXTURES, CONFIG_SECTION_VIDEO_ADVANCED, "0");
     127  if (strchr(textures, '1'))
     128    this->texturesEnabled = true;
     129  else
     130    this->texturesEnabled = false;
     131
    124132}
    125133
  • orxonox/trunk/src/lib/graphics/graphics_engine.h

    r4770 r4777  
    3131
    3232    int initVideo();
    33     int loadFromIniFile(IniParser* iniParser, const char* section);
     33    int loadFromIniFile(IniParser* iniParser);
    3434
    3535    void setWindowName(const char* windowName, const char* icon);
Note: See TracChangeset for help on using the changeset viewer.