Home | Namespaces | Hierarchy | Alphabetical List | Class list | Files | Namespace Members | Class members | File members
E:/Programming/MyProject/K_Game_hg/GameEngine/include/engine/EngineSettings.h
Go to the documentation of this file.
00001 // Copyright 2006-2011 by Kat'Oun
00002 
00003 #ifndef _ENGINE_OPTIONS_H_
00004 #define _ENGINE_OPTIONS_H_
00005 
00006 #include <EngineConfig.h>
00007 #include <core/Types.h>
00008 #include <core/Singleton.h>
00009 
00010 #include <string>
00011 
00012 namespace core
00013 {
00014 class ConfigFile;
00015 }
00016 
00017 namespace engine
00018 {
00019 
00020 class ENGINE_PUBLIC_EXPORT EngineSettings: public core::Singleton<EngineSettings>
00021 {
00022 public:
00023 
00024         EngineSettings();
00025         ~EngineSettings();
00026 
00027         u32 getWidth();
00028         u32 getHeight();
00029         u32 getBitdepth();
00030         bool getFullscreen();
00031         bool getVSync();
00032         void* getMainWindowId();
00033 
00034         void setWidth(u32 width);
00035         void setHeight(u32 height);
00036         void setBitdepth(u32 bitdepth);
00037         void setFullscreen(bool fullscreen);
00038         void setVSync(bool vsync);
00039         void setMainWindowID(void* windowId);
00040 
00043         void loadOptions(const std::string& optionsfile);
00044 
00047         void saveOptions(const std::string& optionsfile);
00048 
00049         static EngineSettings* getInstance();
00050 
00051 protected:
00052 
00053         core::ConfigFile* mConfigFile;
00054 
00055         bool mOptionsModified;
00056 
00058         u32 mWidth;
00059         u32 mHeight;
00060         u32 mBitdepth;
00061         bool mFullscreen;
00062         bool mVSync;
00063 
00064         void* mMainWindowId;
00065         //katoun TODO: add other options
00066 };
00067 
00068 } // end namespace engine
00069 
00070 #endif

The KG Game Engine
The KG Game Engine Documentation © 2006-2011 by Kat'Oun. Generated on Sat Jul 2 2011 00:50:04 by Doxygen (1.7.4)