This page is not finished
You can help by editing and extending it.
Static lightsources
Dynamic lightsources
World lights
Worlds lights are loaded from external .rtlights file supplied with a map (foo.bsp will try to load foo.rtlights). If there are not .rtlights file, engine tries to load lights from a map "light" entities, which often is grude and terrible slow (as "lights" are maked for map compiler LIGHT stage raytracer, not for reatime rendering). So producing a good .rtlights folr is very first step in a process of map creation.
World lights are static, meaning they canot be moved, rotated, altered during a game.
Tip: Blood Omnicide is using world lights to place lights for a Q3map2 LIGHT phase. So unlike Quake, which should have both "light" entities and .rtlights, Blood Omnicide .rtlights containins all map static lights
Each world light can have this parameters:
- origin : position
- angles : rotation
- color : RGB light color
- radius : radius of light in game units
- corona : corona intensity (0 to disable)
- coronasize : size of corona (this is multiplier to light radius)
- style : lights style number (see lightstyles above)
- shadows: whether to cast shadows from light
- cubemap : a path to cubemap filter texture
- ambient : ambient light intensity (ignores shading, makes lighting to be more 'flat')
- diffuse : shading light intensity (default is 1)
- specular : specular intensity (default is 1)
- normalmode : if this flag is set, light will be draws if cvar r_shadow_realtime_world is 0
- realtimemode : if this flag is set, light will be draws if cvar r_shadow_realtime_world is 1
Blood Omnicide tips:
Tip: A combination of normalmode = 0, realtimemode = 0 to mark lights which are only appear on lightmap
Tip: Light style 1 will make a dynamic lights that will not appear on lightmap
Tip: Cubemap-filtered lights dont appear on lightmap
Console variables:
r_shadow_realtime_world : Enables rendering of full world lighting (whether loaded from the map, or a .rtlights file, or a .ent file, or a .lights file produced by hlight)
r_shadow_realtime_world_lightmaps : Brightness to render lightmaps when using full world lighting
r_shadow_realtime_world_shadows : Enables rendering of shadows from world lights
r_shadow_realtime_world_compile : Enables compilation of world lights for higher performance rendering (shadow volumes only)
r_shadow_realtime_world_compileportalculling : Enables portal-based culling optimization during compilation (overrides compilesvbsp)
r_shadow_realtime_world_compileshadow : Enables compilation of shadows from world lights for higher performance rendering (shadow volumes only)
r_shadow_realtime_world_compilesvbsp : Enables svbsp optimization during compilation (slower than compileportalculling but more exact)
Tip: In Blood Omnicide, this console varisables are hardcoded since its using a combination of full realtime lightning and lightmaps. Tweak this settings only for debugging purposes or if you want to break something.
Dynamic lights
Dynamic lights are cast from entities. This could be both server-side entities such as rockets or client-side entities such as explosions.
r_shadow_realtime_dlight : Enables rendering of dynamic lights such as explosions and rocket light
r_shadow_realtime_dlight_portalculling : Enables portal optimization on dynamic lights
r_shadow_realtime_dlight_shadows : Enables rendering of shadows from dynamic lights
r_shadow_realtime_dlight_svbspculling : Enables svbsp optimization on dynamic lights
Next chapter: Tweaking
Back to index | Top of the page