|
PGR Copakond OpenGL Engine - Bowling
|
Base class for scene lighting calculations. More...
#include <light.h>
Public Types | |
| enum | LightType { DIRECTIONAL , POINT , SPOTLIGHT } |
Public Member Functions | |
| Light (LightType type, glm::vec3 position, glm::vec3 direction, glm::vec3 ambient, glm::vec3 diffuse, glm::vec3 specular, float range, float angle, float exponent, bool dim) | |
| Initializes base light properties. | |
| int | type () |
| glm::vec3 & | position () |
| glm::vec3 & | direction () |
| glm::vec3 & | ambient () |
| glm::vec3 & | diffuse () |
| glm::vec3 & | specular () |
| int & | id () |
| float & | range () |
| float & | angle () |
| float & | exponent () |
| bool & | dim () |
| LightUniforms & | getUniformLocations () |
Protected Attributes | |
| LightType | _type |
| glm::vec3 | _position |
| glm::vec3 | _direction |
| glm::vec3 | _ambient |
| glm::vec3 | _diffuse |
| glm::vec3 | _specular |
| int | _id |
| float | _range |
| float | _angle |
| float | _exponent |
| bool | _dim |
| LightUniforms | _uniformLocations |
Base class for scene lighting calculations.
| copakond::Light::Light | ( | LightType | type, |
| glm::vec3 | position, | ||
| glm::vec3 | direction, | ||
| glm::vec3 | ambient, | ||
| glm::vec3 | diffuse, | ||
| glm::vec3 | specular, | ||
| float | range, | ||
| float | angle, | ||
| float | exponent, | ||
| bool | dim ) |
Initializes base light properties.
| dim | If true, applies distance-based attenuation (dimming). |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
protected |
|
protected |
Cutoff angle for spotlights
|
protected |
|
protected |
If true, light intensity attenuates based on distance
|
protected |
|
protected |
Falloff exponent for spotlights
|
protected |
|
protected |
|
protected |
Maximum distance the light reaches
|
protected |
|
protected |
|
protected |