Difference between revisions of "Lighting optimization"
m (→RAM & VRAD)
|Line 22:||Line 22:|
== RAM & VRAD ==
== RAM & VRAD ==
If VRAD needs more RAM
If VRAD needs more RAM you have physically installed, it will page memory to the disk and slow down your compile time greatly. Lower lightmap scales to reduce memory usage.
Revision as of 11:44, 1 May 2011
There are two areas where optimisation can be performed:
A higher Lightmap scale can cause more texture memory to be used, and can impact performance slightly when in the same scene of other materials that effect the total memory usage. Use larger scales wisely when there aren't other expensive materials within the Scene. This even takes effect when there isn't any lighting baked onto a Lightmap, therefore reducing the quality of a Lightmap in a dark area can counter for higher scales in expensive scenes. Lastly, Lightmap Quality also can effect the map file size, and compile time.
VRAD assumes that all named lights will be switched on or off at some point, and compiles an extra version of all lightmaps the light touches to provide for this. Not only does this bloat map size, VRAD compiles direct lighting only to reduce the number of lightmaps that need to be touched (i.e. no bounced light). Don't name static lights unless you really have to!
Dynamic lights are expensive and must be carefully managed. Their number is important, but also what they are pointing at: the more complex the surfaces and numerous the models at which a dynamic light points, the more expensive it becomes. This makes them particularly unsuited to multiplayer maps where it is unclear where the action will be.
It's best, from a performance standpoint, to simply avoid dynamic light unless you notice a large parcel of your budget going unused. Players will be used to static light and won't expect anything better unless you set a precedent yourself.
RAM & VRAD
If VRAD needs more RAM than you have physically installed, it will page memory to the disk and slow down your compile time greatly. Lower lightmap scales to reduce memory usage.