Vegetation Material Setup

Textures

  • Diffuse Map: RGB should contain diffuse color. Alpha should contain opacity (used for alpha test)
  • Normal map (optional): RGB should contain normal map. Alpha (optional) should contain gloss map. If there is no texture assigned, you can get very good performance/memory saving/optimization.
  • Specular map (optional): RGB should contain specular color. If no texture is assigned, the normal map alpha channel will be used as gloss map. If there is no texture assigned, you can get very good performance/memory saving/optimization.
  • Opacity map (optional): RGB should contain opacity color used in backlighting. This texture can be a much lower resolution than all others (eg: if diffuse is 1024x1024 this could be 128x128). If there is no texture assigned, you can get very good performance/memory saving/optimization.

Shader Generation Parameters

  • Leaves: This means that the shader is only used for rendering leaves, it will use much more complex shading (=expensive). Activate only for leaves rendering.
  • Grass: This means that the shader is only used for rendering grass, it will use a much cheaper shading. Activate only for Grass rendering. It basically kills spec and normal map setting, so the shading is only diffuse.
  • Spherical Harmonics (SH): This is only to be used for particularly big Trees. It gives depth (darkness) information to the canopy (should be only used for leaves).

If you want to use this you need to export SH with from 3ds Max like this:

Make sure that the obstruct material in max looks like this:

Common Mistakes

  • Bump used when not necessary: If no bump is used, do not assign a bump texture like white_dnn.dds. Don't do this, it will be more expensive than no texture at all.
  • Specular/Opacity maps used when not necessary: Grass and other small ground bushes/plants do not need this. This will save a lot of memory.
  • Opacity map with the same resolution as other ones: This texture can be much smaller than the other ones.
  • Bad usage of glossiness values: Values of around 2 look extremely bad. Use at least 8 to get a decent result (see above images).