Debian Codegraph @

src/globalvar.h

raw symbols SCIP
1 /***************************************************************************
2 globalvar.h - description
3 -------------------
4 begin : october 17th, 2006
5 copyright : (C) 2006-2008 by Duong Khang NGUYEN
6 email : neoneurone @ gmail com
7
8 $Id: globalvar.h 421 2009-10-10 12:22:14Z neoneurone $
9 ***************************************************************************/
10
11 /***************************************************************************
12 * *
13 * This program is free software; you can redistribute it and/or modify *
14 * it under the terms of the GNU General Public License as published by *
15 * the Free Software Foundation; either version 2 of the License, or *
16 * any later version. *
17 * *
18 ***************************************************************************/
19
20 #ifndef _OPENCITY_GLOBALVAR_H_
21 #define _OPENCITY_GLOBALVAR_H_ 1
22
23 #ifdef OPENCITY_SDL_MIXER
24 #include "audiomanagersdl.h" // SDL_mixer audio support
25 #else
26 #include "audiomanager.h" // Dummy audio support
27 #endif
28
29 #include "main.h" // Main defines
30 #include "extensionmanager.h" // OpenGL extension manager
31 #include "graphicmanager.h" // Graphic object manager
32 #include "map.h" // Height map handling
33 #include "propertymanager.h" // Structure properties manager
34 #include "renderer.h" // Video renderer
35 #include "networking.h" // Networking support
36 #include "movementmanager.h" // Moving object manager
37 #include "kernel.h" // MAS kernel
38 #include "environment.h" // MAS environment
39 #include "pathfinder.h" // Path finding algorithm
40 #include "mapgen/mapmaker.h" // Map generator
41
42 // The current OpenCity version
43 #define OC_VERSION 0
44 #define OC_PATCHLEVEL 0
45 #define OC_SUBLEVEL 7
46
47
48 //========================================================================
49 /** This structure contain the global settings
50 \author Duong Khang NGUYEN
51 */
52 struct GlobalVar
53 {
54 // Config file and command line options
55 bool gboolUseAudio; ///< Is audio enabled ?
56 bool gboolAcceleratedVisual; ///< Is GL accelerated visual enabled ?
57 bool gboolFullScreen; ///< Are we in fullscreen mode ?
58 bool gboolServerMode; ///< Are we running in the server mode ?
59 uint guiCityWidth; ///< The current city's width
60 uint guiCityLength; ///< The current city's length
61 uint guiMsPerFrame; ///< The number of milliseconds to wait between each frame.
62 uint guiScreenWidth; ///< The current screen's width
63 uint guiScreenHeight; ///< The current screen's height
64 uint guiVideoBpp; ///< The current video bits-per-plane
65 string gsOpenGLDriver; ///< The name of the OpenGL driver
66
67 uint guiGeneratorSeed;
68 string gsGeneratorHeightMap;
69 MapGen::MapMaker::MAP_TYPE guiGeneratorMapType;
70 MapGen::MapMaker::WATER_TYPE guiGeneratorWaterType;
71 MapGen::MapMaker::MAP_SHAPE_TYPE guiGeneratorMapShapeType;
72 MapGen::MapMaker::TREE_DENSITY_TYPE guiGeneratorTreeDensityType;
73
74 OC_FLOAT gfMsSimDelayMax;
75 string gsZenServer;
76
77 // Application status
78 bool gboolActive; ///< Is the application active ?
79
80 // The mutex that all the simulators depend on
81 SDL_mutex* gpmutexSim;
82
83 // The famous renderer
84 Renderer* gpRenderer;
85
86 // Data managers
87 AudioManager* gpAudioMgr;
88 GraphicManager* gpGraphicMgr;
89 ExtensionManager* gpExtensionMgr;
90 PropertyManager* gpPropertyMgr;
91 MapGen::MapMaker* gpMapMaker; ///< The MapMaker is used to create the height map
92 Map* gpMapMgr;
93 Networking* gpNetworking;
94 PathFinder* gpPathFinder;
95 MovementManager* gpMoveMgr;
96
97 // Multi-Agent System
98 Kernel* gpKernel;
99 Environment* gpEnvironment;
100
101 // The SDL video surface
102 SDL_Surface* gpVideoSrf;
103 };
104
105
106 #endif
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138