Baking Textures

Baking Textures

Maya 2012 Tutorial

 

How to Bake Lights and Shadows into a Maya Texture

 

 

Baking textures onto an object makes for faster render times and less texture problems. During the baking process you can choose to include or omit the shadows.

Depending on your render method, the baking process can vary. In this example, we will bake a texture onto an object and render the scene using the Maya Software. For Mental Ray, texture baking is a completely different process.

 

Step One

Open a new Maya document and start a new project. Be sure to set your project and save your new scene. For more information, see topic, Starting a Project.

Step Two

Add a NURBS sphere to the workspace by choosing Create > NURBS Primitives > Sphere.

Step Three

Select the sphere, then right-click the sphere and choose Assign New Material. Click the Lambert button in the Create Render Node.

Step Four

With the sphere selected, open the Attribute Editor, lambert tab and click the Color checkerbox.

Step Five

In the Create Render Node, 3D Textures section, click the Crater button.

Step Six

Open the Attribute Editor and change the Crater colors to Earth tones.

Step Seven

Click the lambert tab in the Attribute Editor and click the Bump Mapping checkerbox.

Step Eight

In the Create Render Node, 3D Textures section, click the Crater button.

Step Nine

Add a light to the scene by choosing Create > Lights > Directional Light (include options). Activate Cast Shadows in the options. Click Create to add your light.

Step Ten

Using the Move tool (w key), position your new directional light in the scene. Press the t key to activate the light's manipulator so you can quickly aim the light.

Step Eleven

Click the Render Current Frame icon to see your rendered texture.

Step Twelve

Select the sphere, then choose Window > Rendering Editors > Hypershade.

Step Thirteen

In the Hypershade panel, Materials section, shift-select the lambert2 shader. In other words, you now have selected both the object and it's texture.

Step Fourteen

Choose Edit > Convert File to Texture (Maya Software) (include options) from the Hypershade panel menu items.

Step Fifteen

In the options panel, choose Edit > Reset Settings. Activate Bake Shading Group Lighting and Bake Shadows.

Step Sixteen

Set the X Resolution and Y Resolution to 512 pixels. If you plan to edit the image in Photoshop, you can choose an image format other than the default file format. Click the Convert and Close button.

Step Seventeen

To see your new shader network, select the sphere and choose Graph > Graph Materials on Selected Objects in the Hypershade. The procedural Crater texture is no longer connected to your object.

Step Eighteen

Click the Render Current Frame icon to view your new texture.

Shadows, Shading and Baking

This works great if you have an object where the lighting doesn't change throughout the animation. However, in this example if we now rotate the sphere, it will reveal it's dark side.

Baking Transparency

Transparency is also an option for Step Fifteen.

 

Lynda.com career skills