17 #ifndef IGNITION_RENDERING_BASE_BASELIGHT_HH_ 18 #define IGNITION_RENDERING_BASE_BASELIGHT_HH_ 26 inline namespace IGNITION_RENDERING_VERSION_NAMESPACE {
37 public:
virtual void SetDiffuseColor(
double _r,
double _g,
double _b,
40 public:
virtual void SetDiffuseColor(
const math::Color &_color) = 0;
42 public:
virtual void SetSpecularColor(
double _r,
double _g,
double _b,
45 public:
virtual void SetSpecularColor(
const math::Color &_color) = 0;
47 public:
virtual void SetAttenuationConstant(
double _value) = 0;
49 public:
virtual void SetAttenuationLinear(
double _value) = 0;
51 public:
virtual void SetAttenuationQuadratic(
double _value) = 0;
53 public:
virtual void SetAttenuationRange(
double _range) = 0;
55 public:
virtual void SetCastShadows(
bool _castShadows) = 0;
57 protected:
virtual void Reset();
69 public:
virtual void SetDirection(
double _x,
double _y,
double _z);
73 protected:
virtual void Reset();
95 public:
virtual void SetDirection(
double _x,
double _y,
double _z);
99 public:
virtual void SetInnerAngle(
double _radians);
101 public:
virtual void SetInnerAngle(
const math::Angle &_angle) = 0;
103 public:
virtual void SetOuterAngle(
double _radians);
105 public:
virtual void SetOuterAngle(
const math::Angle &_angle) = 0;
107 public:
virtual void SetFalloff(
double _falloff) = 0;
109 protected:
virtual void Reset();
129 this->SetDiffuseColor(
math::Color(_r, _g, _b, _a));
137 this->SetSpecularColor(
math::Color(_r, _g, _b, _a));
146 this->SetAttenuationConstant(1);
147 this->SetAttenuationLinear(0);
148 this->SetAttenuationQuadratic(0);
149 this->SetAttenuationRange(100);
150 this->SetCastShadows(
true);
177 this->SetDirection(0, 0, -1);
230 this->SetDirection(0, 0, -1);
231 this->SetInnerAngle(
IGN_PI / 4.5);
232 this->SetOuterAngle(
IGN_PI / 4.0);
233 this->SetFalloff(1.0);
Definition: BaseLight.hh:29
virtual ~BasePointLight()
Definition: BaseLight.hh:188
virtual void Reset()
Definition: BaseLight.hh:227
virtual void SetOuterAngle(double _radians)
Set the outer angle of the spotlight.
Definition: BaseLight.hh:220
Definition: BaseLight.hh:77
BaseSpotLight()
Definition: BaseLight.hh:194
virtual ~BaseLight()
Definition: BaseLight.hh:120
Represents a point light.
Definition: Light.hh:136
virtual void SetDirection(double _x, double _y, double _z)
Set the direction of the light.
Definition: BaseLight.hh:167
BaseLight()
Definition: BaseLight.hh:114
virtual ~BaseDirectionalLight()
Definition: BaseLight.hh:161
Definition: BaseLight.hh:87
virtual void SetDirection(double _x, double _y, double _z)
Set the direction of the light.
Definition: BaseLight.hh:206
virtual ~BaseSpotLight()
Definition: BaseLight.hh:200
Represents a light source in the scene graph.
Definition: Light.hh:32
Represents a spotlight.
Definition: Light.hh:145
Represents a infinite directional light.
Definition: Light.hh:113
BasePointLight()
Definition: BaseLight.hh:182
Definition: BaseLight.hh:61
virtual void SetSpecularColor(double _r, double _g, double _b, double _a=1.0)
Set the specular color.
Definition: BaseLight.hh:134
virtual void SetInnerAngle(double _radians)
Set the inner angle of the spotlight.
Definition: BaseLight.hh:213
BaseDirectionalLight()
Definition: BaseLight.hh:155
virtual void Reset()
Definition: BaseLight.hh:174
virtual void SetDiffuseColor(double _r, double _g, double _b, double _a=1.0)
Set the diffuse color.
Definition: BaseLight.hh:126
virtual void Reset()
Definition: BaseLight.hh:142