not finished yet, but better than before
[MicroTrace.git] / SpotLight.hxx
1 #ifndef SPOTLIGHT_HXX
2 #define SPOTLIGHT_HXX
3
4 #include "Light.hxx"
5
6 class SpotLight : public Light
7 {
8 public:
9 SpotLight(Scene* scene, const Vec3f& pos, const Vec3f& dir, const Vec3f& intensity, float alpha_min, float alpha_max);
10 virtual ~SpotLight();
11
12 virtual bool Illuminate(Ray& ray, Vec3f& intensity);
13
14 const Vec3f& position() const;
15 const Vec3f& direction() const;
16
17 private:
18 SpotLight();
19
20 // position and direction
21 Vec3f m_pos, m_dir;
22 // emission (red, green, blue)
23 Vec3f m_intensity;
24 // opening angles
25 float m_alpha_min, m_alpha_max;
26 };
27 #endif
This page took 0.058484 seconds and 5 git commands to generate.