banner



How Ot Use Two Images For One Texture On Maya

This chapter is from the book

Texture Mapping

The adjacent step is to replace a surface'south solid color with a texture. Normally, a texture refers to applying a 2nd image around a 3D surface, rather like wallpapering a curvy surface. Considering a 2nd paradigm tin can exist stretched, wrapped, and projected onto a surface in many different ways, you must accept control of how the image is applied.

Mapping Coordinates

Mapping coordinates, also known as UV coordinates, tell the 3D renderer how to place the 2D map across the geometry, which varies depending on whether the model is created from NURBS or polygons. For NURBS, parametric mapping is inherent to the surface and this is typically what's used. Because NURBS are already parametric surfaces, mapping can automatically period smoothly across the surface. You lot tin can as well accommodate NURBS mapping, to motility and rotate how the map is positioned on the object.

For polygon surfaces, mapping is commonly applied by projecting 2D maps across the 3D surface in i of several means: planar, cylindrical, spherical, and a special method called automated mapping. As y'all might expect, when you utilize a second texture to a 3D object with a planar map project, you'll meet a smearing effect in areas of the object that'due south perpendicular to the direction of the map projection. The cylindrical and spherical projections would seem to solve this trouble, but both mapping types take their drawbacks—singularities. These are points at the poles of the sphere or cylinder where the mapping is pinched into a point (see Effigy 8.15). Generally, you must apply the best mapping method for the surface and the areas seen during the blitheness. That is, if the ugly part is in an expanse that won't be visible to the camera during the animation, the problem is solved. In tough cases, a combination of automatic mapping, multiple mapping coordinates, and lots of photoediting piece of work can commonly fix the problem.

Figure 8.15Figure 8.xv Three teapots with planar, cylindrical, and spherical mapping (from left to correct).

Maya's Interactive Texture Placement

To make adjusting mapping on a surface less confusing, Maya offers interactive texture placement. This characteristic lets you encounter the maps motility on the surface in real time as yous move, rotate, and scale the manipulator for the mapping. To make this work, you demand to have Hardware Texturing turned on for at to the lowest degree 1 of the 3D panels. To exercise that, select the panel (RMB-click over the panel) and then click Hotbox | Shading | Hardware Texturing (hotkey: 6). By default, materials with a texture applied to the Color attribute accept the color texture map gear up to appear in the hardware-textured panels.

Procedural Maps Explained: second Versus 3D

In addition to applying an paradigm or movie to a surface, Maya provides many other texture types called procedural textures. Instead of using bodily images for mapping, procedural textures use formulas. Many patterns, such as bricks, tiles, and gradients, are so repetitive that they can hands be represented by an equation. By using special forms of seemingly random values, many natural effects can exist fake mathematically: Marble, leather, water, granite, and many other complex and random textures are included with Maya as procedurals.

Maya's procedural textures come in two varieties: second and 3D. Y'all can think of the 2D procedurals as a calculated grade of a bitmap. A formula is responsible for the image, but the paradigm must exist applied to the 3D geometry with some form of mapping, so it'south subject to all the benefits and drawbacks of 2nd mapping. When 3D procedurals are applied, however, they exist throughout 3D infinite, and object surfaces define where yous run across the texture. It's similar etching the object from a block of the material. This method has the benefit of not requiring any mapping, but if the object bends or warps, the procedural texture can seem to "swim" through the object (but Maya has an avant-garde option for getting around this limitation called Texture Reference Objects).

Procedural textures take several benefits. Because they are formula based, their parameters can be adjusted to instantly synthesize all kinds of different furnishings. Because the simulated random "noise" used for the natural textures varies at every betoken in infinite, the procedurals don't repeat, as is mutual with a tiled prototype of, say, marble. Also, considering 3D procedurals be throughout 3D space, you frequently become skillful results on objects that would otherwise be hard to map. Instead of trying to wrap a 2D texture around a complicated sculpture, you can apply a 3D procedural and it will appear to be perfectly mapped.

2nd Procedurals

Maya's 2nd procedurals tin be divided into two categories: regular patterns and dissonance patterns. The regular patterns include grid, checker, burl, cloth, and ramp. With these patterns, you tin create tiles, bricks, and many other man-made repeating effects. Noise patterns include fractal, mountain, noise, and water. These psuedorandom textures are excellent for creating the complex "dirty" surfaces common in nature.

3D Procedurals

All of the 3D procedurals just snow are random types. Some, such as woods and marble, conspicuously imitate nature. However, all are excellent for synthesizing random furnishings. Even when animating a human being-made globe such every bit a building interior, yous still need noisy patterns—the crash-land texture on ceiling tiles, some splotchy carpet patterns, and fifty-fifty the brushed solid-colour pigment on walls are slightly randomly textured.

Tutorial: Applying Textures

In this tutorial, y'all'll utilise some textured materials to the objects and edit the placement of those textures. Y'all tin can load the scene file noted hither to selection up from the end of the "Creating Solid Materials" tutorial.

On the CD

Chapter_08\movies\ch08tut04.wmv

  1. Open Hypershade (hotkey: Shift+T). Make sure the Create Bar and both tab panels are displayed. RMB-click the Create Bar and ready it to Create Materials. MMB-drag a Blinn textile to the bottom tab console, and double-click it to open the Attribute Editor.

On the CD

Chapter_08\ch08tut01end.mb

  1. Rename the material checkerfloor, and click the checkered push to the right of the color swatch. The Create Return Node dialog box opens to the Textures tab, displaying all the 2D and 3D procedurals and textures (see Figure 8.16). Click on the Checker type to apply it to the Colour attribute.

