Darkplaces lighting/Special effects
(Created page with "{{navigation title|Lighting methods}} This chapter contains reference of various special effects hardcoded in light renderer. This special effects, applied or combined will he...") |
Revision as of 00:03, 6 August 2012
This chapter contains reference of various special effects hardcoded in light renderer. This special effects, applied or combined will help to create wide range of things, such as:switchable lights, projective lights, sunlight simulation, flickering lights and more.
Light styles
Stub!
Coronas
Coronas aimed to simulate glow around dynamic lights, which looks good on small and medium size lights. Coronas are customised per-light (size and brightness) an also can be placed without lights.
Cubemap filtering
A technique for modeling non-uniform light distribution according to direction, for example a lantern may use a cubemap to describe the light emission pattern of the cage around the lantern (as well as soot buildup discoloring the light in certain areas), often also used for softened grate shadows and light shining through a stained glass window (done crudely by texturing the lighting with a cubemap), another good example would be a discolight.
Any dynamic lightsource can have cubemap attached.
Planar shadows
Simplified global shadows which are cast from entities, not from lights (so planar shadows are just filters, they dont do any lighting math).
Planar shadows are either stencil or shadowmapped if shadowmapping is on.
Customized ModelLight
Lightgrid sampling (diffuse, ambient and light vector components) can be overriden by Client-side QuakeC. Allows various lighting effects on models (strobing, using different positions for sampling etc.)
Fog
Fog are global. Optionally, height plane and height texture can be defined which will make fog to fade with height.
Fog have the following options:
- density - how much fog to add per distance, this is virtual value. 1 means very strong fog.
- red - red component of fog color
- green - green component of fog color
- blue - blue component of fog color
- alpha - fog effect opacity (default is 1)
- mindist - distance to start applying fog at
- maxdist - maximal distance apply fog at
- top - origin of height plane at worldspace (game units)
- height - fog height fade in game units
- fadetexture - horizontal texture that resembles fading, left pixel if top bright, right is top dark. Can be used for non-linear fading.
Fog are set by console commands:
Next chapter: Light sources
Back to index | Top of the page