Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
May 30, 2015, 12:22:27 PM (9 years ago)
Author:
landauf
Message:

moved static application paths (root, executable, modules) into new class named ApplicationPaths
moved configurable data paths (data, log, config) into new class named ConfigurablePaths
removed PathConfig

Location:
code/branches/core7/src/modules/designtools
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/branches/core7/src/modules/designtools/ScreenshotManager.cc

    r10464 r10509  
    4545#include "core/config/ConfigValueIncludes.h"
    4646#include "core/GraphicsManager.h"
    47 #include "core/PathConfig.h"
     47#include "core/ConfigurablePaths.h"
    4848#include "core/Resource.h"
    4949#include "core/command/ConsoleCommandIncludes.h"
     
    154154        {
    155155            // Save it.
    156             finalImage->save(PathConfig::getInstance().getLogPathString() + "screenshot_" + getTimestamp() + this->fileExtension_);
     156            finalImage->save(ConfigurablePaths::getLogPathString() + "screenshot_" + getTimestamp() + this->fileExtension_);
    157157            delete finalImage;
    158158            orxout(user_info) << "Finished taking " << this->gridSize_*this->windowWidth_ << "x" << this->gridSize_*this->windowHeight_ << " pixel HD screenshot. Storing in log/." << endl;
  • code/branches/core7/src/modules/designtools/SkyboxGenerator.cc

    r10464 r10509  
    4141#include "core/config/ConfigValueIncludes.h"
    4242#include "core/GraphicsManager.h"
    43 #include "core/PathConfig.h"
     43#include "core/ConfigurablePaths.h"
    4444#include "core/Resource.h"
    4545#include "core/command/ConsoleCommandIncludes.h"
     
    175175                this->setupRenderWindow(renderWindow);
    176176                // Add the log path to the standard resource group.
    177                 Ogre::ResourceGroupManager::getSingleton().addResourceLocation(PathConfig::getInstance().getLogPathString(), "FileSystem", Resource::getDefaultResourceGroup());
     177                Ogre::ResourceGroupManager::getSingleton().addResourceLocation(ConfigurablePaths::getLogPathString(), "FileSystem", Resource::getDefaultResourceGroup());
    178178               
    179179                orxout(internal_status) << "Setting up SkyboxGenerator..." << endl;
     
    210210                this->restoreRenderWindow(renderWindow);
    211211                // Remove the log path from the standard resource group.
    212                 Ogre::ResourceGroupManager::getSingleton().removeResourceLocation(PathConfig::getInstance().getLogPathString(), Resource::getDefaultResourceGroup());
     212                Ogre::ResourceGroupManager::getSingleton().removeResourceLocation(ConfigurablePaths::getLogPathString(), Resource::getDefaultResourceGroup());
    213213               
    214214                // Reset the flow parameters for the next skybox generation.
     
    308308    void SkyboxGenerator::saveImage(Ogre::Image* image, const std::string& name) const
    309309    {
    310         image->save(PathConfig::getInstance().getLogPathString()+name);
     310        image->save(ConfigurablePaths::getLogPathString()+name);
    311311        delete image;
    312312        // Loading the resizing, then saving again. This seems stupid, but resizing doesn't seem to work otherwise.
     
    315315        image->load(name, Resource::getDefaultResourceGroup());
    316316        image->resize(this->size_, this->size_);
    317         image->save(PathConfig::getInstance().getLogPathString()+name);
     317        image->save(ConfigurablePaths::getLogPathString()+name);
    318318        delete image;
    319319        ScreenshotManager::getInstance().cleanup(); // Free memory in ScreenshotManager.
Note: See TracChangeset for help on using the changeset viewer.