I spent some time this weekend trying to get Maya to render it’s lighting to a texture. There are countless resources out there for baking Direct Lighting or Ambient Occlusion but if you are looking to get Final Gather into your texture, the information tapers quickly. I did find one way to make it happen, but it’s far from ideal. This technique is only useful if you plan to render a simple model with local lighting, like a small detail object or vignette. If you want to bake an entire scene this would get ugly…
Step 1: Populate the Final Gather Map
- Open your scene and make sure that it renders as intended in your render window.
- Go to Render Settings -> Render Using [ Mental Ray ]. Make sure you are using the correct renderer. This is likely the case if #1 is rendering properly.
- Now, in Render Settings -> Indirect Lighting -> Final Gather Map, set Rebuild to OFF.
- Just below that Rebuild option should be “Final Gather File”. Type in the name of a temp file that Mental Ray can use to store it’s cached samples. Any name will do as long as you have write access.
- I would also “Enable Map Visualizer” so you can see your sample points.
- Now render the scene from multiple angles. Each render of your scene will add more sample points. You can see these being populated if you enabled map visualization.
- Go back to “Rebuild” and change that value to FREEZE. This will lock the Final Gather samples that you’ve collected, using them in your texture bake.
Step 2: Bake
Any baking that you do here (and in your preview renders) will reference the frozen file that you pre-constructed.
I won’t get into the details of how to bake because there are plenty of in-depth video tutorials on this part. I only wanted to show that it is possible to use final gather in your light maps. This approach however is not suited for large environment light baking…