class Light OpenGL light
| | setLight (const GLfloat *ambient, const GLfloat *diffuse, const GLfloat *specular, const GLfloat *position, const GLfloat *direction = 0, GLfloat exponent = 0.0, GLfloat cutoff = 180.0, const GLfloat *attenuation = 0) set new light attributes |
| | getIndex (void) const returns OpenGL light index |
| | isActive (void) const returns light active flag |
| | getAmbient (void) const returns light ambient coefficients |
| | getDiffuse (void) const returns light diffuse coefficients |
| | getSpecular (void) const returns light specular coefficients |
| | getPosition (void) const returns light position |
| | getDirection (void) const returns spotlight direction |
| | getExponent (void) const returns spotlight expoenent |
| | getCutoff (void) const returns spotlight cutoff (in degrees) |
| | getAttenuation (void) const returns light attenuation factors (constant, linear and quadratic) |
| | setAmbient (const GLfloat *ambient) set light ambient coefficients |
| | setDiffuse (const GLfloat *diffuse) set light diffuse coefficients |
| | setSpecular (const GLfloat *specular) set light specular coefficients |
| | setPosition (const GLfloat *position) set light position coefficients |
| | setDirection (const GLfloat *direction) set spotlight direction coefficients |
| | setExponent (const GLfloat exponent) set spotlight exponent |
| | setCutoff (const GLfloat cutoff) set spotlight cutoff |
| | setAttenuation (const GLfloat *attenuation) set light attenuation coefficients |
| | glSet (void) recomputes if needed and executes material display list |
| | enable (void) enable (use) light |
| | disable (void) disable light plane |
| | displayFantom (bool disp) choose whether to display a graphical representation fo this spot light |
| | putInCamera (void) set spot light in scene |
| | getCamera () const returns the camera that is lit |
| | constructors
| ||||
| | destructor
|
| | fantom light graphic primitive |
| | camera camera owning this light |
| | index OpenGL light id |
| | active is light active |
| | ambient [4] light ambient coefficients |
| | diffuse [4] light diffuse coefficients |
| | specular [4] light specular coefficients |
| | position [4] light source position |
| | direction [3] spot direction |
| | exponent spotlight exponent |
| | cutoff spotlight cutoff (in degrees) |
| | attenuation [3] spotlight constant, linear and quardatic attenuation factors |
OpenGL light
CameraOGL* camera
GLenum index
bool active
GLfloat ambient[4]
GLfloat diffuse[4]
GLfloat specular[4]
GLfloat position[4]
GLfloat direction[3]
GLfloat exponent
GLfloat cutoff
GLfloat attenuation[3]
constructors
Light(CameraOGL *cam)
Light(CameraOGL *cam, const GLfloat *ambient, const GLfloat *diffuse, const GLfloat *specular, const GLfloat *position, const GLfloat *direction = 0, GLfloat exponent = 0.0, GLfloat cutoff = 180.0, const GLfloat *attenuation = 0)
ambient - ambient light 4 coefficients
diffuse - diffuse light 4 coefficients
specular - specular light 4 coefficients
position - light position 4 coefficients
direction - spotlight direction 3 coefficients
exponent - spotlight exponent
cutoff - spotlight cutoff (in degrees)
attenuation - spotlight 3 attenuation factors
destructor
void setLight(const GLfloat *ambient, const GLfloat *diffuse, const GLfloat *specular, const GLfloat *position, const GLfloat *direction = 0, GLfloat exponent = 0.0, GLfloat cutoff = 180.0, const GLfloat *attenuation = 0)
diffuse - diffuse light 4 coefficients
specular - specular light 4 coefficients
position - light position 4 coefficients
direction - spotlight direction 3 coefficients
exponent - spotlight exponent
cutoff - spotlight cutoff (in degrees)
attenuation - spotlight 3 attenuation factors
GLenum getIndex(void) const
bool isActive(void) const
const GLfloat* getAmbient(void) const
const GLfloat* getDiffuse(void) const
const GLfloat* getSpecular(void) const
const GLfloat* getPosition(void) const
const GLfloat* getDirection(void) const
GLfloat getExponent(void) const
GLfloat getCutoff(void) const
const GLfloat* getAttenuation(void) const
void setAmbient(const GLfloat *ambient)
void setDiffuse(const GLfloat *diffuse)
void setSpecular(const GLfloat *specular)
void setPosition(const GLfloat *position)
void setDirection(const GLfloat *direction)
void setExponent(const GLfloat exponent)
void setCutoff(const GLfloat cutoff)
void setAttenuation(const GLfloat *attenuation)
void glSet(void)
void enable(void)
void disable(void)
void displayFantom(bool disp)
alphabetic index hierarchy of classes
this page has been generated automatically by doc++
(c)opyright by Malte Zöckler, Roland Wunderling
contact: doc++@zib.de