00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #ifndef CAELUM__CAELUM_PREREQUISITES_H
00022 #define CAELUM__CAELUM_PREREQUISITES_H
00023
00024
00025 #ifdef __APPLE__
00026 #include "Ogre/Ogre.h"
00027 #else
00028 #include "Ogre.h"
00029 #endif
00030
00031 #include <memory>
00032
00033
00034 #if OGRE_PLATFORM == OGRE_PLATFORM_WIN32
00035 #ifdef CAELUM_LIB
00036 #define CAELUM_EXPORT __declspec (dllexport)
00037 #else
00038 #ifdef __MINGW32__
00039 #define CAELUM_EXPORT
00040 #else
00041 #define CAELUM_EXPORT __declspec (dllimport)
00042 #endif
00043 #endif
00044 #elif OGRE_PLATFORM == OGRE_PLATFORM_APPLE
00045 #define CAELUM_EXPORT __attribute__ ((visibility("default")))
00046 #else
00047 #define CAELUM_EXPORT
00048 #endif
00049
00050
00051 #define CAELUM_VERSION_MAIN 0
00052 #define CAELUM_VERSION_SEC 5
00053 #define CAELUM_VERSION_TER 0
00054 #define CAELUM_VERSION = (CAELUM_VERSION_MAIN << 16) | (CAELUM_VERSION_SEC << 8) | CAELUM_VERSION_TER
00055
00056
00057 #ifndef CAELUM_TYPE_DESCRIPTORS
00058 #if (OGRE_VERSION >= 0x00010600) && OGRE_USE_NEW_COMPILERS
00059 #define CAELUM_TYPE_DESCRIPTORS 1
00060 #else
00061 #define CAELUM_TYPE_DESCRIPTORS 0
00062 #endif
00063 #endif
00064
00065
00066
00067 #ifndef CAELUM_SCRIPT_SUPPORT
00068 #if (OGRE_VERSION >= 0x00010600) && OGRE_USE_NEW_COMPILERS
00069 #define CAELUM_SCRIPT_SUPPORT 1
00070 #else
00071 #define CAELUM_SCRIPT_SUPPORT 0
00072 #endif
00073 #else
00074 #if !(OGRE_VERSION > 0x00010600)
00075 #error "Caelum script support requires Ogre 1.6."
00076 #endif
00077 #if !(OGRE_USE_NEW_COMPILERS)
00078 #error "Caelum script support requires Ogre 1.6 with OGRE_USE_NEW_COMPILERS."
00079 #endif
00080 #if !(CAELUM_TYPE_DESCRIPTORS)
00081 #error "Caelum script support also requires type descriptors."
00082 #endif
00083 #endif
00084
00086
00107 namespace Caelum
00108 {
00109
00110
00111 typedef double LongReal;
00112
00113
00114 using Ogre::uint8;
00115 using Ogre::uint16;
00116 using Ogre::ushort;
00117 using Ogre::uint32;
00118 using Ogre::uint;
00119
00120 using Ogre::Real;
00121 using Ogre::String;
00122
00124 static const String RESOURCE_GROUP_NAME = "Caelum";
00125
00126
00127
00128 enum CaelumRenderQueueGroupId
00129 {
00130 CAELUM_RENDER_QUEUE_STARFIELD = Ogre::RENDER_QUEUE_SKIES_EARLY + 0,
00131 CAELUM_RENDER_QUEUE_MOON_BACKGROUND = Ogre::RENDER_QUEUE_SKIES_EARLY + 1,
00132 CAELUM_RENDER_QUEUE_SKYDOME = Ogre::RENDER_QUEUE_SKIES_EARLY + 2,
00133 CAELUM_RENDER_QUEUE_MOON = Ogre::RENDER_QUEUE_SKIES_EARLY + 3,
00134 CAELUM_RENDER_QUEUE_SUN = Ogre::RENDER_QUEUE_SKIES_EARLY + 4,
00135 CAELUM_RENDER_QUEUE_CLOUDS = Ogre::RENDER_QUEUE_SKIES_EARLY + 5,
00136 CAELUM_RENDER_QUEUE_GROUND_FOG = Ogre::RENDER_QUEUE_SKIES_EARLY + 6,
00137 };
00138
00139
00140 class UniversalClock;
00141 class SkyDome;
00142 class BaseSkyLight;
00143 class Moon;
00144 class SphereSun;
00145 class SpriteSun;
00146 class ImageStarfield;
00147 class PointStarfield;
00148 class CloudSystem;
00149 class CaelumSystem;
00150 class FlatCloudLayer;
00151 class PrecipitationController;
00152 class PrecipitationInstance;
00153 class GroundFog;
00154 class DepthComposer;
00155 class DepthComposerInstance;
00156 class DepthRenderer;
00157 }
00158
00159 namespace Ogre
00160 {
00161 #if OGRE_VERSION <= 0x010602
00162
00163
00164
00165
00166
00167
00168
00169
00170
00171 inline std::ostream& operator << (std::ostream& out, Ogre::Degree deg) {
00172 return out << deg.valueDegrees();
00173 }
00174 #endif
00175 }
00176
00177 #endif // CAELUM__CAELUM_PREREQUISITES_H