Get $500+ of the best After Effects files, video templates and music for only $20!
Understanding The Render Order In After Effects

Understanding The Render Order In After Effects

A few years after my first light saber, I learned how to track footage, then eventually I was able to put in a cheap animated 3D spider robot… I was getting to the place where I thought I knew the basics of After Effects pretty well. Then one day my professor at college told us briefly about render order in After Effects… I found this fascinating and wanted to know more. Today we’ll do some experimentation and go through After Effects’ render order!


What is the Render Order ?

It’s just the way After Effects proceeds from the source files to the rendered footage (in the RAM or in a file). In other words, it’s the order in which all the calculations are made by After Effects in processing your source files to get the rendered footage in your composition window, or in your exported file.

In order to fully understand this concept, remember that a video clip or a digital (rasterized or vector-based) picture, is just math. If you think that a pixel is a small square or rectangle with a unique color… you are wrong. Or should say, you’re not quite right. Before being graphically represented like this, pixels, vector-based pictures and video clips are numbers, the way all digital data is.

After Effects is software which is able to tweak, modify, and change those numbers in lots of different ways. All the processes are based on algorithms…. Effects are algorithms… the Camera Layer is based on algorithms… Motion Blur is even based on algorithms.

Okay, so everybody already knows that, but what I wanted emphasize here is that your final rendered video is the result of all the algorithms that you apply on your source footage which is calculated one after the other. After Effects doesn’t show you the intermediate states of the processes on your picture, it just displays the final result. And because After Effects is based on non-destructive editing, learning how After Effects works is a useful skill that can really help you improve your workflow.

hexadecimal representation

An hexadecimal representation, by Henkster on stock.xchng.

A Basic Comp, Step by Step

To get a better idea of the concept, we will take a simple experimental composition which we can see below, with layers, a Track Matte, two Pre-comps, Effects, an Adjustment layer, 3D layers, a Blending Mode, a Light and a Camera. In a composition, the layers are calculated from bottom to top and non visible layers are not calculated. Don’t forget that the composition has a default mono-color background which can be rendered if need be (but it can blend with the layers, using Blending modes). So, to understand the render order of a composition, we first need to understand the render order of a layer.

comp

Our beautiful test composition based on the AE CS5 logo.

The First Layer

Here, it’s is the AE CS5 logo in PNG format. It could be any kind of layer or source material. The first step for After Effects consists of decoding your picture :codec, pixels, fields, frame-rate etc…

ae cs5 logo

The AE CS5 logo.

Just after that, comes the Masks. Here is just a circular Mask around the “AE”. The Mask are rendered from top to bottom. So if you have two Masks, the second is relative to the first.

Then the Effects of our layer is calculated. Here we have a Bevel. As you can see, the Bevel is applied at the edge of our Mask. It shows that Effects comes after the Masks. If there were several Effects, they will be applied from top to bottom.

The Transform properties are applied right after the Effects. This way, the Scale, Opacity, Position etc… of the Effects are relative to the layer Transform properties.

Then, there is the Blending mode. Here it’s just the normal mode, because it’s the bottom layer. The other modes are useless in this position.

Now that our first layer is calculated, we can continue with the rest of our composition.

First Layer

The First Layer of our Comp.

The Rest of the Comp

Next comes the Track Matte. The Track Matte layer is calculated completely (Masks, Effects, Style) and then the Matte is applied to our first layer. Here, our Matte is a pre-composition, in which the letters of the logo are white. In fact, the Pre-composition is calculated first, before any layer of the composition. As you can see, the Bevel effect is not applied to the letters of the logo. That proves that the Effect of the bottom layer is calculated before the Track Matte. Note that a Track Matte cannot be applied on a 3D layer if that latter has a Layer Style (that’s why there is no Layer Style in our first layer). Note also that the Style Layer of a Track Matte does not take into account if that Track Matte is 3D. Anyways, using a 3D Track Matte on a 3D layers isn’t really a good thing, but this is just for the experimentation.

track matte

The Track Matte in Action.

Next in our composition appears the Light layer. The Light layer deals with the 3D layers, casting their shadows and illuminating them if they are in its beam. That means that the visual appearance of a 3D element changes after it was calculated in 2D. To avoid problems, be sure that your Track Matte, (if it’s in 3D) doesn’t accept lights and shadows.

