Phongo Clap RT  1.0
Simple Raytracing Renderer
Public Member Functions | Private Attributes | List of all members
SpotLight Class Reference

Spotlight constructor. More...

#include <Light.h>

Inheritance diagram for SpotLight:
Inheritance graph
Collaboration diagram for SpotLight:
Collaboration graph

Public Member Functions

 SpotLight (ngl::Vec3 _pos, ngl::Colour _diff_col, ngl::Colour _spec_col, float _diff_int, float _spec_int, float _falloff, float _angle, ngl::Vec3 _dir)
 
 ~SpotLight ()
 
- Public Member Functions inherited from Light
 Light (ngl::Vec3 _pos, ngl::Colour _diff_col, ngl::Colour _spec_col, float _diff_int, float _spec_int, float _falloff)
 Light constructor. More...
 
 ~Light ()
 Destructor for the Light objects. More...
 

Private Attributes

float m_angle
 The cone angle in which light is emitted. More...
 
ngl::Vec3 m_dir
 Direction or aiming vector of the spotlight. More...
 

Additional Inherited Members

- Protected Attributes inherited from Light
ngl::Vec3 m_pos
 Light's position vector. More...
 
ngl::Colour m_diff_col
 Diffuse colour emmited by the light. More...
 
ngl::Colour m_spec_col
 Specular colour emmited by the light. More...
 
float m_diff_int
 Diffuse contribution intensity. It will multiply the diffuse colour when doing the Phong calculations More...
 
float m_spec_int
 Specular contribution intensity. Will multiply the specular colour when doing the Phong calculations More...
 
float m_falloff
 Controlls the falloff of the light. Higher values will accentuate the decay. More...
 

Detailed Description

Spotlight constructor.

Parameters
[in]_posLight's position.
[in]_diff_colDiffuse colour emitted by the light.
[in]_spec_colSpecular colour emmited by the light.
[in]_diff_intSets the intensity of the diffuse colour emission.
[in]_spec_intSets the intensity of the specular emission.
[in]_falloffControlls how the light decays.
[in]_angleThe cone angle in which light is emitted.
[in]_dirDirection or aiming vector of the spotlight.

Definition at line 106 of file Light.h.

Constructor & Destructor Documentation

SpotLight::SpotLight ( ngl::Vec3  _pos,
ngl::Colour  _diff_col,
ngl::Colour  _spec_col,
float  _diff_int,
float  _spec_int,
float  _falloff,
float  _angle,
ngl::Vec3  _dir 
)
inline

Definition at line 109 of file Light.h.

116  : Light(_pos, _diff_col,
117  _spec_col,
118  _diff_int,
119  _spec_int,
120  _falloff),
121  m_angle(_angle), m_dir(_dir) {}
Light(ngl::Vec3 _pos, ngl::Colour _diff_col, ngl::Colour _spec_col, float _diff_int, float _spec_int, float _falloff)
Light constructor.
Definition: Light.h:30
ngl::Vec3 m_dir
Direction or aiming vector of the spotlight.
Definition: Light.h:131
float m_angle
The cone angle in which light is emitted.
Definition: Light.h:127
SpotLight::~SpotLight ( )
inline

Definition at line 122 of file Light.h.

122 {}

Member Data Documentation

float SpotLight::m_angle
private

The cone angle in which light is emitted.

Definition at line 127 of file Light.h.

ngl::Vec3 SpotLight::m_dir
private

Direction or aiming vector of the spotlight.

Definition at line 131 of file Light.h.


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