3-D Visualization Previous page   Next Page

Back Face Lighting

Back face lighting is useful for showing the difference between internal and external faces. These pictures of cut-away cylindrical surfaces illustrate the effects of back face lighting.

The default value for BackFaceLighting is reverselit. This setting reverses the direction of the vertex normals that face away from the camera, causing the interior surface to reflect light towards the camera. Setting BackFaceLighting to unlit disables lighting on faces with normals that point away from the camera.

You can also use BackFaceLighting to remove edge effects for closed objects. These effects occur when BackFaceLighting is set to reverselit and pixels along the edge of a closed object are lit as if their vertex normals faced the camera. This produces an improperly lit pixel because the pixel is visible but is really facing away from the camera.

To illustrate this effect, the next picture shows a blowup of the edge of a lit sphere. Setting BackFaceLighting to lit prevents the improper lighting of pixels.


Previous page  Specular Color Reflectance Positioning Lights in Data Space Next page

© 1994-2005 The MathWorks, Inc.