baking ambient occlusion(transfer map method)

11
SEARCH: LOGIN: Game Artist Forums > Main > Spotlight Articles Tutorial: Ambient Occlusion in Maya - by Alchemist101 Register FAQ Forum Rules Members List Calendar Page 1 of 5 1 2 3 > Last » LinkBack (27) Thread Tools Display Modes 01-02-2007, 05:09 PM #1 (permalink) benclark Industry Artist 2,319 - 362 Tutorial: Ambient Occlusion in Maya - by Alchemist101 AMBIENT OCCLUSION IN MAYA8 and PHOTOSHOP This tutorial covers the basics of how to setup and bake ambient occlusion maps in Maya8. The process is similar for previous versions of Maya only the menu names will be different. As with most things in Maya there are probably many different ways to do this but this method works well for me and is reasonably quick to setup. 1. SETTING UP THE SHADER NETWORK - First open the hypershade window and from the Maya nodes list MMB drag a Surface Shader node into the work area Tutorial: Ambient Occlusion in Maya - by Alchemist101 - Game Artist ... http://www.game-artist.net/forums/spotlight-articles/1317-tutorial-ambi... 1 of 11 2010/01/10 08:23 PM

Upload: angelbladecobus

Post on 04-Apr-2015

365 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: Baking Ambient Occlusion(Transfer Map Method)

SEARCH: LOGIN:

Game Artist Forums > Main > Spotlight Articles

Tutorial: Ambient Occlusion in Maya - by Alchemist101

Register FAQ Forum Rules Members List Calendar

Page 1 of 5 1 2 3 > Last »

LinkBack (27) Thread Tools Display Modes

01-02-2007, 05:09 PM #1 (permalink)

benclarkIndustry Artist

2,319 - 362

Tutorial: Ambient Occlusion in Maya - by Alchemist101

AMBIENT OCCLUSION IN MAYA8 andPHOTOSHOP

This tutorial covers the basics of how to setup and bake ambient occlusion maps in Maya8. The process is similar forprevious versions of Maya only the menu names will be different.

As with most things in Maya there are probably many different ways to do this but this method works well for me and isreasonably quick to setup.

1. SETTING UP THE SHADER NETWORK

- First open the hypershade window and from the Maya nodes list MMB drag a Surface Shader node into the work area

Tutorial: Ambient Occlusion in Maya - by Alchemist101 - Game Artist ... http://www.game-artist.net/forums/spotlight-articles/1317-tutorial-ambi...

1 of 11 2010/01/10 08:23 PM

Page 2: Baking Ambient Occlusion(Transfer Map Method)

- Now click on the "Create Maya Nodes" button at the top of the nodes list and change it to MentalRay nodes.

- Then under the textures tab MMB drag an 'mib_amb_occlusion' node onto the work area

- Now connect the 'OutValue' of the Occlusion node to the 'OutColor' of the surface shader. This is the defaultconnection between these 2 nodes so you can do this by simply holding down Ctrl and MMB dragging the occlusionnode over the shader node.

2. SETTING UP YOUR SCENE

- In order to get good results from Ambient Occlusion the scene environment must be white. To do this open theOutliner window and select the Persp camera. In the attribute editor under the Environment tab slide the BackgroundColor to 100% white

Tutorial: Ambient Occlusion in Maya - by Alchemist101 - Game Artist ... http://www.game-artist.net/forums/spotlight-articles/1317-tutorial-ambi...

2 of 11 2010/01/10 08:23 PM

Page 3: Baking Ambient Occlusion(Transfer Map Method)

- Now open the Render Globals window and select MentalRay as your renderer and Production as the quality preset.Now change the multi-pixel filter to "Lanczos".(this will automatically change your Quality preset to 'Custom' like in the picture)

- Now close the render Globals window and assign the 'Surface Shader' you have setup to your model. It should turnthe model completely black.

[/size]

3. TWEAKING

- Frame your model and hit render. It should render quickly and look quite grainy and crap at this stage, like this....

Tutorial: Ambient Occlusion in Maya - by Alchemist101 - Game Artist ... http://www.game-artist.net/forums/spotlight-articles/1317-tutorial-ambi...

3 of 11 2010/01/10 08:23 PM

Page 4: Baking Ambient Occlusion(Transfer Map Method)