Then, Camera layer. I don’t think it’s necessary to explain how it works here.

light Camera

The Light and the Camera.

Next in our composition comes our Adjustment layer which affects the layers under it (except Camera and Light layers) in a 2D way (it flattens the composition). Below I’ve applied the Glow and the Curve effects.

glow

The Adjustment Layer : a Curve and a Glow.

Next comes a simple Grey Solid with a colorful Gradient effect applied to it. Note that the Blending Mode is applied after all process done on the layer, except the Alpha layer.

gradient

The Blending mode of the layer come after the Effects.

Finally, the Motion Blur is applied, depending on the camera movement and the layers movement. Here, there is none.

Particular Cases

The Continuously Rasterized Vector Layers

For that kind of layer, the Transform properties are applied before the Effects. That means that the size of the Effects (as a glow, a blur, a fractal noise…) are not relative to the size of the layer. The trick is putting your layer at the right size, and then link the “size” (length, radius, or other properties like that) of your Effects to the scale of the layer.

Don’t forget that the Transform properties can be applied as an Effect, if needed. Just go to the Effects panel and write Transformation. This can be useful in some cases.

Also remember that the shadows of that kind of layer don’t take into account the Effects applied to that one.

vector layer

When the Scale grows up, the relative Scale of the Fractal noise stay the same.

Pre-composition

If you check the “Collapse Transformation” for a pre-comp, the Transform properties will be calculated before the Masks and Effects. It’s basically the same thing as the Continuously Rasterized Vector layer. But the point here is to collapse the Transform properties of the containing composition with the Transform properties of the layers in the Pre-composition, in order to keep the best quality. Be careful: if you put that Pre-composition in a 3D comp, all your layers (in the pre-comp) have to be in 3D (so, no Adjustment layer…).

preComp

The Continuously Rasterized button for a vector layer becomes the Collapse Transformations button for a Pre-composition.

The Shape Layers

With a Shape layer, the group at the bottom is calculated first, and the shape at the bottom of a group is calculated first. Then, the Path operations are calculated from top to bottom. And then, the Paint operations are calculated from bottom to top (they use Blending Modes, like the layers), but we can change that in selecting “Composite : Above Previous in Same Group.”

shape

The shapes at the bottom are calculated first.

Parent, Child, and Link between properties

If a value depends on the value of an other layer (for example, if one layer is child of an other, or if a value is linked to an other), the reference is calculated first.

Layer Styles

They are calculated from top to bottom after the layer Blending Mode, with their own blending mode. We could think that, because the Transform properties are calculated before, the Interior-glow will not rotate if I rotate the layer… But, the glow seems to rotate as if it was applied before. To see what really happens, just put the noise of your Interior glow at its maximum level, and rotate your layer. You can see that the noise doesn’t rotate. The layer styles are calculated after the Transform properties.

Note that the opacity of the Layer Styles is relative to the opacity of the Layer. Once again, the Transform properties are calculated before.

If you want that the Interior Styles use the Blending mode of the layer, you can select “yes” to the Blend Interior Style as Group in the Advanced Blending options. It doesn’t change the render order.

Layer Styles uses the Track Matte of the layer too. This one is calculated before the Layer Style.

alpha style

The style come after the Track Matte, so after the Transform properties.

Preserve Transparency

This is last process calculated by AE to render a layer.

preserve transparency

Preserve Transparency, last in the chain.

Conclusion

Deeply understand the After Effects’ render order is not such an easy process when we have a complex composition with a huge variety of layer types, styles, 3D, pre-comp and vector pictures.

This sums up the different render orders based on our experimentation in After Effects :

Rasterize Layer Render Order

  • Source
  • Masks (from top to bottom)
  • Effects (from top to bottom)
  • Transform
  • Track Matte
  • Blending Mode
  • Styles (from top to bottom, with their own Blending mode and Opacity relative to the Transform properties)
  • Preserve Transparency

Continuously Rasterize Vector Layer and Pre-composition Render Order

  • Source
  • Masks (from top to bottom)
  • Transform
  • Effects (from top to bottom)
  • Track Matte
  • Blending Mode
  • Styles (from top to bottom, with their own Blending mode and Opacity relative to the Transform properties)
  • Preserve Transparency

