OpenMW
components/ogreinit/ogreinit.hpp
Go to the documentation of this file.
00001 #ifndef OPENMW_COMPONENTS_OGREINIT_H
00002 #define OPENMW_COMPONENTS_OGREINIT_H
00003 
00004 #include <vector>
00005 #include <string>
00006 
00007 // Static plugin headers
00008 #ifdef ENABLE_PLUGIN_CgProgramManager
00009 # include "OgreCgPlugin.h"
00010 #endif
00011 #ifdef ENABLE_PLUGIN_OctreeSceneManager
00012 # include "OgreOctreePlugin.h"
00013 #endif
00014 #ifdef ENABLE_PLUGIN_ParticleFX
00015 # include "OgreParticleFXPlugin.h"
00016 #endif
00017 #ifdef ENABLE_PLUGIN_GL
00018 # include "OgreGLPlugin.h"
00019 #endif
00020 #ifdef ENABLE_PLUGIN_Direct3D9
00021 # include "OgreD3D9Plugin.h"
00022 #endif
00023 
00024 namespace Ogre
00025 {
00026     class ParticleEmitterFactory;
00027     class ParticleAffectorFactory;
00028     class Root;
00029 }
00030 
00031 namespace OgreInit
00032 {
00036     class OgreInit
00037     {
00038     public:
00039         OgreInit();
00040 
00041         Ogre::Root* init(const std::string &logPath // Path to directory where to store log files
00042             );
00043 
00044         ~OgreInit();
00045 
00046     private:
00047         std::vector<Ogre::ParticleEmitterFactory*> mEmitterFactories;
00048         std::vector<Ogre::ParticleAffectorFactory*> mAffectorFactories;
00049         Ogre::Root* mRoot;
00050 
00051         void loadStaticPlugins();
00052         void loadPlugins();
00053         void loadParticleFactories();
00054 
00055 
00056         #ifdef ENABLE_PLUGIN_CgProgramManager
00057         Ogre::CgPlugin* mCgPlugin;
00058         #endif
00059         #ifdef ENABLE_PLUGIN_OctreeSceneManager
00060         Ogre::OctreePlugin* mOctreePlugin;
00061         #endif
00062         #ifdef ENABLE_PLUGIN_ParticleFX
00063         Ogre::ParticleFXPlugin* mParticleFXPlugin;
00064         #endif
00065         #ifdef ENABLE_PLUGIN_GL
00066         Ogre::GLPlugin* mGLPlugin;
00067         #endif
00068         #ifdef ENABLE_PLUGIN_Direct3D9
00069         Ogre::D3D9Plugin* mD3D9Plugin;
00070         #endif
00071 
00072     };
00073 }
00074 
00075 #endif