1 | /* |
---|
2 | * ORXONOX - the hottest 3D action shooter ever to exist |
---|
3 | * > www.orxonox.net < |
---|
4 | * |
---|
5 | * |
---|
6 | * License notice: |
---|
7 | * |
---|
8 | * This program is free software; you can redistribute it and/or |
---|
9 | * modify it under the terms of the GNU General Public License |
---|
10 | * as published by the Free Software Foundation; either version 2 |
---|
11 | * of the License, or (at your option) any later version. |
---|
12 | * |
---|
13 | * This program is distributed in the hope that it will be useful, |
---|
14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
---|
16 | * GNU General Public License for more details. |
---|
17 | * |
---|
18 | * You should have received a copy of the GNU General Public License |
---|
19 | * along with this program; if not, write to the Free Software |
---|
20 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. |
---|
21 | * |
---|
22 | * Author: |
---|
23 | * Reto Grieder |
---|
24 | * Co-authors: |
---|
25 | * ... |
---|
26 | * |
---|
27 | */ |
---|
28 | |
---|
29 | /** |
---|
30 | @file |
---|
31 | @brief |
---|
32 | Shared library macros, enums, constants and forward declarations for the core library |
---|
33 | */ |
---|
34 | |
---|
35 | #ifndef _CorePrereqs_H__ |
---|
36 | #define _CorePrereqs_H__ |
---|
37 | |
---|
38 | #include "OrxonoxConfig.h" |
---|
39 | #include <boost/version.hpp> |
---|
40 | |
---|
41 | //----------------------------------------------------------------------- |
---|
42 | // Shared library settings |
---|
43 | //----------------------------------------------------------------------- |
---|
44 | |
---|
45 | #if defined(ORXONOX_PLATFORM_WINDOWS) && !defined( CORE_STATIC_BUILD ) |
---|
46 | # ifdef CORE_SHARED_BUILD |
---|
47 | # define _CoreExport __declspec(dllexport) |
---|
48 | # else |
---|
49 | # if defined( __MINGW32__ ) |
---|
50 | # define _CoreExport |
---|
51 | # else |
---|
52 | # define _CoreExport __declspec(dllimport) |
---|
53 | # endif |
---|
54 | # endif |
---|
55 | #elif defined ( ORXONOX_GCC_VISIBILITY ) |
---|
56 | # define _CoreExport __attribute__ ((visibility("default"))) |
---|
57 | #else |
---|
58 | # define _CoreExport |
---|
59 | #endif |
---|
60 | |
---|
61 | //----------------------------------------------------------------------- |
---|
62 | // Constants |
---|
63 | //----------------------------------------------------------------------- |
---|
64 | |
---|
65 | namespace orxonox |
---|
66 | { |
---|
67 | static const uint32_t OBJECTID_UNKNOWN = static_cast<uint32_t>(-1); |
---|
68 | } |
---|
69 | |
---|
70 | //----------------------------------------------------------------------- |
---|
71 | // Enums |
---|
72 | //----------------------------------------------------------------------- |
---|
73 | |
---|
74 | namespace orxonox |
---|
75 | { |
---|
76 | namespace XMLPort |
---|
77 | { |
---|
78 | enum Mode |
---|
79 | { |
---|
80 | NOP, |
---|
81 | LoadObject, |
---|
82 | SaveObject, |
---|
83 | ExpandObject |
---|
84 | }; |
---|
85 | } |
---|
86 | |
---|
87 | namespace ConfigFileType |
---|
88 | { |
---|
89 | enum Value |
---|
90 | { |
---|
91 | Settings, |
---|
92 | JoyStickCalibration, |
---|
93 | CommandHistory |
---|
94 | // Don't forget to adjust the array size in the ConfigFileManager when adding a new entry here! |
---|
95 | }; |
---|
96 | } |
---|
97 | |
---|
98 | namespace KeybindMode |
---|
99 | { |
---|
100 | enum Value |
---|
101 | { |
---|
102 | OnPress, |
---|
103 | OnHold, |
---|
104 | OnRelease, |
---|
105 | None |
---|
106 | }; |
---|
107 | }; |
---|
108 | } |
---|
109 | |
---|
110 | //----------------------------------------------------------------------- |
---|
111 | // Forward declarations |
---|
112 | //----------------------------------------------------------------------- |
---|
113 | |
---|
114 | namespace orxonox |
---|
115 | { |
---|
116 | typedef std::string LanguageEntryLabel; |
---|
117 | |
---|
118 | template <class T, class U> |
---|
119 | T orxonox_cast(U*); |
---|
120 | |
---|
121 | class ArgumentCompleter; |
---|
122 | class ArgumentCompletionListElement; |
---|
123 | class BaseObject; |
---|
124 | template <class T> |
---|
125 | class ClassFactory; |
---|
126 | template <class T> |
---|
127 | class ClassIdentifier; |
---|
128 | class ClassTreeMask; |
---|
129 | class ClassTreeMaskIterator; |
---|
130 | class ClassTreeMaskNode; |
---|
131 | class ClassTreeMaskObjectIterator; |
---|
132 | class CommandEvaluation; |
---|
133 | class CommandLineParser; |
---|
134 | class CommandLineArgument; |
---|
135 | class ConfigFile; |
---|
136 | class ConfigFileEntry; |
---|
137 | class ConfigFileEntryComment; |
---|
138 | class ConfigFileEntryValue; |
---|
139 | class ConfigFileManager; |
---|
140 | class ConfigFileSection; |
---|
141 | class ConfigValueContainer; |
---|
142 | class ConsoleCommand; |
---|
143 | class Core; |
---|
144 | class DynLib; |
---|
145 | class DynLibManager; |
---|
146 | struct Event; |
---|
147 | class EventState; |
---|
148 | class Executor; |
---|
149 | template <class T> |
---|
150 | class ExecutorMember; |
---|
151 | class ExecutorStatic; |
---|
152 | class Factory; |
---|
153 | class Functor; |
---|
154 | template <class T> |
---|
155 | class FunctorMember; |
---|
156 | class FunctorStatic; |
---|
157 | class Game; |
---|
158 | class GameState; |
---|
159 | struct GameStateInfo; |
---|
160 | struct GameStateTreeNode; |
---|
161 | class GraphicsManager; |
---|
162 | class GUIManager; |
---|
163 | class Identifier; |
---|
164 | class IOConsole; |
---|
165 | class IRC; |
---|
166 | template <class T> |
---|
167 | class Iterator; |
---|
168 | class Language; |
---|
169 | class LuaState; |
---|
170 | class MemoryArchive; |
---|
171 | class MemoryArchiveFactory; |
---|
172 | class MetaObjectList; |
---|
173 | class MetaObjectListElement; |
---|
174 | class Namespace; |
---|
175 | class NamespaceNode; |
---|
176 | template <class T> |
---|
177 | class ObjectList; |
---|
178 | class ObjectListBase; |
---|
179 | class ObjectListBaseElement; |
---|
180 | template <class T> |
---|
181 | class ObjectListElement; |
---|
182 | template <class T> |
---|
183 | class ObjectListIterator; |
---|
184 | class OgreWindowEventListener; |
---|
185 | class OrxonoxClass; |
---|
186 | class PathConfig; |
---|
187 | struct ResourceInfo; |
---|
188 | class SettingsConfigFile; |
---|
189 | class Shell; |
---|
190 | class ShellListener; |
---|
191 | template <class T> |
---|
192 | class SmartPtr; |
---|
193 | template <class T> |
---|
194 | class SubclassIdentifier; |
---|
195 | class TclBind; |
---|
196 | struct TclInterpreterBundle; |
---|
197 | template <class T> |
---|
198 | class TclThreadList; |
---|
199 | class TclThreadManager; |
---|
200 | class Template; |
---|
201 | class Thread; |
---|
202 | class ThreadPool; |
---|
203 | template <class T> |
---|
204 | class WeakPtr; |
---|
205 | class WindowEventListener; |
---|
206 | class XMLFile; |
---|
207 | class XMLNameListener; |
---|
208 | template <class T, class O> |
---|
209 | class XMLPortClassObjectContainer; |
---|
210 | template <class T> |
---|
211 | class XMLPortClassParamContainer; |
---|
212 | class XMLPortObjectContainer; |
---|
213 | class XMLPortParamContainer; |
---|
214 | |
---|
215 | // Input |
---|
216 | class BaseCommand; |
---|
217 | class BufferedParamCommand; |
---|
218 | class Button; |
---|
219 | class HalfAxis; |
---|
220 | class InputBuffer; |
---|
221 | class InputDevice; |
---|
222 | template <class Traits> |
---|
223 | class InputDeviceTemplated; |
---|
224 | class InputHandler; |
---|
225 | class InputManager; |
---|
226 | class InputState; |
---|
227 | struct InputStatePriority; |
---|
228 | class JoyStickQuantityListener; |
---|
229 | class JoyStick; |
---|
230 | class KeyBinder; |
---|
231 | class KeyBinderManager; |
---|
232 | class Keyboard; |
---|
233 | class KeyDetector; |
---|
234 | class KeyEvent; |
---|
235 | class Mouse; |
---|
236 | class ParamCommand; |
---|
237 | class SimpleCommand; |
---|
238 | } |
---|
239 | |
---|
240 | // CppTcl |
---|
241 | namespace Tcl |
---|
242 | { |
---|
243 | class interpreter; |
---|
244 | class object; |
---|
245 | } |
---|
246 | |
---|
247 | // Boost |
---|
248 | namespace boost |
---|
249 | { |
---|
250 | #if (BOOST_VERSION < 104400) |
---|
251 | namespace filesystem |
---|
252 | { |
---|
253 | struct path_traits; |
---|
254 | template <class String, class Traits> class basic_path; |
---|
255 | typedef basic_path<std::string, path_traits> path; |
---|
256 | } |
---|
257 | #else |
---|
258 | namespace filesystem2 |
---|
259 | { |
---|
260 | struct path_traits; |
---|
261 | template <class String, class Traits> class basic_path; |
---|
262 | typedef basic_path<std::string, path_traits> path; |
---|
263 | } |
---|
264 | namespace filesystem |
---|
265 | { |
---|
266 | using filesystem2::basic_path; |
---|
267 | using filesystem2::path_traits; |
---|
268 | using filesystem2::path; |
---|
269 | } |
---|
270 | #endif |
---|
271 | class thread; |
---|
272 | class mutex; |
---|
273 | class shared_mutex; |
---|
274 | class condition_variable; |
---|
275 | } |
---|
276 | |
---|
277 | // Ogre |
---|
278 | namespace Ogre |
---|
279 | { |
---|
280 | class DataStream; |
---|
281 | template <class T> class SharedPtr; |
---|
282 | typedef SharedPtr<DataStream> DataStreamPtr; |
---|
283 | } |
---|
284 | namespace orxonox |
---|
285 | { |
---|
286 | // Import the Ogre::DataStream |
---|
287 | using Ogre::DataStream; |
---|
288 | using Ogre::DataStreamPtr; |
---|
289 | } |
---|
290 | |
---|
291 | // CEGUI |
---|
292 | namespace CEGUI |
---|
293 | { |
---|
294 | class DefaultLogger; |
---|
295 | class Logger; |
---|
296 | class LuaScriptModule; |
---|
297 | |
---|
298 | class OgreCEGUIRenderer; |
---|
299 | class OgreCEGUIResourceProvider; |
---|
300 | class OgreCEGUITexture; |
---|
301 | } |
---|
302 | |
---|
303 | // Lua |
---|
304 | struct lua_State; |
---|
305 | |
---|
306 | // TinyXML and TinyXML++ |
---|
307 | class TiXmlString; |
---|
308 | class TiXmlOutStream; |
---|
309 | class TiXmlNode; |
---|
310 | class TiXmlHandle; |
---|
311 | class TiXmlDocument; |
---|
312 | class TiXmlElement; |
---|
313 | class TiXmlComment; |
---|
314 | class TiXmlUnknown; |
---|
315 | class TiXmlAttribute; |
---|
316 | class TiXmlText; |
---|
317 | class TiXmlDeclaration; |
---|
318 | class TiXmlParsingData; |
---|
319 | namespace ticpp |
---|
320 | { |
---|
321 | class Document; |
---|
322 | class Element; |
---|
323 | class Declaration; |
---|
324 | class StylesheetReference; |
---|
325 | class Text; |
---|
326 | class Comment; |
---|
327 | class Attribute; |
---|
328 | } |
---|
329 | namespace orxonox |
---|
330 | { |
---|
331 | using ticpp::Element; |
---|
332 | } |
---|
333 | |
---|
334 | #endif /* _CorePrereqs_H__ */ |
---|