gfx_settings.hh

Go to the documentation of this file.
00001 /*
00014  * LEGAL:   COPYRIGHT (C) 2007 JIM E. BROOKS
00015  *          THIS SOURCE CODE IS RELEASED UNDER THE TERMS
00016  *          OF THE GNU GENERAL PUBLIC LICENSE VERSION 2 (GPL 2).
00017  *****************************************************************************/
00018 
00019 #ifndef GFX_SETTINGS_HH
00020 #define GFX_SETTINGS_HH 1
00021 
00022 #include "base_conf_reader.hh"
00023 
00024 namespace gfx {
00025 
00031 class Settings
00032 {
00033 public: //private:  // p51 accesses SettingsConfReader
00034 
00042     class SettingsConfReader : public ConfReader
00043     {
00044     public:
00045         void ProcessField( string& field, ifstream& conf );
00046     };
00047 
00048 public:
00049             Settings( void );
00050 
00051     SettingsConfReader  mSettingsConfReader;
00052 
00053     // settings.conf:
00054     int     mWindowWidth;
00055     int     mWindowHeight;
00056     Degree  mPerspectiveFov;
00057     fp      mPerspectiveFrustumNear;
00058     fp      mPerspectiveFrustumFar;
00059     RGBA    mSkyColor;
00060     RGBA    mFogColor;
00061     string  mFogMode;
00062     fp      mBaseFogDensity;
00063     uint    mAntialias;
00064     fp      mCullVolumeScale;
00065 
00066     // settings.conf: Timer:
00067     Milliseconds    mTimerTickFreq;
00068     Milliseconds    mKeyboardTickFreq;
00069     Milliseconds    mJoystickTickFreq;
00070     uint            mKeyboardInputQueueOverflow;
00071     uint            mJoystickInputQueueOverflow;
00072 };
00073 
00074 ostream& operator<<( ostream& strm, const Settings& settings );
00075 
00076 #if GFX_SETTINGS_CC
00077 Settings gSettings;
00078 #else
00079 extern Settings gSettings;
00080 #endif
00081 
00082 } // namespace gfx
00083 
00084 #endif // GFX_SETTINGS_HH
Palomino 3D Engine documents generated by doxygen 1.5.3 on Fri Nov 23 11:26:11 2007