Render Passes and Mental Ray
Maya 2012 Tutorial
How to Render Shadow, Specular and Reflection Separately with Maya Mental Ray Render Passes
The Render Passes feature described in this topic only works with Mental Ray. It is helpful if you want to separate your image into a series of layers that will be reassembled in a compositing program such as After Effects.
Using this process the image shadows, reflections, specular and diffuse color are rendered as separate images.
Add a sphere and a plane to the scene by choosing Create > Polygon Primitives > Sphere and Create > Polygon Primitives > Plane.
Scale and move the objects in the scene with the Scale tool (r key) and Move tool (w key). The sphere should be floating above the plane.
Add a spot light to the scene (Create > Lights > Spot Light) and position the light so it illuminates the sphere. To access the light's manipulator, press the t key.
Turn on shadows by selecting the light and opening the Attribute Editor. Open the Mental Ray section, then the Shadows section. Select the Use Mental Ray Shadow Map Overrides check box.
Open the Render Settings and select Mental Ray for the Render Using choice.
Right-click each of the objects one at a time and assign each object a Blinn texture.
Open the Blinn shader for each object in the Attribute Editor and change the object's color.
Render your image by clicking the Render Current Frame icon. At this point it should have a specular highlight, shadow and reflection.
Open the Channel Box and click the Render tab in the lower section of the panel.
Right-click the Master layer name and choose Add New Render Pass > Diffuse Without Shadows.
Repeat Step Ten three times and choose Reflection, Shadow, then Specular.
Make sure you have created a project and set your project. For more information, see topic, Starting a Project. Your scene should be saved in the project's scenes folder.
Create your render passes by choosing Render > Batch Render from the Rendering menu set.
Your new images can now be found in the project's images folder. Each image is located inside it's own folder. The folders are named diffuseNoShadow, MasterBeauty, reflection, shadow and specular. By default the images are saved as iff files. For images headed to Photoshop you may want to specify tif or targa for your image file format.
The Power of Working in Layers
This workflow gives you incredible control as you create your animations. By breaking your animation into a series of layers it is very efficient to tweak a layer in After Effects instead of going back and re-rendering the entire scene.
Don't Like those Folders?
The folders created in Step 14 may not be the smartest way to work. If you prefer to ditch the folders and have images with a name that is more descriptive, try this trick. In the Render Settings, Common tab, enter the following text in the File Name Prefix Box: <Scene>_<RenderLayer>_<RenderPass>
Now the name is created using the scene name, render layer name and render pass name.
Viewing Passes Connected to Your Project
To see which passes are connected to your project, open the Render Settings panel and click the Passes tab. All the passes are listed in the Associated Passes section.
Can't Find Mental Ray?
If Mental Ray doesn't appear in the Render Settings, Render Using: menu, choose Window > Settings/Preferences > Plug-in Manager. Make sure Mayatomr.bundle is loaded.