Shadow Map

A shadow map is a bitmap that the renderer generates during a pre-rendering pass of the scene. Shadow maps don't show the color cast by transparent or translucent objects. On the other hand, shadow maps can have soft-edged shadows, which ray-traced shadows cannot. The parameters can be changed in the Shadow Map Parameters Rollout.

Example of shadow-mapped shadows

A shadow-map is projected from the direction of the light. This method provides a softer edge and can require less calculation time than ray-traced shadows, but it's less accurate.

Each light object has its own shadow-map settings. You can adjust these settings to achieve a sharper shadow. This involves changing the resolution and the pixel sampling of the shadow's bitmap. Because shadow-map shadows are only bitmaps, you need to keep in mind their resolution in relation to your distance from the shadow, and the detail required by the shadow. If the resolution is too low, and the camera too close, the shadow might look more like sooty smudges.

If shadows appear too coarse when you render them, increase the map size. The size can range from 0 to 10,000. However, be aware that greater size requires more memory and can take longer to generate. A 4096-line shadow map occupies 64 MB of memory (4096 x 4096 x 4).

If you have enough RAM to hold the entire scene including shadow maps, shadows don't affect performance, but if the renderer has to use a virtual memory swap file, rendering time can slow considerably.

The default shadow map size is 512.

For a spotlight, the bitmap used by shadow maps must fill the area covered by the falloff of the light. The wider the falloff, the coarser the shadow appears. Keep the falloff as tight as possible given the requirements of your scene.

The mental ray renderer saves shadow maps as ZT files. In addition to the settings for individual lights, the mental ray renderer includes shadow map controls on the Render Setup dialog Renderer panel Shadows & Displacement rollout.