- Now we need to tweak the settings a little. Open the attribute editor and then in the Hypershade window click on theAmbient Occlusion node. The Occlusion node's attributes will now appear in the attribute editor. These are the settingsI use for most objects...

- The first setting to change is 'Samples'. Increasing this will remove the grainy look but will drastically increase rendertimes. 256 samples is good for most objects.

- Do not change the 'Bright' and 'Dark' settings. These affect how light/dark the occlusion value is, but it is a lot betterto render with the default extremes and tweak them in Photoshop at a later stage if you need to.

- The spread setting affects how far the occlusion shadow spreads over the surface. Again the default setting of 0.800 isgood for most objects, any lower tends to be too extreme, and a high spread can cause darkening problems when it ismultiplied over your colour layers in Photoshop.

This image has been resized. Click this bar to view the full image. The original image is sized 800x279.

4. BAKING TO TEXTURE

Tutorial: Ambient Occlusion in Maya - by Alchemist101 - Game Artist ... http://www.game-artist.net/forums/spotlight-articles/1317-tutorial-ambi...

4 of 11 2010/01/10 08:23 PM

Page 5: Baking Ambient Occlusion(Transfer Map Method)

Once you have the occlusion looking good in a render, the next stage is to bake it to a texture.

- First make sure you have specified a project folder. To do this select File> Project > Set, and select a file. This file iswhere your baked texture will automatically be saved. If you forget to set a project folder the bake will be saved in yourdefault projects file in your My Documents folder.

- Make sure that you have UV mapped your model.- Make sure you check the face normals of your model are facing the right way or the bake will produce a black picture- Make sure you have softened the edges of your model and created hard edges where needed- Save a copy of your scene at this stage as Maya can crash while baking to texture- Now choose the rendering menu set and select Lighting/Shading > Batch Bake (Mental Ray) > Options boxThese are settings that I use and have never had to change them, so they should work for most objects.....

- Select your object in the viewport and hit the 'Convert and Close' button to start baking the occlusion. When you dothis Maya will not respond to any clicking, sometimes the screen will go blank and it generally looks like it has crashedbut don't worry it will come back eventually. This can take anywhere from a few minutes to a few hours depending onhow complex the scene is.

5. USING YOUR BAKED OCCLUSION MAP

- Once the bake is completed open the project file that you specified earlier.

- In that folder select RenderData > MentalRay > Lightmap > select your baked texture file and open this withPhotoshop.

Tutorial: Ambient Occlusion in Maya - by Alchemist101 - Game Artist ... http://www.game-artist.net/forums/spotlight-articles/1317-tutorial-ambi...

5 of 11 2010/01/10 08:23 PM

Page 6: Baking Ambient Occlusion(Transfer Map Method)

- Drag the Occlusion bake on top of your model's texture layer(s) and select Multiply as the layer blending mode. Youmay also want to apply a slight Gaussian blur to your occlusion layer, especially if it being used on an organic surface.For hard sharp edged surfaces like this one no blur was applied.

This picture shows the object and a basic 3-light setup with and without occlusion in the texture.The effect of the AO map is to fake GI lighting in real time.

This image has been resized. Click this bar to view the full image. The original image is sized 713x387.

6. BAKING OCCLUSION FROM HIGH RES TO LOWRES MODELS

Ambient occlusion maps can also be used to compliment normal maps. The occlusion values from a high poly modelcan be baked to the UV layout of a low poly model. This helps to sell the normal mapped details if used in a subtle way.

This function is found in the transfer maps window under lighting/shading in the Render menu set.

Tutorial: Ambient Occlusion in Maya - by Alchemist101 - Game Artist ... http://www.game-artist.net/forums/spotlight-articles/1317-tutorial-ambi...

6 of 11 2010/01/10 08:23 PM

Page 7: Baking Ambient Occlusion(Transfer Map Method)

As an example I will use this alien head model with normal map already extracted......

This image has been resized. Click this bar to view the full image. The original image is sized 720x440.

Now we will bake an ambient occlusion map to compliment the normal map...

In the Transfer Maps window....

1. Select your low poly mesh in the viewport and click add selected to load your target mesh

2. Do the same for your high poly mesh

3. Click the "Ambient" box

4. Use the settings shown (remember to specify a folder to save the map into)

