00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #ifndef CAELUM__IMAGE_STARFIELD_H
00022 #define CAELUM__IMAGE_STARFIELD_H
00023
00024 #include "CaelumPrerequisites.h"
00025 #include "CameraBoundElement.h"
00026 #include "PrivatePtr.h"
00027
00028 namespace Caelum
00029 {
00034 class CAELUM_EXPORT ImageStarfield : public CameraBoundElement
00035 {
00036 protected:
00038 PrivateSceneNodePtr mNode;
00039
00041 PrivateMaterialPtr mStarfieldMaterial;
00042
00044 PrivateEntityPtr mEntity;
00045
00047 static const Ogre::String STARFIELD_DOME_NAME;
00048
00050 static const Ogre::String STARFIELD_MATERIAL_NAME;
00051
00054 Ogre::Degree mInclination;
00055
00056 public:
00057 static const String DEFAULT_TEXTURE_NAME;
00058
00062 ImageStarfield (
00063 Ogre::SceneManager *sceneMgr,
00064 Ogre::SceneNode *caelumRootNode,
00065 const Ogre::String &textureName = DEFAULT_TEXTURE_NAME);
00066
00069 virtual ~ImageStarfield ();
00070
00074 void setInclination (Ogre::Degree inc);
00075
00079 void update (const float time);
00080
00084 void setTexture (const Ogre::String &mapName);
00085
00086 public:
00088 virtual void notifyCameraChanged (Ogre::Camera *cam);
00089
00090 protected:
00092 virtual void setFarRadius (Ogre::Real radius);
00093
00094 public:
00095 void setQueryFlags (uint flags) { mEntity->setQueryFlags (flags); }
00096 uint getQueryFlags () const { return mEntity->getQueryFlags (); }
00097 void setVisibilityFlags (uint flags) { mEntity->setVisibilityFlags (flags); }
00098 uint getVisibilityFlags () const { return mEntity->getVisibilityFlags (); }
00099 };
00100 }
00101
00102 #endif // CAELUM__IMAGE_STARFIELD_H