Deepen your understanding of After Effects by completing this tutorial, which covers topics such as incorporating pre-animated comps, keeping vector layers sharp in nested comps, animating text character-by-character using a script, and transitioning from the gold square to the logo reveal animation.
This exercise is excerpted from past After Effects training materials and is compatible with After Effects updates through 2020. To learn current skills in After Effects, check out our After Effects classes and video editing classes in NYC and live online.
Note: These materials are provided to give prospective students a sense of how we structure our class exercises and supplementary materials. During the course, you will get access to the accompanying class files, live instructor demonstrations, and hands-on instruction.
Topics covered in this After Effects tutorial:
Incorporating Pre-Animated Comps, Keeping Vector Layers in Nested Comps Sharp, Animating Text Character-by-Character using a Script, Transitioning from the Gold Square to the Logo Reveal Animation
Exercise Preview
Exercise Overview
The WaitingRoom logo is comprised of two solid color squares—one of which is gold—connected by a square outline with no fill. In this exercise, we’ll animate our gold square to move upward and reveal this logo (which has been pre-animated) and the rest of our final layout. We’ll also use a script to separate WaitingRoom’s URL into separate characters, so we can animate them to rise up into the composition one character at a time.
Previewing What You’ll Make in This Exercise
-
You should still have yourname-Text Animation.aep open in After Effects. If you closed it, re-open it now. We recommend you finish the previous exercises (2A–2C) before starting this one. If you haven’t finished them, do the following:
- Open Text Animation-Ready for URL Animation.aep (from the Text Animation > Finished AE Projects folder).
- Save the file as yourname-Text Animation.aep in the Text Animation folder.
On the Desktop, navigate to Class Files > After Effects Level 2 Class > Text Animation > Finished Clips and double–click Text-Animation-Waiting-Room-URL.mov.
-
Play the video and notice the following:
- The gold square from our last layout moves upward and to the left while it simultaneously shrinks down, in preparation for the next layout reveal.
- Once the square gets into position, it slides up to reveal a solid turquoise square. The squares move apart from each other with a bit of overshoot.
- The animated logo also contains an orange outline that draws on-screen, as well as two lines of moving text that get progressively revealed as they clear their respective static alpha mattes.
- As the outline and text appear, the WaitingRoom URL jumps on-screen from below the visible area. Each character animates separately in sequence.
Replay the video as many times as you need—we’ll be reproducing it in this exercise. Keep it open so you can refer back to it as needed.
Incorporating Pre-Animated Comps into a Larger Project
Switch to After Effects, where yourname-Text Animation.aep is open.
In the Timeline, switch to the Text Animation-MAIN tab if you aren’t already there.
Look in the Timeline’s layer stack. Our project is comprised of four layouts, but notice that we don’t have an 04-prefixed pre-comp yet. We created this pre-comp for you. Before we add it here, let’s check it out.
In the Project panel (you may need to close the Effect Controls panel), expand the Pre-comps folder if needed, then double–click on 04-Waiting Room to open our final layout in a new Timeline tab.
-
In the composition that opens, you’ll see that there are two layers waiting for us, a URL and a Logo FPO.
In the design process, you may sometimes see the acronym FPO. It stands for F or P osition (or P lacement) O nly. It’s the equivalent of placeholder text for images, so graphics marked as FPO are low resolution or appear incomplete in some other way. In a motion graphics context, the term is often used to describe static images that are temporarily standing in for an animated version of the same thing.
Sometimes a client or a collaborator will provide you with a pre-animated logo reveal or other type of branded footage that needs to be incorporated into a promotional piece. WaitingRoom provided us with a “standard end tag” to replace the FPO version of their logo. In the Project panel, click on the Assets folder so the project we’re about to import automatically goes into the appropriate folder.
Press Cmd–I (Mac) or Ctrl–I (Windows) to import a file.
Navigate into Class Files > After Effects Level 2 Class > Text Animation > AE Projects to Import, and double–click WR-Logo-Animated.aep to open it.
In the Project panel, expand into the WR-Logo-Animated.aep folder and double–click on the Waiting Room Logo comp to open it in a new Timeline tab.
-
Press Spacebar to preview from the beginning to see the logo is fully animated but it doesn’t start right away.
We need to place the logo into the composition for our fourth layout. But just in case WaitingRoom wants to modify this file later, let’s keep the Composition Settings as is (instead of changing the Start Timecode to match the start of the animation).
Even though we won’t crop the in point, we do need to figure out the timecode where we need to start animating the fourth layout. Click into the Timeline and select all layers.
Press the U key to see all the keyframes in this pre-animated composition.
Press J or K until you land on the first keyframe at 5;20.
At the top of the Timeline, close the Waiting Room Logo comp. You should be back in the 04-Waiting Room tab.
From the Project panel’s WR-Logo-Animated.aep folder, drag the Waiting Room Logo comp into the Timeline, dropping it above the other two layers.
If the playhead isn’t already at 5;20, move it there now.
We want to add a marker so we can remember where this composition’s animation starts. If any layers are selected, the marker will get created on that layer. We want to add it to the comp, so deselect all.
-
Go to Layer > MArkers > Add Marker.
Because we did not have any layers selected, we can see the marker on the right side of the Timeline in the gray strip above all the layer bars. Remember that it’s a handy visual reference that helps you navigate to an exact point in time.
Let’s label the marker to denote its purpose. Double–click on the marker .
In the Comment field that appears, type start anim and click OK.
At the top of the Timeline, click on the Text Animation-MAIN tab name.
From the Project panel’s Pre-comps folder, drag 04-Waiting Room into the left side of the Timeline, dropping it between the pie and [03-Leverage] layers. (It should become Layer 6.)
If the playhead isn’t at 5;20, Shift–drag the playhead so it snaps to the pre-comp’s marker at this timecode.
Trimming the pre-comp’s in point here in the master composition will only cut this layer. (The pre-comp itself with its multiple layers will remain intact.) That’s what we want! Press Opt–[ (Mac) or Alt–[ (Windows).
We want this logo to start animating at 12;26, so move the playhead there.
To move the layer so its in point is aligned with the playhead, press the [ key.
Keeping Vector Layers in Nested Comps Sharp
In the Timeline, double–click on the [04-Waiting Room] pre-comp layer to switch back to its Timeline tab.
Let’s scale up our animated logo so it is the same size as (and in the same position as) the static FPO version. Because seeing all the logo’s parts will help us scale it up as needed, select the [Waiting Room Logo] layer and press O to get to its out point.
With the layer still selected, press the S key to bring up its Scale.
Hover over the current Scale value of 100% until you see the hand slider . Drag rightward until the layer’s edges start getting pixelated. How odd…
-
Release the mouse and do an undo.
By default, After Effects treats a pre-composition like pixel-based footage. Even if a vector layer inside a pre-comp has its Continuously Rasterize switch on, that sharpness gets lost when you nest a pre-comp inside another comp.
Just like we do for single vector layers, we need to turn on a switch to sharpen the entire nested pre-comp with its vector layers. It’s actually the same Continuously Rasterize switch we’ve been using, except in the context of a pre-comp layer, it’s called Collapse Transformations. For more about this aspect of the switch, read Adobe’s help article at tinyurl.com/ae-collapse-trans
In the [Waiting Room Logo] layer, click the empty Collapse Transformations switch to make the pre-comp nice and sharp. (If you don’t see this option, click the Toggle Switches / Modes button at the bottom of the panel.)
-
Once more, hover over the 100% Scale value and drag the hand slider rightward until the animated logo roughly matches the size of the static Logo FPO.
The new Scale value should be around 253%.
When done, turn off the Logo FPO layer’s visibility by clicking its eye switch .
Animating the URL on a Per-Character Basis
Let’s animate the URL jumping into place letter-by-letter, with a bit of overshoot before settling. Rather than animating each and every piece separately, we’ll animate the text as a single unit. Then we’ll use a script to separate it out by character.
In order to use the script after we create the animation, we will need to make our URL layer’s text editable in After Effects. In the Timeline, Ctrl–click (Mac) or Right–click (Windows) on the URL layer and go to Create > Convert to Editable Text.
Move the playhead to 6;18, when we want the text to settle into its final position.
Select the URL layer if it isn’t already, then press P to reveal its Position.
Separate Dimensions, then deselect.
Keyframe the URL layer’s Y Position property by clicking the stopwatch .
Move the playhead to 6;14, where there will be a bit of overshoot.
Change Y Position to 911, and the entire text will move a bit higher.
We want the text to start moving at 6;02, so move the playhead there.
If the Selection tool is not already active, press the V key.
Press the Down Arrow key (adding Shift when needed) to move the entire text below the bottom of the composition frame. The Y Position should be around 1111.
Select the second keyframe (at 6;14) and press F9 to Easy Ease it.
-
Press the Spacebar to play the animation starting from the playhead’s position.
It looks good so far, but we want each character to come in sequentially, one at a time. Let’s first use a script to separate the text into its individual parts, then sequence each layer’s keyframes.
To pull up the script, go to Window > DecomposeText.jsx.
-
In the panel that appears, set the following options:
- In the menu next to Decompose into, keep Characters selected so the script will create a new layer for each character.
- To maintain the positioning of each character as it animates, keep the Original position using expressions option selected.
- Click the Decompose button to run the script with the options you chose.
NOTE: Expressions are written in Adobe’s ExtendScript language—the same JavaScript-based code as the scripts we’ve been using. This script uses expressions to maintain the text’s positioning, which would otherwise be imprecise.
Close the panel using the panel menu or the red button above the panel.
-
In the Timeline, notice that the script created one layer per character, with each layer named accordingly. To keep our stack nice and clean, select all and click one of the open arrows to swivel them closed.
NOTE: Just in case we would need it later, the script maintained our original URL text layer, with all its keyframes intact but with its visibility turned off. Thanks, DecomposeText!
Deselect all.
Click on Layer 2 (the first W layer) and Shift–click on Layer 20 (the last M layer).
Press the U key to see that the keyframes are still in the original timecodes.
Move the playhead to 6;02 if you aren’t already there.
So we can automatically stagger the appearance of each piece by a single frame, let’s temporarily shorten them to be one frame in duration. To crop the in points, press Opt–[ (Mac) or Alt–[ (Windows). Then do the same with the out points by pressing Opt–] (Mac) or Alt–] (Windows).
Go to Animation > Keyframe Assistant > Sequence Layers.
Make sure Overlap is NOT checked. Keep the default options and click OK.
With all the layers still selected, look in the Timeline. If you can’t see the topmost single-character layer (the first W that should be Layer 2), scroll up or down until you can.
Hover over the end of this W layer until you see a resize handle . Drag it all the way to the right so it reaches the end of the Timeline (along with the other layers).
Press B to set your Composition Work Area to start here.
Press the Spacebar to watch your work, starting at 6;02. That feels great!
Transitioning from the Gold Square to Reveal the Logo
We’re almost done! Our final task is to animate the transition from the third layout to the final one we’ve been working on. All we need to do is return to our master comp and move our gold square up and to the left while it scales down to its size in the pre-animated logo.
Go back to the Text Animation-MAIN tab.
-
Select the [03-Leverage] layer and make sure its Collapse Transformations switch is on.
NOTE: When working with a nested pre-composition with 3D layers, make sure to turn on the layer’s Collapse Transformations switch to ensure After Effects knows that 3D layers are inside. Otherwise they could get flattened!
With the layer selected, press the A key to pull up its Anchor Point property.
Press the Y key as a shortcut to get the Pan Behind (Anchor Point) tool .
So the values change in more precise increments, use the period (
.
) key to zoom into at least 200%.Click on the anchor point and then press Shift. While looking at the Timeline, drag it downward until the Anchor Point values are 960, 650.
Press Shift–P to see that the Position values are the same.
Click into the Composition panel’s zoom percentage menu and choose Fit.
Move the playhead to 12;10, when the gold square first appears.
Keyframe both the Position and Scale by pressing Opt–P and Opt–S (Mac) or Alt–Shift–P and Alt–Shift–S (Windows).
Move the playhead to 12;26.
-
In your own projects, you would scale and position by eye (with the Opacity of the [04-Waiting Room] layer at 50%) until you get the perfect values. We did the work for you, so just enter the following values:
- Change the Scale to 43.4% to shrink it down to the size of the logo’s square.
- Change the Position to 595, 541 so it overlaps with the logo’s square.
If You See Text That Was Formerly Off-Screen
The Collapse Transformations switch treats a pre-comp as having endless boundaries. When we shrunk down the gold square, some layers that were off-screen outside the comp bounds may have become visible once again. If this happened to you, you did not trim some layers properly. Do the following to fix it:
- Move the playhead to 12;08.
- Double–click on the [03-Leverage] layer to open this pre-comp in a new Timeline tab.
- Select the space layer and Shift–click on line 2 so we can trim their out points.
- While still at 12;08, press Opt–] (Mac) or Alt–] (Windows) so they are fully invisible in the next frame.
Press Cmd-Left Arrow (Mac) or Page Up to go back a frame to 12;25. Then press Opt–] (Mac) or Alt–] (Windows) to trim its out point here.
Hit the Home key or move your playhead to the start of your Timeline, and hit the B key to start the Work Area here.
Make sure the Work Area is the length of the comp.
Press Spacebar to preview the entire project from the very beginning. We’re done!
Do a File > Save and let’s get ready to render!
Rendering
Let’s export our video and save it for publishing! In the Timeline, make sure you are in the Text Animation-MAIN tab.
Go to Composition menu > Add to Render Queue.
In the Render Queue panel that appears at the bottom, next to Output To, click on the file name or Not yet specified.
Navigate to Class Files > After Effects Level 2 Class > Text Animation > Renders, name it Waiting-Room-Text-Animation.mov and click Save.
-
At the top right of the Render Queue panel, click the Queue in AME button.
This should launch Adobe Media Encoder.
Go to Window > Workspaces > Default Workspace
Then go to Window > Workspaces > Revert Workspace to reset to factory settings.
On the right you should see that Text Animation-MAIN has been added to your Queue.
Below the Format column, click the small arrow and choose H.264 if it isn’t already.
Below the Preset column, click the small arrow . If you created an Adobe Media Encoder preset earlier, click on your H264 preset now. If not, please continue with the steps below. If you did set a preset, you can skip to step 21!
In the Preset column, choose Match Source-High Bitrate from the menu.
Click the words Match Source-High Bitrate to customize these settings.
In the Export Settings window that opens up, a little further down, make sure you’re viewing the Video tab.
Click the Match Source button to make sure our export is the same dimensions as
our sequence settings.Scroll down in the Video section and check on Render at Maximum Depth so that our video exports at a high quality.
Below that, find the Bitrate Settings.
Set Bitrate Encoding to VBR, 2 pass. This refers to a Variable Bit Rate and number of encoding passes.
Further down in the Video section, under Advanced Settings, check on Key Frame Distance and set it to 30 to match it to our project’s frame rate.
At the bottom of the Export Settings window, check on Use Maximum Render Quality.
At the bottom of the window, click OK to exit out of the Export Settings.
Below the Output File column you’ll see the filename and location where it’s going to save your file should already be set to your Renders folder. If it isn’t already, click the blue filepath text, and set it to Class Files > After Effects Level 2 Class > Text Animation > Renders.
To start the rendering/exporting process, in the top right of the Queue window, click on the green Start Queue button .
When the progress bar below the Queue panel is completely blue, the rendering is complete! Once it’s done, you can click the blue filepath below the Output File column, to go to the folder where the file is located.
Open the Waiting-Room-Text-Animation.mp4 movie and watch your finished piece!