Tutorial: Ambient Occlusion in Maya - by Alchemist101 - Game Artist ... http://www.game-artist.net/forums/spotlight-articles/1317-tutorial-ambi...

7 of 11 2010/01/10 08:23 PM

Page 8: Baking Ambient Occlusion(Transfer Map Method)

The resulting Occlusion map looks like this....

Tutorial: Ambient Occlusion in Maya - by Alchemist101 - Game Artist ... http://www.game-artist.net/forums/spotlight-articles/1317-tutorial-ambi...

8 of 11 2010/01/10 08:23 PM

Page 9: Baking Ambient Occlusion(Transfer Map Method)

Baking occlusion larger than 512x512 using this method can take forever so be prepared to wait a while

This map can then be taken into Photoshop and multiplied over the model's texture in the same way as before....

This image has been resized. Click this bar to view the full image. The original image is sized 799x470.

__________________www.benjaminclark.netMy Sketchbook

The Following 25 UsersSay Thank You to benclarkFor This Useful Post:

ahriman, chinese_lover, CopticMike, Daltons, DigitalPutty, Dubbler, IchII3D, Jessart, jidus, JMChristopher, Kathar,koogorah, llpsweetie, maxxart, MrTwister, requiem2d, SebastianK, ShoT, Taehoon, Talon, Thonz, tkaza, Vamediah,yoyomon, ZASkaggs

02-02-2007, 10:52 AM #2 (permalink)

ThonzSenior Member

234 - 13

Wow, verry nice tutorial.I'm a max user, but it helped me understand AO a lot better.Thanks!

02-02-2007, 04:27 PM #3 (permalink)

CopticMikeSenior Member

151 - 6

AAAHHHH THank you SOOO MUCH!!! Im a maya user, and you really helped me out, now the occulsion mystery, hasbeen demystified! Thank you again__________________To make your dreams come true, You MUST first wake up.

02-02-2007, 07:05 PM #4 (permalink)

st0lveAmateur Artist

85 - 1

To me, this looks kinda like a lighting map from 3ds max's render to texture feature, if you use a skylight that is.Is there any difference? :O__________________Lasse Pedersen | st0lve.net~ |Insurgency 2D\3D artist

03-02-2007, 12:07 PM #5 (permalink)

Tutorial: Ambient Occlusion in Maya - by Alchemist101 - Game Artist ... http://www.game-artist.net/forums/spotlight-articles/1317-tutorial-ambi...

9 of 11 2010/01/10 08:23 PM

Page 10: Baking Ambient Occlusion(Transfer Map Method)

|Buddy|Frequenter

132 - 9

More like MR render AO in RTT but yeah You're right.__________________She says the jungle... it just came alive and took him.

www.buddypowered.com

04-02-2007, 09:19 AM #6 (permalink)

SpaceRabbitNew Member

3 - 0

Dumb question, but does your hi-res model require UV mapping, or just the low res. I was reading the documentationfor this in Maya 7 and they kept stressing that both models had to have cleam UV mapping which seems like such awaste of time to have to UV both your hi-res and low res.

Thanks for the info, and great tutorial!

04-02-2007, 02:54 PM #7 (permalink)

benclarkIndustry Artist

2,319 - 362

Thanks for the feedback guys, SpaceRabbit - nope you dont have to lay out the UVs on the high poly model

04-02-2007, 08:20 PM #8 (permalink)

SpaceRabbitNew Member

3 - 0

Snap, thats what I wanted to hear! Thanks Alchemist!

05-02-2007, 07:36 AM #9 (permalink)

ghibNew Member

3 - 0

Anyone have any ideas whether it's possible to bake an AO map from a normal or displacement map rather than usinga hi-res mesh. Current version of Illuminate Labs Turtle is able to do this as it bakes maps at rendertime. Would behandy to do this instead of importing massive polycount objects into maya.

05-02-2007, 07:59 AM #10 (permalink)

NysuatroAmateur Artist

467 - 31

So people use a ambiant occlusion for having shadows in there texture?

Page 1 of 5 1 2 3 > Last »

Bookmarks

Digg del.icio.us StumbleUpon Google

LinkBacks (?)LinkBack to this Thread: http://www.game-artist.net/forums/spotlight-articles/1317-tutorial-ambient-occlusion-maya-alchemist101.html

