Thư viện tri thức trực tuyến
Kho tài liệu với 50,000+ tài liệu học thuật
© 2023 Siêu thị PDF - Kho tài liệu học thuật hàng đầu Việt Nam

Introducing 3ds Max 9 3D for beginners apr 2007 - part 7 pptx
Nội dung xem thử
Mô tả chi tiết
Later in the chapter, you will learn a more efficient way to edit the image on the
object, known as UVW mapping.
Opacity Maps
Opacity mapping allows you to cut out parts of an object by making those parts invisible.
You can also create wonderful fading effects using Opacity maps. With opacity mapping,
you don’t have to model certain details, which can be a real time saver. In this example,
you will create a chain link fence. However, you will not model a fence. You will create it
entirely from mapping. To make a chain link fence, follow these steps:
1. Open the Chain Link Opacity Map.max file in the Texture Scene Files folder on the
companion CD. Open the Material Editor and select a sample slot. First, you are going
to add a bitmap to the diffuse color, so go to the Maps rollout. Select the bar next to
Diffuse Color. Pick Bitmap from the Material/Map browser and navigate to the Texture Scene Files folder on the CD. Choose Chain Link.tif (shown in Figure 7.41).
2. Go to the Coordinates rollout and change both the U and V Tiling parameters to 3.0.
This will scale down the image because the image repeats three times.
3. Apply the Material to the Plane geometry in the scene. Click the Show Map in Viewport button. Render and you will see something similar to Figure 7.42. As you can
see, the Chain Link image appears on the plane, but you can’t see the objects on the
other side.
Figure 7.42
The chain link fence
is rendered.
more mapping exercises ■ 313
Figure 7.41
The chain link
texture
97612c07.qxd 2/26/07 2:56 PM Page 313
4. Go to the Material Editor. Click the Go to Parent button to get to the Maps rollout for
the parent material. Click on the bar next to Opacity and select Bitmap from the
Material/Map browser. In the Explore window, navigate to the Texture Scene Files
folder on the CD and select Chain Link OP.tif (shown here).
5. The tiling values for the Opacity map must be the same as the diffuse map; otherwise
the transparency of the fence will not line up with the links of the fence. Go to the
Coordinates rollout, and change both the U and V Tiling to 3.0. Render to see the
results shown here.
You can see immediately how useful opacity mapping can be. 3ds Max uses the white
portions of the image map to display full opacity, whereas the black areas become transparent. If you did not have an opacity file such as the one in this exercise, you could easily
create one by painting a black-and-white matte of the color image that you are using for
the material.
314 ■ chapter 7: Materials and Mapping
97612c07.qxd 2/26/07 2:56 PM Page 314
Mapping Coordinates
An image map is a two-dimensional entity that has length and width but no depth, while
geometry in 3ds Max extends in all three axes. How is a material, which contains 2D image
maps, applied properly to a scene object? Are the maps projected in a single direction onto
the object’s surfaces or do they envelop the object cylindrically or spherically? The answer
depends on the type of mapping coordinates applied to the object. Mapping coordinates
define how and where image maps are projected onto an object’s surfaces and whether the
maps are repeated across those surfaces.
Mapping coordinates are applied to objects in several ways. When primitive objects are
created and the Generate Mapping Coords option is checked, at the bottom of the Parameters rollout, the appropriate mapping coordinates are created automatically. The Generate Mapping Coords option is on by default.
Loft objects, which are covered in Chapter 5, control mapping in the Mapping section
of the Surface Parameters rollout. The Length Repeat value determines how many times
the material’s maps are repeated along the length of the Path object, and the Width Repeat
value determines how many times the maps are repeated around the shape object. The
configuration of the shape or path object is irrelevant to the application of the mapping
coordinates; the loft object can create mapping coordinates for any loft object. Figure 7.43
shows a loft object with a simple checker pattern repeated five times along the object’s
length and three times around the perimeter of the shape.
Figure 7.43
A loft object controlling a checker map’s
repetition in the Surface Parameters
rollout
mapping coordinates ■ 315
97612c07.qxd 2/26/07 2:56 PM Page 315
The UVW Map modifier is a common method for applying and controlling mapping
coordinates. You select the type of mapping projection, regardless of the shape of the
object, and then set the amount of tiling in the modifier’s parameters. The mapping coordinates applied through the UVW Map modifier override any other mapping coordinates
applied to an object, and the Tiling values set for the modifier are multiplied by the Tiling
value set in the assigned material.
Assign the UVW Map Modifier
Now let’s take a look at how to apply a UVW Map Modifier in a scene. The following
exercise examines the use of the UVW Map modifier:
1. Open the UVW.max file in the Texture Scene Files folder on the companion CD. This scene
consists of a wall object with a linked window and two significantly different boxes.
MAPPING COORDINATES AND BOOLEANS
Boolean compound objects handle mapping in their own unique ways. When only Operand A has a mapped material,
that material and its mapping coordinates are inherited by the resultant Boolean object. When only Operand B
has a mapped material, the option of applying that material and mapping
appears in the form of a dialog box. When both operands have mapped
materials, the Material Attach Options dialog box presents several options
to use or discard the materials and mapping.
Objects that have been collapsed or converted to editable polys, editable meshes, or editable
patches do not have inherent mapping coordinates. They must have the UVW Map modifier
applied to utilize mapped materials.
316 ■ chapter 7: Materials and Mapping
97612c07.qxd 2/26/07 2:56 PM Page 316
2. Open the Material Editor and then assign the Brick Wall material to the wall object.
The material appears on the object in the Camera01 viewport.
The problem is that the long wall is approximately 17 feet long and the short wall is
approximately 7 feet long, and the Brick map used in the material is only eight bricks
wide. The default mapping coordinates for a wall object applies the entire map to any
vertical surface of the wall, regardless of how long that wall is. The long wall has eight
bricks stretched along its length, just as the shorter wall does.
3. Select the wall. In the Modify panel, expand the Modifier List and then select the
UVW Map modifier.
The mapping changes and now appears to streak vertically, as shown in Figure 7.44.
This is because the default Planar mapping type projects the map onto the object parallel
to the plane-shaped gizmo. The vertical lines that appear are the same color as the brick
image’s pixels where the surface of the object intersects the gizmo. To fix the issue, continue with the following steps:
mapping coordinates ■ 317
97612c07.qxd 2/26/07 2:56 PM Page 317