This entity represents a dynamic light source. More...

Public Member Functions | |
| dr dg db sr sg sb | GetColor () |
| Returns both the diffuse and the specular color of this light source as a 6-tuple. More... | |
| SetColor (number r, number g, number b) | |
| Sets the color (both diffuse and specular) of this light source. More... | |
| SetColor (number dr, number dg, number db, number sr, number sg, number sb) | |
| Sets the color (diffuse and specular separately) of this light source. More... | |
| number | GetRadius () |
| Returns the radius of this light source. More... | |
| SetRadius (number r) | |
| Sets the radius of this light source. More... | |
Public Member Functions inherited from BaseEntityT | |
| string | GetName () |
| Returns the name of this entity. More... | |
| x y z | GetOrigin () |
| Returns the origin of this entity as a triple of numbers. More... | |
| SetOrigin (number x, number y, number z) | |
| Sets a new position for this entity. More... | |
This entity represents a dynamic light source.
Dynamic light sources cast dynamic, per-pixel computed light. Its shading details and shadows are updated with each rendered frame.
EntPointLightSourceT entities are easy to use, but note that too many of them with a too large radius in a single scene can negatively affect the rendering performance.
See http://www.cafu.de/wiki/mapping:cawe:lighting for more details about the available kinds of light sources and their characteristics.
PointLightSource | dr dg db sr sg sb GetColor | ( | ) |
Returns both the diffuse and the specular color of this light source as a 6-tuple.
| number GetRadius | ( | ) |
Returns the radius of this light source.
The radius determines the distance from the light source origin at which the light intensity has dropped to zero.
| SetColor | ( | number | r, |
| number | g, | ||
| number | b | ||
| ) |
Sets the color (both diffuse and specular) of this light source.
The parameters r, g and b are numbers between 0 (no contribution) and 255 (max. contribution) for the respective color component.
| r | The red component of the light color. |
| g | The green component of the light color. |
| b | The blue component of the light color. |
| SetColor | ( | number | dr, |
| number | dg, | ||
| number | db, | ||
| number | sr, | ||
| number | sg, | ||
| number | sb | ||
| ) |
Sets the color (diffuse and specular separately) of this light source.
The parameters are numbers between 0 (no contribution) and 255 (max. contribution) for the respective color component.
| dr | The red component of the diffuse light color. |
| dg | The green component of the diffuse light color. |
| db | The blue component of the diffuse light color. |
| sr | The red component of the specular light color. |
| sg | The green component of the specular light color. |
| sb | The blue component of the specular light color. |
| SetRadius | ( | number | r | ) |
Sets the radius of this light source.