Layout Texture on a Simple Cube
Maya 2012 Tutorial
How to Add a Texture to a Cube in Maya
Creating UV maps is an art form in itself. By understanding how to layout a UV map on a simple cube you will better understand the process as you attempt to map more complex objects.
Create a new project, set your project and save a new scene in the scenes folder. For more information, see topic, Starting a Project.
Add a polygon cube with default values to the workspace by choosing Create > Polygon Primitives > Cube. In the options, choose Edit > Reset Settings, then press Create.
To view the object and UV Texture Editor at the same time, choose Window > Saved Layouts > Persp/UV Texture Editor.
Select the cube. Notice that the UV Texture Editor displays the cube faces with the correct proportions.
Using the UV Editor as a template, you can create a texture in Photoshop that corresponds to the faces of the cube.
To save your image as a template for Photoshop, choose Polygons > UV Snapshot.
Note your image name and location. Set your image size using multiples of 128 (i.e., 256, 512, 1024, etc.).
Save your image as a tif file so you can open it in Photoshop. You can also use jpg or targa if you plan on opening the image in Photoshop.
Open your image in Photoshop. By default it can be found in your project's images folder.
In Photoshop, double-click the Background layer to make it a transparency layer. Add a new layer below the template layer.
With the upper layer selected, choose Image > Adjustments > Invert.
Double click the upper layer icon to open the layer options panel. Drag the upper layer Blend slider to 253 to remove the white portions of the upper layer.
Paint the lower layer while using the template as a guide.
Delete the upper layer, then flatten your image if you have multiple layers. Delete the Alpha channel from the Channels panel.
Save your image as texture01 in your project's sourceimages folder.
Returning to Maya, right-click the cube and choose Assign New Material > Lambert.
In the Attribute Editor, click the checkerbox next to the Color slider. In the Create Render Node panel, 2D Textures section, right-click the File icon and choose Create Texture.
In the Attribute Editor, click the Image Name folder to navigate to your image. The image is located in your project's sourceimages folder.
Click the Render Current Frame icon to see the cube with it's new texture.
Why an Alpha Channel?
In Step Eight we chose to save our template as a tif image. Maya automatically adds an alpha channel with tif files.
If we had chosen jpg, no alpha channel would have been created. If you attempt to add an image to an object with an alpha channel, the alpha information can be connected to the shader's transparency node.