A very useful function.
Set the light values of each vertex directly
Actually this function merely calls STATE_point_set_rgb() for all the points of the given polygon
Here are some uses of this function:
1) make a polygon brighter or darker or to alter its color.
2) Set different colors to each vertex (If a texture is used for this polygon
the the color of the vertixes will be mixed with the color of the texture
(a multiply mix so one can never make the texture brighter than the origibal)
3) The light API actually creates the illusion of light by manipulating the color of the
vertixes. One can use this function (together with STATE_point_set_rgb) to create an alternative light mechanism
though usually it is easier to use the light API to set the vertices color.
4) Create nice effects such as fading the polygon to the color of the background.
See also STATE_point_set_rgb()
|