Page 354 OpenGL Super Bible! glLight Purpose Sets light source parameters for one of the eight available light sources. Include File Variations void glLightf(GLenum light, GLenum pname, GLfloat param ); void glLighti(GLenum light, GLenum pname, GLint param ); void glLightfv(GLenum light, GLenum pname, const GLfloat *params ); void glLightiv(GLenum light, GLenum pname, const GLint *params ); Description Use this function to set the lighting parameters for one of the eight supported light sources. The first two variations of this function require only a single parameter value to set one of the following properties: GL_SPOT_EXPONENT, GL_SPOT_CUTOFF, GL_CONSTANT_ATTENUATION, GL_LINEAR_ATTENUATION, and GL_QUADRATIC_ATTENUATION. The second two variations are used for lighting parameters that require an array of multiple values. These include: GL_AMBIENT, GL_DIFFUSE, GL_SPECULAR, GL_POSITION, and GL_SPOT_DIRECTION. These variations may also be used with single valued parameters by specifying a single element array for *params. Parameters light GLenum: Specifies which light source is being modified. This will range from 0 to GL_MAX_LIGHTS (8 for Windows NT and Windows 95). Constant light values are enumerated from GL_LIGHT0 to GL_LIGHT7. pname GLenum: Specifies which lighting parameter is being set by this function call. See Table 9-2 for a complete listing and the meaning of these parameters. param GLfloat, or GLint: For parameters that are specified by a single value, this specifies that value. These parameters are: GL_SPOT_EXPONENT, GL_SPOT_CUTOFF, GL_CONSTANT_ATTENUATION, GL_LINEAR_ATTENUATION, and GL_QUADRATIC_ATTENUATION. These parameters only have meaning for spot lights. params GLfloat*, or GLint*: An array of values that fully describe the parameters being set. See Table 9-2 for a listing and the meaning of these parameters. Returns None. Example
If you are looking for affordable and reliable webhost to host and run your business application visit our ftp web hosting services.
This entry was posted
on Tuesday, September 18th, 2007 at 8:10 am and is filed under Coldfusion.
You can follow any responses to this entry through the RSS 2.0 feed.
You can leave a response, or trackback from your own site.