Baking Ambient Occlusion with 3ds Max & Mental Ray

This tutorial will take you through the process of baking ambient occlusion in 3ds Max using Mental Ray.

Ambient occlusion is a shading method used in 3D computer graphics which helps add realism to local reflection models by taking into account attenuation of light due to occlusion. Ambient Occlusion attempts to approximate the way light radiates in real life, especially off of what is normally considered non-reflective surfaces.

- Wikipedia Ambient Occlusion

To complete this mini tutorial you will need an unwrapped model, I used a jet plane I’ve been working on recently.

Firstly open your model that you should have unwrapped already, delete any lights in your scene and then insert a skylight into the scene.

Now it’s time to set your render settings so that you get a good quality result when you bake the Ambient Occlusion later. I’m going to use Mental Ray because I’ve had better results with it compared to the scanline renderer. So assign Mental Ray as your production renderer (render setup > common > assign renderer.) Since we’re using a skylight with Mental Ray we need to enable Final Gather (render setup > indirect illumination > final gather.) Tick the ‘enable final gather’ box and use the high precision preset. You could use the highest setting if your not happy with your results but it will take a lot longer! You can also increase the sampling quality under your renderer tab. I used a minimum of 1 and maximum of 16 samples per pixel.

Choose Mental Ray Final Gather settings

Assign a standard white material to your object in the material editor. Change the background colour in the environment settings to white and make sure the global tint is at 1.0 which is the default level.

White Material Environment Settings

Make sure the object is selected and now press 0 to bring up the Render to Texture window.  Under mapping coordinates make sure to select use existing channel. Scroll down to output and press add… then choose Ambient Occlusion (MR) from the available elements list. You’ll now have some more options available, so set your map size, I’ve used 512×512 and set your samples to 128, the higher the number the better the results.

Render To Texture Render To Texture 2

Once your happy with the settings press render and 3ds Max will render your Ambient Occlusion map. You can then use this directly in your game engine or you might want to mix it with your diffuse map in Photoshop. Put the AO map to the top layer and change the blending mode to ‘multiply’ and your done!

Ambient Occlusion Result Diffuse with AO baked in

It’s possible to improve on this method by using a bump map/normal map in the bump slot of the white material you created which will give you occlusion that fits with your bump map. You can also bake ambient occlusion from a high poly model to a low poly model but that’s beyond the scope of this tutorial – one for the future maybe!

Hope this tutorial was helpful!

Be Sociable, Share!

Related Posts:


About this entry