Posted By For Type Date

Ambient Occlusion For Maya Users :) - DVXuser.com -- The online community for filmmaking This thread Refback 07-05-2008 01:24 PM

Gamestepper Forums • View topic - How to Bake Ambient Occlusion in Maya 8.5 This thread Refback 21-04-2008 05:16 PM

occulusion map - cgTantra Forums This thread Refback 24-03-2008 06:11 AM

Tutorial: Ambient Occlusion in Maya - by Alchemist101 - Game Artist ... http://www.game-artist.net/forums/spotlight-articles/1317-tutorial-ambi...

10 of 11 2010/01/10 08:23 PM

Page 11: Baking Ambient Occlusion(Transfer Map Method)

LinkBacks (?)LinkBack to this Thread: http://www.game-artist.net/forums/spotlight-articles/1317-tutorial-ambient-occlusion-maya-alchemist101.html

Video Game Artist and Fan Community: Polycount: Maya AO maps This thread Refback 21-03-2008 11:18 PM

Gamestepper Forums • View topic - How to Bake Ambient Occlusion in Maya 8.5 This thread Refback 17-03-2008 09:29 PM

Problema de normales en un Batch Bake - CG-Node This thread Refback 17-03-2008 02:09 PM

Gamestepper Forums • View topic - How to Bake Ambient Occlusion in Maya 8.5 This thread Refback 17-03-2008 11:24 AM

2007 Brabus CL600 - Page 8 - CGCars This thread Refback 10-03-2008 04:37 PM

2007 Brabus CL600 - Page 8 - CGCars This thread Refback 10-03-2008 04:12 PM

2007 Brabus CL600 - Page 8 - CGCars This thread Refback 10-03-2008 04:12 PM

Gamestepper Forums • View topic - How to Bake Ambient Occlusion in Maya 8.5 This thread Refback 05-03-2008 06:07 PM

Video Game Artist and Fan Community: Polycount: Maya AO maps This thread Refback 04-03-2008 06:29 PM

CG-Links :: Maya :: Baking an Ambient Occlusion This thread Refback 02-03-2008 05:34 PM

Tutorial: Showcase your work with Clay Render - 3D Buzz This thread Refback 28-02-2008 08:15 PM

Team Bigun WIP Thread - Page 7 - Threedy Forums This thread Refback 17-02-2008 06:47 PM

Gamestepper Forums • View topic - How to Bake Ambient Occlusion in Maya 8.5 This thread Refback 16-02-2008 09:06 PM

CGTalk - Ambient occlusion dome lighting This thread Refback 15-01-2008 03:31 PM

Ambient Occlusion For Maya Users :) - DVXuser.com -- The online community for filmmaking This thread Refback 14-01-2008 02:25 AM

Ambient Occlusion For Maya Users :) - DVXuser.com -- The online community for filmmaking This thread Refback 05-01-2008 01:20 AM

Art-conventions - Dawn of Bugs This thread Refback 10-12-2007 02:03 PM

Ben Clark - Game Art This thread Refback 02-12-2007 02:37 PM

Tutorial: Showcase your work with Clay Render - 3D Buzz This thread Refback 25-11-2007 05:31 AM

Video Game Artist and Fan Community: Polycount: Maya AO maps This thread Refback 20-11-2007 07:31 AM

Video Game Artist and Fan Community: Polycount: Maya AO maps This thread Refback 30-10-2007 11:20 AM

Video Game Artist and Fan Community: Polycount: Maya AO maps This thread Refback 17-10-2007 04:51 AM

Video Game Artist and Fan Community: Polycount: Maya AO maps This thread Refback 12-10-2007 05:27 PM

Video Game Artist and Fan Community: Polycount: Maya AO maps This thread Refback 29-09-2007 10:00 PM

All times are GMT -5. The time now is 01:29 PM.

Contact Us - Game-Artist.net - Privacy Statement - Top

Powered by vBulletin® Version 3.7.0 Beta 4Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.

Content Relevant URLs by vBSEO 3.1.0Copyright © 2006-2008 Game-Artist.Net

Tutorial: Ambient Occlusion in Maya - by Alchemist101 - Game Artist ... http://www.game-artist.net/forums/spotlight-articles/1317-tutorial-ambi...

11 of 11 2010/01/10 08:23 PM