Figure 8.16Figure 8.xvi The Create Render Node dialog box lists all bachelor map types.

  1. Make the Perspective view full screen and set it to Shaded view (hotkey: 6). Actuate Hardware Texturing for this view (Hotbox | Shading | Hardware Texturing).

  2. Y'all'll use the drag-and-drop method to utilise a material to an object. MMB-elevate the checkerfloor swatch from the top tab panel of Hypershade to the scene's floor surface. You should see a checkerboard appear on the floor.

  3. Double-click the checkerfloor material in Hypershade to make information technology agile in the Attribute Editor. In the Aspect Editor for the material, open the Hardware Texturing department, and set the Texture Quality to Loftier. You should meet the checkerfloor texture sharpen in the Shaded view.

  4. In the Attribute Editor for the checkerfloor cloth, the Color swatch is light gray, and the icon to the right of the Color slider has changed from a checkered button to a right-pointing pointer, indicating that the color has been overriden by something else. Click the right-pointer icon to have the Attribute Editor display the parameters for the Checker node.

TIP

To navigate back to the original node after you lot take practical a texture, click the right-pointer icon. If you need to disengage a texture'due south assignment, RMB-click on the name of the entry and cull Intermission Connectedness, as shown in Figures eight.17A and 8.17B.

Figure 8.17AFigure viii.17A Use the lower of the ii connexion buttons, "go to input connexion," to render to the material's base of operations backdrop when finished editing a texture.

Figure 8.17BEffigy 8.17B Right-click over the text label for a material attribute to become a dialog option to "break connection"—removing the texture that was assigned to that aspect.

  1. A dialog box opens where you tin alter the colors of the checkerfloor fabric from black and white to other colors, equally shown in Figure 8.xviii. To the right of these color sliders are checky buttons you can click to replace one of checkerfloor'south solid colors with another texture. To supercede the white squares in checkerfloor with a 3D marbled texture, click the checky button to the right of Color1 (white), and then click Marble under 3D Textures in the Create Render Node dialog box.

  2. The Attribute Editor at present shows the settings for the marble texture. The veins in the marble are much too tiny for your scene, however. To scale the procedural marble texture higher, click the place3dTexture tab in the Attribute Editor, and set the iii Calibration values to ten. Render the Perspective view, and you should meet a marbled checkerfloor cloth. The flooring is somewhat reflective considering the default Reflectivity value of 0.5 was assigned to checkerfloor.

Figure 8.18Figure eight.18 The Checker texture node in the Attribute Editor.

  1. Next, yous'll place a 2D texture on the polygonal shield object with the text "Maya Fundamentals." Create a new Blinn fabric, and open the Attribute Editor. Proper noun the cloth m4fshield. Click the checkered button next to Colour, and in the Create Render Node dialog box, select File in the 2D Textures section. Next to the Paradigm Proper name text box in the Attribute Editor, click the button with the folder icon to select the prototype you want to apply. For this object, it's the file noted below the CD icon. Later on selecting and accepting the file, click the m4fshield textile in the top tab area of Hypershade. And then MMB-drag the textile onto the shield object to the correct of the blossom pot. You should encounter the texture announced in a distorted way.

The shield is a polygonal object fabricated with a revolve. Mapping is applied to the revolve, but information technology's applied circularly in the direction the spline spins to create the surface. In this example, you merely desire a apartment sign on the front of the shield, and so you demand to override the default mapping that has been applied.

  1. Select the shield object and planar map it (Hotbox | Edit Polygons | Texture | Planar Mapping). You should run across the mapping on the surface modify immediately, and the mapping manipulator is displayed.

  2. Now you tin adjust the size and position of the map manipulator to make the text fit neatly on the shield. In one corner of the manipulator is a red "L"; when yous click on it, it turns yellow and iii manipulator handles appear: a unmarried circle (for activating Rotate mode) and the Scale and Move icons with X, Y, and Z active, as shown in Effigy 8.19. If y'all click on the circle, the Rotate 10, Y, and Z manipulators appear, as shown in Figure 8.xix. Using these manipulators, you can transform the application of the prototype to the shield until it's placed correctly. Note that if you click the corner "L" over again, the manipulator reverts to its original mode, which is designed for like shooting fish in a barrel sizing. Use the corner Ls (to the left in Effigy 8.xix) to arrange the map's size.

Figure 8.19Figure 8.19 The planar mapping manipulators have been pulled away from the geometry to show the two placement modes, toggled by clicking the corner "L" at the lower left of the manipulator.

  1. Now return the view to see what the materials look like. Figure 8.twenty shows the planar mapping manipulator in its adapted placement.

  2. If y'all need to bring the manipulator handles back for texture placement, you can practise and so past selecting the object, opening the Channel Box (hotkey: Shift+C), and clicking the polyPlanarProj entry. If this fails, you need to open the Tool Box (Hotbox | Brandish | UI Elements | Tool Box). The sixth icon from the top in the Tool Box, just below Calibration, is the Show Manipulator Tool button. Click that to get your map manipulator back. The hotkey for the Show Manipulator Tool is t.

Figure 8.20Figure eight.xx The final scene, rendered with the shield map in place. Note that the glass torus doesn't appear in the Shaded view.

On the CD

Chapter_08\ch08tut04end.mb

How Ot Use Two Images For One Texture On Maya,

Source: https://www.peachpit.com/articles/article.aspx?p=31330&seqNum=6

Posted by: manzeroravialf.blogspot.com

0 Response to "How Ot Use Two Images For One Texture On Maya"

Post a Comment

Iklan Atas Artikel

Iklan Tengah Artikel 1

Iklan Tengah Artikel 2

Iklan Bawah Artikel