May06
2013

Using a structured and pragmatic approach Getting Started in 3D with Maya begins with basic theory of fundamental techniques of 3D modeling in Autodesk Maya, then builds on this knowledge using practical examples and projects to put your new skills to the test. In this excerpt, Adam provides a polygon primer for beginners.

Figure 01: A portrait of the star of the 3D show – the polygon . The polygon is both the star, and the smallest of players – it is what all forms (that we see) are made of.

Parts of a Polygon

Polygons have several component parts. These components are labeled in the Figure 01 above . Let’s talk about them for a minute:

Face : This is what we intuitively think of as the polygon. It’s the surface that we actually see. While it has a width and height, it has no depth – it’s infinitely thin.

Normal : A polygon’s normal is simply its front. The simplest way to think of this is that every polygon has a front and a back, and the normal (by default) runs perpendicular to the front of the face. This can be a little abstract until it’s seen in action (which we will examine in a little bit); but this becomes very important in situations like game creation because games (in order to draw things faster) don’t draw the backs of polygons. So, if the normal of a polygon is facing the wrong way, the polygon isn’t seen within a game engine. Normals can be further tough to understand because they aren’t shown by default when selecting a component and can be a little obscure to control. Not to worry though; we’ll spend some good time talking about them and especially getting them to face the direction they need to.

Edge : A face is surrounded by edges. These edges define the limitations of the polygon and the face. These edges also exist within 3D space, but actually contain no geometry of their own – they simply help describe the geometry of the polygon. When an edge is moved, rotated, or scaled, it changes the shape of the face and thus the polygon.

Vertex : Each edge has a vertex on either end of it. Vertices are one dimensional components that exist in 3D space. When a vertex is moved (one vertex cannot be scaled or rotated), it changes the length of the edges it is a part of, thus changing the shape of the polygons those edges contain. Do note, that a collection of vertices can be rotated or scaled which really is simply moving their relative location to each other.

UVs : These are really less of a “what” and more of a “where.” They are a coordinate system that allows Maya (or any 3D program) to know how to attach a texture to a collection of polygons. They are not particularly modifiable in 3D space – and really need to be handled in 2D space – most particularly in something we call “texture space.”

Traits of Polygon

To understand what polygons are and how they work, consider this metaphor. Polygons are like very thin (but very rigidly strong) plates of metal. An individual polygon cannot bend – it is planar. However, multiple polygons can be joined along their edges, and they can indeed bend where they connect. What this means is that if you take six polygons and attach them to each other, so that they share edges and vertices, you get a cube ( Fig 02 ). Increase the number of polygons and the number of places where the shape can bend increases; this means a form can become more and more round as the polygon count increases.

Figure 02 : Increasing polygon count increases curve possibilities.

But notice that even the seemingly smooth sphere on the far right of the Figure 02 is still made of non-bending polygons. Check out the close-up of that sphere shown in Figure 03 below – see the edges of those polygons?

Figure 03: Close-up of a smooth sphere and the still non-smooth, rigid polygons.

Polycounts

So what does this mean for us? Well, polygons are not only the building blocks of shapes but also the building blocks of the data set that the computer must keep track of for any shape or scene. Especially in situations like games, this data set can be hugely important when considering frame rates (the rate— frames in a second—at which the video card is able to display the information of a scene). Too many polygons and the computer simply can’t process them, and the video card can’t draw them fast enough to allow for any sort of meaningful game-play.

Now, to be fair, polycount (the number of polygons in a scene) is rarely the most limiting factor of game-play. Textures and dynamic shadows usually have a bigger influence on that with today’s hardware. But get too many polys and even the most robust systems can be ground to a halt in both games and inside of Maya as the scene is being manipulated.

Thus, the age old dilemma – and the craft of good 3D – is to use as many polygons as are needed to describe a form, but no more. How many is too many?  The answer is tough and really a moving target. Too many for my machine as I’m writing this may be different for your machine when you read this. Not long ago, a scene with a million polys was way too many to work with and today that’s almost a trivial amount.

So the answer is: depends. I know, terribly unsatisfying, but along the way in our tutorials (found in the book), we will always be keeping our eye on efficient use of polys, so that we can ensure a project that is most useful on the most machines.

This is an excerpt from Getting Started in 3D with Maya. Getting Started in 3D with Maya can be purchased at Amazon.com, BN.com, and wherever fine books can be found

Adam Watkins is Associate Professor, 3D Animation, School of Interactive Media & Design at the University of the Incarnate Word. He is currently on a research sabbatical at the Los Alamos National Laboratory in New Mexico, where he is part of the VISIBLE effort creating virtual simulation games for use in non-proliferation exercises. Watkins has headed the 3D Animation program for over ten years and is the author of several books and over 100 articles on 3D Animation. His students are the winners of multiple national and international animation awards and festivals.