#include <vplight.h>
Inheritance diagram for VPLight:
Public Member Functions | |
VPLight () | |
VPLight (const VPLight &light) | |
VPLight (float i, float ai, VPColor c, bool o) | |
VPLight (const std::string &newDescription, float newIntensity, float newAmbientIntensity, const VPColor &newColor, const VPPoint4D &newLocation) | |
virtual | ~VPLight () |
VPLight & | operator= (const VPLight &light) |
void | SetIntensity (float i) |
float | GetIntensity () const |
void | SetAmbientIntensity (float ai) |
float | GetAmbientIntensity () const |
void | SetColor (const VPColor &c) |
VPColor | GetColor () const |
void | Turn (bool on_off) |
Turns a light on or off. | |
bool | IsOn () const |
void | SetLocation (const VPPoint4D &newLocation) |
Sets the location of the light. | |
VPPoint4D | GetLocation () const |
bool | DrawOGL (unsigned int oglLightID) const |
Draws (sets up) a light using OpenGL commands. | |
Static Public Member Functions | |
static const VPLight & | SUN () |
White directional light towards negative Y. Small ambient intensity. | |
static const VPLight & | BRIGHT_AMBIENT () |
Strong, white ambient light. |
This class represents simple light sources, i.e.: directional lights or point lights with no attenuation. See the derived classes for more complex light sources.
Definition at line 22 of file vplight.h.
|
Definition at line 43 of file vplight.cpp. References VPColor::SetRGBA(). |
|
Definition at line 71 of file vplight.cpp. References ambientIntensity, color, VPSceneNode::description, intensity, location, and on. |
|
Definition at line 52 of file vplight.cpp. |
|
|
|
Definition at line 80 of file vplight.cpp. |
|
Strong, white ambient light.
Definition at line 97 of file vplight.cpp. References VPPoint4D::ORIGIN(), and VPColor::WHITE(). |
|
Draws (sets up) a light using OpenGL commands.
Definition at line 138 of file vplight.cpp. References VPColor::GetScaled(). |
|
Definition at line 114 of file vplight.cpp. |
|
Definition at line 122 of file vplight.cpp. |
|
Definition at line 106 of file vplight.cpp. |
|
|
|
Definition at line 130 of file vplight.cpp. |
|
Definition at line 83 of file vplight.cpp. References ambientIntensity, color, VPSceneNode::description, intensity, location, and on. |
|
Definition at line 110 of file vplight.cpp. |
|
Definition at line 118 of file vplight.cpp. |
|
Definition at line 102 of file vplight.cpp. |
|
Sets the location of the light. newLocation should be a point for positional lights or a direction for directional lights. Definition at line 134 of file vplight.cpp. |
|
White directional light towards negative Y. Small ambient intensity.
Definition at line 93 of file vplight.cpp. References VPColor::WHITE(). |
|
Turns a light on or off.
Definition at line 126 of file vplight.cpp. |