Project 6f: Compositing

Goal We are going to learn how to render and composite different layers of our fire!

Phase III: Compositing

A large part of creating successful effects is understanding the power and importance of setting your Maya file up in render layers so you can take advantage of layered compositing tricks in a post production program such as After Effects. In this phase we will prep your scene for layered rendering on the farm and finally import your renders into AfterEffects for final compositing and rendering.

  1. First, let's take a moment to clean up your Outliner again. Group your Flame container, log, and logFlame_emitter into a group named "fire". You might have noticed that the log appeared very dark in a previous render. Create and name a light on the log so that it can show up in the render. Place the light in a group called "lights". When preparing for final render it is often useful (especially for effects) to set up render layers in your scene. Open the Channel Box/Layer Editor. At the bottom of the panel are 3 tabs: Display, Render, and Anim. Click the render tab. If the Render tab is not there, refer to the top of Project 6e.

    The masterLayer contains all the elements of your scene. This is what renders by default. We want to split our scene up into 3 layers: A sparks layer, a log layer, and a fire layer.

  2. To begin, click the sparkFX group and your log in your outliner. With these, look at your render layers panel, click Layers → Create Layer from Selected. This will create a new render layer for our sparks. Name this render layer by double clicking on the name and type in sparks_RL. Next select everything under your fire group. (Layers → Create Layer from Selected) rename the layer to fire_RL. Now create a render layer just for your log and its light, and name it log_RL.

    Click through your newly created render layers and make sure that the correct objects are indeed on their proper render layer. Make sure your render layers are enabled (leftmost button is depressed and black). Your Master Layer should be disabled (leftmost button is unpressed and grey). Your render layer panel should look like the image below.

  3. You may have noticed that the log is in all of the render layers.  This is on purpose.  We want to make the log block out objects that are behind it without being visible in the final render.

    To do this we apply a "black hole" shader.  Right click on the log while you have the fire_RL selected and go to Assign New Material….  Select surface shader from the menu and press ok.  In the material attributes, set the Out Color and Out Matte Opacity to black and rename the shader black_hole.  Now assign the same material to the log while you have the sparks_RL selected.

  4. Time to Render! Double check your render settings: naming convention, quality settings, frame padding, file format, etc. Open the render settings and set the following:
    • Render Using: Arnold Renderer
    • File name prefix: shot_100
    • Image Format: tif
    • Frame/Animation ext: name_#.ext
    • Frame padding: 4
    • Start frame: 1
    • End frame: 120
    • Renderable Camera: render_cam (You will have to set this up.)
    • Width: 640
    • Height: 360

    You will also want to set up a project as the target location for your renders:

    1. Go to File → Set Project
    2. Navigate to:
      //csenetid/cs/unix/projects/instr/capstone2/cse458_au18_student_files/[student_folder]/project_6
    3. Click "Select Folder" and allow Maya to make a default workspace.

    Once you have all of your render settings set up, you will be batch rendering each of your new layers. You do NOT need to render your master layer nor do you need to render more than one frame of the log. Go to the Rendering menu on the top left. Then go to Render → Batch Render. . In the bottom right of the Maya interface (where it tells you when you have errors), Maya will tell you what percentage of a current frame it has rendered. If you click to the right of this box, you will find the Script Editor. You can watch the Script Editor for any errors too. It will tell you which frame it's rendering, as well as the percentage.

    Once your render has begun you should be able to see folders created in your project directory, usually under images. These folders will have the same name as your render layers.

    Time to grab some coffee, bubble tea, or another drink of your choice, and wait for your renders to finish!

  5. Once your render is complete the next step is to import the resulting image sequences into After Effects CS6 for compositing. Remember to name your sequences so you know what you are working with!

    Click and drag one image sequence down to the "Create a new composition" button. Add in the remaining sequences, create a black solid (by going to Layer > New > Solid... and picking black from the color selection), and Layer your composition like the image below.

    You will also need to select your "fire" and "sparks" layer (really make sure to rename them! Always rename your image sequences, you will thank yourself for this later) and with those layers, right click on them, and go to Blending Mode > Add. This will blend out the black-holed log. You may see that your sparks are very faint at this point: feel free to go back in to your Maya file and tweak your settings to make them more visible, by changing color, size, or glow. If you re-render your sparks with the same settings, the new renders should overwrite your old ones, and you can right click your image sequence in After Effects and hit "Reload Footage" to see the new sparks.

  6. Change your composition settings to match your render settings.  The settings are located in Composition → Composition Settings.  Your settings should match those in the image below.

  7. In the project section of your AfterEffects project, right click on the fire images and go to Interpret Footage → Main.  In the dialog box set Alpha to Ignore and Frame Rate to 24 Frames per Second.  Repeat this step for the sparks images.

  8. In the composition section, right click on the fire images and go to Blending Mode → Screen. Repeat for the sparks images.
  9. At this point you can (if you want) start some final spit and polish such as color correction, added effects, layer blending etc. You can render out your composition by selecting it and going to File > Export > Add to Render Queue, and setting your output location by clicking on the 'Not yet specified' link next to Output To:. Click the render button in the top right of the Render Queue panel, and wait for your composition to render out!

    Save your final "render layer ready" Maya file ([lastname]_[firstname]_effects_p3.ma), your AfterEffects file, and a .avi of your final fire animation.

Turn In You will be graded on the following: Turn the following into Collect-It on Catalyst: