Surface Normals and Display


Every surface in Maya has normals ( Figure 8.118 ). A normal is the line perpendicular to the plane tangent to the surface. In other words, the normal always points away from the surface. By default, a normal is also perpendicular to the face or vertex it's associated with.

Figure 8.118. This simple shape has both vertex and face normal display turned on, making it appear fuzzy.


Normals are important because they tell the renderer how to shade the surface. How bright a surface is depends on the angle at which light hits the surface. Flatter angles reflect more light and are brighter than obtuse angles. If you rotate a vertex normal, the renderer shades the area near it as if the surface was rotated (making it lighter or darker) ( Figure 8.119 ). However, the actual surface remains unchanged. Only the apparent angle of the surface is adjusted by the normal.

Figure 8.119. On the left, the normal is aligned with the surface, and light bounces back in a realistic way. On the right, the normal is rotated, so light bounces off the surface as if it were perpendicular to the normal. Because less light comes back, the surface appears darker (as if it were turned away from the camera).


With polygon objects, you have a good deal of control over the normals. You can do things like average the normals across a surface to give the appearance of smoothing, or adjust the angle of the normals to put the appearance of detail where there is none.

Adjusting and smoothing normals is a crucial part of low-poly modeling, which is used frequently in game production.

To display vertex normals:

1.

Select a polygon object.

2.

Choose Display > Custom Polygon Display.

The Custom Polygon Display Options dialog box opens ( Figure 8.120 ).

Figure 8.120. Use the Custom Polygon Display Options dialog box to display vertex normals.


3.

In the Vertices section, select Normals, and then click Apply.

The selected object displays the vertex normals with lines pointing from the vertices ( Figure 8.121 ).

Figure 8.121. The selected object displays the vertex normals with lines pointing from the vertices.


By controlling the angle of the vertex normals, you can make a low-res surface look smoother than it actually is.

To soften or harden vertex normals:

1.

Create a polygon sphere by selecting Create > Polygon Primitives > Sphere.

2.

Press to switch to shaded mode.

3.

Choose Polygon > Edit > Normals > Soften/Harden.

The Polygon Soften/Harden Edge Options dialog box opens (Figure 8.122).

Figure 8.122. Change the appearance of your object in the Polygon Soften/Harden Edge Options dialog box.


4.

Click All Hard (0), and then click Apply.

The sphere now has the appearance of a faceted surface ( Figure 8.123 ).

Figure 8.123. Click All Hard (0) to make the sphere look a little like the Death Star.


5.

Click All Soft (180), and then click Apply.

The sphere again has the appearance of a smooth surface (Figure 8.124).

Figure 8.124. Click All Soft (180) to make the sphere look smooth again.


Notice that the edges of the sphere don't smooth. Averaging the vertex normals to make things appear smooth is just a mathematical trick; it doesn't affect the actual geometry, so border edges are still sharp.

Tip

  • The slider hardens any edge more acute than the angle the slider is set to and leaves the rest soft. To soften gentle surfaces in your model but leave the right angles hard, set the slider angle to 90.


Face normals

The face normal determines which side of the surface to render. This is important when you're working on models for real-time display, because most real-time engines won't show a face from the back.

To display face normals:

1.

Select a polygon object.

2.

Choose Display > Polygon Components > Normals.

The face normals are displayed as perpendicular lines pointing up from the center of each face (Figure 8.125).

Figure 8.125. Face normals project from the center of each face in a polygon object.


By default, Maya creates double-sided polygons. If you create a single-sided polygon, the side of the face that has the normal is displayed. If you look at the polygon from the other side, you see right through it. This is also referred to as backface culling, as discussed in the "Modeling Polygons" section of this chapter.

To make a mesh single-sided:

1.

Press to switch to shaded mode.

2.

Select a polygon object ( Figure 8.126 ).

Figure 8.126. Select a double-sided object.


3.

Press to open the Attribute Editor for the selected object.

4.

In the Render Stats section, deselect Doubled Sided (Figure 8.127).

Figure 8.127. Deselect Double Sided in the polygon's Attribute Editor.


The object updates, and only one side of the object's surface is visible (Figure 8.128).

Figure 8.128. You can see through the back face of a single-sided surface.


Whether you're working with single- or double-sided polygons, it's important that normals on the same mesh all point in the same direction. However, normals on one surface may not face the same direction as those on another surface to which you're attaching. When this happens, many Maya functions (especially vertex normal softening) won't behave as expected. To correct this situation, select the offending faces and reverse their face normal.

To reverse a face normal:

1.

Select the polygon object.

2.

Display the face normals for the object as described earlier.

The face normals project from the centers of all the faces ( Figure 8.129 ).

Figure 8.129. The face normals point outward ...


3.

Choose Edit Polygons > Normals > Reverse.

The face normals now project in the opposite direction ( Figure 8.130 ).

Figure 8.130. ... until they're reversed.


Tips

  • You can set Maya to create singlesided polygonal surfaces by selecting Polygons > Tool Options > Create Meshes Single Sided.

  • You can apply all the normal tools to an entire object or just to selected faces. Many of these tools also work on selected vertices, faces, and edges.





Maya 7 for Windows and Macintosh(c) Visual Quickstart Guide
Maya 7 for Windows & Macintosh
ISBN: 0321348990
EAN: 2147483647
Year: 2006
Pages: 185

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net