Main Page | Modules | Namespace List | Class Hierarchy | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

X3D_SpotLight.h

Go to the documentation of this file.
00001 #ifndef X3DTK_X3D_SPOTLIGHT
00002 #define X3DTK_X3D_SPOTLIGHT
00003 
00004 #include "X3DTypes.h"
00005 #include "X3D_X3DLightNode.h"
00006 
00007 namespace X3DTK {
00008 namespace X3D {
00009 
00018 class SpotLight : public X3DLightNode
00019 {
00020 public:
00022   SpotLight();
00024   SpotLight(const SFFloat       &ambientIntensity,
00025             const SFVec3f &attenuation,
00026             const SFFloat       &beamWidth,
00027             const SFColor &color,
00028             const SFFloat       &cutOffAngle,
00029             const SFVec3f &direction,
00030             const SFFloat       &intensity,
00031             const SFVec3f &location,
00032             const SFBool        &on,
00033             const SFFloat       &radius);
00035   virtual SFAbstractNode clone() const;
00037   virtual ~SpotLight();
00038 
00040   void setAttenuation(const SFVec3f &attenuation);
00042   void setBeamWidth(const SFFloat &beamWidth);
00044   void setCutOffAngle(const SFFloat &cutOffAngle);
00046   void setDirection(const SFVec3f &direction);
00048   void setLocation(const SFVec3f &location);
00050   void setRadius(const SFFloat &radius);
00051 
00053   inline const SFVec3f &getAttenuation() const {return _attenuation;};
00055   inline const SFFloat &getBeamWidth() const {return _beamWidth;};
00057   inline const SFFloat &getCutOffAngle() const {return _cutOffAngle;};
00059   inline const SFVec3f &getDirection() const {return _direction;};
00061   inline const SFVec3f &getLocation() const {return _location;};
00063   inline const SFFloat &getRadius() const {return _radius;};
00064 
00066   virtual void load(const X3DFileElement *element);
00068   virtual SFString &write(SFString &output) const;
00069 
00070 protected:
00072   SpotLight(const SpotLight &N);
00073 
00074 private:
00076   SFVec3f _attenuation;
00078   SFFloat _beamWidth;
00080   SFFloat _cutOffAngle;
00082   SFVec3f _direction;
00084   SFVec3f _location;
00086   SFFloat _radius;
00087 };
00088 
00089 }
00090 }
00091 
00092 #endif

Generated on Thu Jun 3 10:12:10 2004 for X3DToolKit by doxygen 1.3.6