Shape layer Render order

  • Groups (from bottom to top)
  • Inside a group : Paths (from bottom to top) and Paths Operations (top to bottom)
  • Inside a group : Paint (default : from bottom to top; depending on the Composite parameter)
  • Inside a group : Transform properties
  • Transform properties of the Layer
  • Effects (from top to bottom)
  • Track Matte
  • Blending Mode
  • Styles (from top to bottom, with their own Blending mode and Opacity relative to the Transform properties)
  • Preserve Transparency

Composition Render Order

  • Background color (if needed)
  • Pre-composition
  • Other Layers (from bottom to top)
  • Lights
  • Cameras
  • Motion Blur
  • Audio

For more technical details, you can go the Adobe Help online and see these articles below. I suggest that you test all the information issued in this tutorial or the Adobe Help to really understand how it works.

I hope you enjoy that article. Feel free to use my After Effects project for your own experimentation. :)

Add Comment

Discussion 10 Comments

  1. b.b says:

    Question: Pre-Comping works a bit like Smart Objects in Ps, right?

    I’ve been thinking of this theory a long time, since i’ve come from Ps and i’m trying to learn AE.

    calling me beginner/noob is fully accepted :D

    -B

  2. Todd Kopriva says:

    Here’s a video tutorial that I recorded that shows the render order and the practical results:
    http://bit.ly/i3ERhQ

    Also, in answer to b.b.’s question: Yes, precomposing in After Effects is somewhat similar to using a smart object in Photoshop.

  3. Todd Kopriva says:

    By the way, I applaud Raymond’s (the author’s) work in getting all of this information together.

  4. ExtremRaym says:

    Thanks a lot Todd, i am really honored by your comment :)
    By the way, very nice video, the Drop Shadow effect shows was a good idea.

    I found later that we can visualize the render order of a composition in switching to the Composition Flowchart.

    It’s all i wanted to add :)

    b.b : you already have the answer :P

  5. Thanks a lot Todd, i am really honored by your comment :) By the way, very nice video, the Drop Shadow effect shows was a good idea. I found later that we can visualize the render order of a composition in switching to the Composition Flowchart. It’s all i wanted to add :) b.b : you already have the answer :P

  6. Alptonay says:

    Hey Raymond, thank you very much for this article.. Now I realized why layer order or effects order causes changes.. I have discovered this by myself but couldn’t understand the logic.. So now it’s lighten up :) Thank you again…

  7. RTKLLR says:

    From what i learned, non-visible layers are calculated anyway. Only if you solo needed layers, non-solo and thus non-visible layers won’t be calculated.

    The situation was – i had some layers i didn’t need for the final render, they contained Drop shadow effect and were slowing things down. I turned off their visibility and there was no change. Only after I deleted the layers(or effects), render speeded up. Even in render details I could see that all those drop shadows are calculated.

  8. ExtremRaym says:
    Author

    Hi !
    I’m not totally agree with what you said =/
    I didn’t have the same result as you got.
    I tried to put 50 HD h.234 footages in my comp, and the render of the first frame was very long (1 minutes), and when i set to non-visible all the layers except one, the render is very fast, same speed as solo.

    But i apologize : it’s true that non-visible layers are calculated, but not their visual information.
    I have to admit that non-visible layers can be calculated anyway. The perfect example is Track Matte : non-visible, but calculated.
    But we cant’ generalize. I tried to put an Adjustment Layer between two 3D layers : if the Adjustment Layer is set to non-visible, the other layers can intersect each other, as if there was no Adjustment layer…
    As it’s said in the Adobe Help “Soloing excludes all other layers of the same type from being rendered”…

    You can go here for more information : http://help.adobe.com/en_US/aftereffects/cs/using/WSD322660F-F833-4e4c-A4CA-12B522F79415a.html

Add a Comment

To add a code snippet to your comment, please wrap your code like so: <pre name="code" class="html">YOUR CODE</pre>. You can replace the class name with "js," "css," "sql," or "php." If there are any "<" or ">" within your code, please search and replace them with: &lt; and &gt; respectively.