Documentation

Unity Engine


User Manual

Script Reference

Unity Engine


LightmapParameters.AntiAliasingSamples

The number of sub-texel positions to use when sampling a lightmap texel.
Read time 1 minuteLast updated 12 days ago

Definition

  • Type: Enum
  • Namespace: UnityEditor
  • Assembly: UnityEditor
public enum LightmapParameters.AntiAliasingSamples

Remarks

The number of sub-texel positions to use when sampling a lightmap texel. Values higher than 1 will use supersampling to improve lightmap quality and reduce artifacts related to aliasing.
The default value of 4 should be sufficient to remove the majority of aliasing issues. However, in some cases it may be necessary to increase the number of sub-texel sample positions. This can be particularly useful where "jaggy" edges in direct lighting can be observed. Typically this is more visible when using baked shadows.
Note that memory usage increases proportionally to the number of samples used. Using high values in large Scenes may therefore increase the chance that lightmap bakes do not complete, especially when using large lightmap texture sizes.
Additional Resources: _antiAliasingSamples.