caelum::ImageStarfield Class Reference

#include <ImageStarfield.h>

Inheritance diagram for caelum::ImageStarfield:

caelum::CameraBoundElement

List of all members.

Public Member Functions

 ImageStarfield (Ogre::SceneManager *sceneMgr, Ogre::SceneNode *caelumRootNode, const Ogre::String &textureName="ImageStarfield.jpg")
virtual ~ImageStarfield ()
void setInclination (Ogre::Degree inc)
void update (const float time)
void setTexture (const Ogre::String &mapName)
virtual void notifyCameraChanged (Ogre::Camera *cam)
 Handle camera change.

Protected Member Functions

virtual void setFarRadius (Ogre::Real radius)
 Handle far radius.

Protected Attributes

Ogre::SceneNode * mNode
Ogre::MaterialPtr mStarfieldMaterial
Ogre::Degree mInclination

Static Protected Attributes

static const Ogre::String STARFIELD_DOME_NAME = "CaelumStarfieldDome"
static const Ogre::String STARFIELD_MATERIAL_NAME = "CaelumStarfieldMaterial"


Detailed Description

ImageStarfield dome class.
Author:
Jesús Alonso Abad

Definition at line 32 of file ImageStarfield.h.


Constructor & Destructor Documentation

caelum::ImageStarfield::ImageStarfield ( Ogre::SceneManager *  sceneMgr,
Ogre::SceneNode *  caelumRootNode,
const Ogre::String &  textureName = "ImageStarfield.jpg" 
)

Constructor.

Parameters:
sceneMgr The scene manager this dome will belong to.

Definition at line 31 of file ImageStarfield.cpp.

References caelum::GeometryFactory::generateSphericDome(), mInclination, mNode, mStarfieldMaterial, setTexture(), STARFIELD_DOME_NAME, and STARFIELD_MATERIAL_NAME.

caelum::ImageStarfield::~ImageStarfield (  )  [virtual]

Destructor.

Definition at line 51 of file ImageStarfield.cpp.

References mNode, and mStarfieldMaterial.


Member Function Documentation

void caelum::ImageStarfield::setInclination ( Ogre::Degree  inc  ) 

Sets the starfield inclination. This inclination is the angle between the starfield rotation axis and the horizon plane.

Parameters:
inc The starfield inclination in degrees. It`s equal to observer latitude taken with opposite sign.

Definition at line 74 of file ImageStarfield.cpp.

References mInclination.

void caelum::ImageStarfield::update ( const float  time  ) 

Updates the starfield position/orientation.

Parameters:
time Local time in [0, 1] range.

Definition at line 78 of file ImageStarfield.cpp.

References mInclination, and mNode.

Referenced by caelum::CaelumSystem::updateSubcomponents().

void caelum::ImageStarfield::setTexture ( const Ogre::String &  mapName  ) 

Updates the starfield material.

Parameters:
mapName The new starfield texture map name.

Definition at line 86 of file ImageStarfield.cpp.

References mStarfieldMaterial.

Referenced by ImageStarfield().


Member Data Documentation

Ogre::SceneNode* caelum::ImageStarfield::mNode [protected]

Reference to the dome node.

Definition at line 37 of file ImageStarfield.h.

Referenced by ImageStarfield(), setFarRadius(), update(), and ~ImageStarfield().

const Ogre::String caelum::ImageStarfield::STARFIELD_DOME_NAME = "CaelumStarfieldDome" [static, protected]

Name of the spheric dome resource.

Definition at line 41 of file ImageStarfield.h.

Referenced by ImageStarfield().

const Ogre::String caelum::ImageStarfield::STARFIELD_MATERIAL_NAME = "CaelumStarfieldMaterial" [static, protected]

Name of the starfield material.

Definition at line 45 of file ImageStarfield.h.

Referenced by ImageStarfield().

Ogre::MaterialPtr caelum::ImageStarfield::mStarfieldMaterial [protected]

Reference to the starfield material.

Definition at line 49 of file ImageStarfield.h.

Referenced by ImageStarfield(), setTexture(), and ~ImageStarfield().

Ogre::Degree caelum::ImageStarfield::mInclination [protected]

Inclination of the starfield.

Definition at line 53 of file ImageStarfield.h.

Referenced by ImageStarfield(), setInclination(), and update().


The documentation for this class was generated from the following files:

Generated on Fri Jul 11 09:24:53 2008 for Caelum by  doxygen 1.5.6