Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jun 16, 2009, 2:25:05 PM (15 years ago)
Author:
rgrieder
Message:

Last part of the cleanup: world entities.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/pch/src/orxonox/objects/worldentities/Light.h

    r3183 r3186  
    3131
    3232#include "OrxonoxPrereqs.h"
    33 #include "StaticEntity.h"
    3433
    3534#include <string>
    36 #include <OgreLight.h>
    37 
    3835#include "util/Math.h"
    3936#include "interfaces/TeamColourable.h"
     37#include "StaticEntity.h"
    4038
    4139namespace orxonox
     
    4341    class _OrxonoxExport Light : public StaticEntity, public TeamColourable
    4442    {
     43        public:
     44            enum LightTypes // Copy from the Ogre enum
     45            {
     46                /// Point light sources give off light equally in all directions, so require only position not direction
     47                LT_POINT,
     48                /// Directional lights simulate parallel light beams from a distant source, hence have direction but no position
     49                LT_DIRECTIONAL,
     50                /// Spotlights simulate a cone of light from a source so require position and direction, plus extra values for falloff
     51                LT_SPOTLIGHT
     52            };
     53
    4554        public:
    4655            Light(BaseObject* creator);
     
    5564                { return this->light_; }
    5665
    57             inline void setType(Ogre::Light::LightTypes type)
     66            inline void setType(Light::LightTypes type)
    5867                { this->type_ = type; this->updateType(); }
    59             inline Ogre::Light::LightTypes getType() const
     68            inline Light::LightTypes getType() const
    6069                { return this->type_; }
    6170
     
    133142
    134143            Ogre::Light* light_;
    135             Ogre::Light::LightTypes type_;
     144            LightTypes type_;
    136145            ColourValue diffuse_;
    137146            ColourValue specular_;
Note: See TracChangeset for help on using the changeset viewer.