Ambient light

From Valve Developer Community
Revision as of 01:50, 21 May 2018 by Pinsplash (talk | contribs) (did what i can for the TODOs)

Jump to: navigation, search

Console commands

mat_leafvis 1; r_visambient 1
These two commands together enable the display the ambient lighting sample points in the active leaf.
r_flashlightambient <int>
Seems like it would be used for making ambient light originating from projected textures or for influencing the color of the flashlight based on ambient light. Does not do anything in Half-Life 2.
r_lightcache_numambientsamples <int>
Cheat. The number of random directions to fire rays when computing ambient lighting. Default 162. Requires map restart.
Confirm:This only affects static props.
r_ambientlightingonly <bool>
Cheat. Light models with only ambient lighting; requires map restart.
r_radiosity <int>
Cheat. The manner in which radiosity is sampled. The console claims that there are four settings (0-3), each with different behaviours, but in practice the only two that seem to matter are 0 to disable and 4 to re-enable. This command is thus the opposite of r_ambientlightingonly.
r_ambientboost <bool>
Boosts ambient term if it is totally swamped by local lights.
r_ambientmin <float>
Threshold above which ambient cube will not boost (i.e. it's already sufficiently bright). Default 0.3.
r_ambientfraction <float>
Cheat. Fraction of direct lighting that ambient cube must be below to trigger boosting. Default 0.1.
r_ambientfactor <float>
Boost ambient cube by no more than this factor. Default 5.