Easy-to-follow video tutorials help you learn software, creative, and business skills.Become a member

Precomposing to create groups

From: 2D Character Animation with After Effects

Video: Precomposing to create groups

Okay, I have created this little animation of a guy hammering a nail in After Effects, and what I want to do now is start to animate his other body parts. If we have a look at the timeline, and I'm just going to do that by hitting the tilde key or the accent key. Which on the British keyboard is next to the zed key on the keyboard. And I believe on the American keyboard it's next to the number one key at the top of the keyboard. Now we're going to open up our timeline and you'll see that we've got lots and lots and lots and lots of layers. We've got different layers for each of the body parts. So if I just close up the right arm there, and we hit the tilda key again or the accent key to come back out of it.

Precomposing to create groups

Okay, I have created this little animation of a guy hammering a nail in After Effects, and what I want to do now is start to animate his other body parts. If we have a look at the timeline, and I'm just going to do that by hitting the tilde key or the accent key. Which on the British keyboard is next to the zed key on the keyboard. And I believe on the American keyboard it's next to the number one key at the top of the keyboard. Now we're going to open up our timeline and you'll see that we've got lots and lots and lots and lots of layers. We've got different layers for each of the body parts. So if I just close up the right arm there, and we hit the tilda key again or the accent key to come back out of it.

If I solo the layers you can see that each layer represents different body parts, we've go the hair, the eyebrows, the mouth, the eyes, the head. All on separate layers. Now if we were to animate them all in this composition, we're going to be kind of finding it a little bit tough moving up and down and having to figure out which layers which. Not only that, if I move the head layer, for example. And I just decide to use the arrow keys on the keyboard to move the head.

Notice the head moves without all the other features, which is not really what I want. I want the features to move with the head. So there's a couple of ways of attaching layers together in After Effects, and we're going to have a look at them, one of them, now, which is pre-composing. Pre-composing is a process of being able to select layers, and nest them into separate compositions. But still retaining their position within this composition. and I'll show you how that works, so for example.

If we're to start with the arm layer. We can solo the layers just to check which ones which. So let's solo that layer so that's his left arm. We want his right arm so we want the upper arm layer and the other layer that we want is at the top, which is the right arm layer. So if we want these both in this composition called arm, that contains the upper arm and the lower arm so it can then rotate these as a group, what we do is select them, so we'll select the upper arm, move up to the top, hold down the command key or control key on PC, to select non-contiguous items, and click on the right arm layer.

Now, with both of those selected, I can go to the layer menu, and choose pre-compose down at the bottom. Now you're going to want to learn the keyboard shortcut for pre-composing, because it's something that you do a lot in After Effects. And as you can see, it's way down at the bottom of the layer menu, so it's a hassle to go there with there with your mouse. Then you can just type in Shift, Command, C, or Shift, Control, C on the PC. And when you do that, it will open up the precomposed dialog box. And we'll give it a name. So we're going to call it arm comp.

Now we want to say which arm it is, and if it's the way that I do this is if it's on the right side of composition I call it the right arm. So we'll call it the right arm comp, and I'm going to click okay, and you'll notice that we've now got a comp called right arm comp, and it soloed if I switch on all the other layers by clicking off the solo button, you can see it integrated with the other layers. But now, I have a single layer which has transform properties that I can move, rotate And do whatever I want to with as a group. OK, so I can start to treat this arm as a group, which makes it a little bit easier to control.

So I'm going to go ahead and do that with some other layers. So I'm going to select all the layers that I would want to be in the head. So, we have the ears, the glasses, which are the spectacles, the hair, the eyebrows, the mouth, the pupils, the eyes, the head itself, and let's take well, we'll leave the neck, actually. We'll leave the neck where they are. And this time, we're going to go to layer precompose again just so you can see where it is. But remember shift command c, or shift control c on the PC precompose, and we'll call this head comp.

This time, I'm going to say open new composition, and when I click okay, it's going to open my new head comp composition with all of my head layers in it. Now if I want to jump back to the main composition, I'm not sure which one it was, I can click on this little composition mini flow chart button and I can see that my parent composition if you like, the composition that contains this is character composition and when I go back there I can see the head comp.

If I open up my transformed property group. And go to position, you'll notice that I can move that as a single group now. So, we want to continue doing that, so let's do the left arm as just a single layer. The body we don't need to do. The bottom we don't need to do. And we can actually delete that layer at the bottom. We don't need that one. So what we're going to do is we're going to go into the head comp, and make some separate compositions for the eyes. And this is what you want to do. So even within the head comp if I double click it to open it up, and if your using CS4 then you'll have to hold down the alt button when you double-click to open up the nested composition.

Been CS5 just double-clicking a composition will open it up. Now in here you've got ear glasses, hair right eyebrow, left eyebrow, and the pupils I want to group with the eyes, so that I can move the eyes in here and the pupils will move with them. So I'm going to choose the left eye hold on the command key or control key, choose left pupil. And then go to Lair precompose, or as we know, it's command shift C or control shift C on the PC. We'll call it left I comp.

And I'm going to remove the new composition because I don't want to open it at the moment. And then right eye and right pupil, command shift C, control shift C. We're going to write eye comp. Okay, so I've got two separate comps for the eyes. Now I may want to move them individually and if I do, then it's probably best to keep them in separate comps. Otherwise, I could group these together in a single compo, it's up to me really. But I'm, what I'm going to do is to show you the position moving. Now, to adjust the position value, normally I would open up the transform property group.

But this keyboard shortcuts for all the basic properties, so hitting p on the keyboard with the layer selected will bring up the position properties, and there you can see the eyes moving. Okay. I'm going to keep them in separate comps. 'Cuz there may be a time where I want to move 1 down a little bit, and 1 up a little bit. to kind of create a comedy effect. So I'm going to keep them as separate layers. Okay. I could also go and group the eyebrows together if I wanted to, but I think that's enough for now. So we've got our eyes grouped inside the head. Okay? So there's my right eye and left eye comp.

There's my head comp, and there's my character comp. So I'm starting to build up a hierarchy of structure, making it easier for me to control the layers and also making it easier for me to create animation. Now, if we want to access the compositions, or the pre-comps another way, We can go up here to our project panel and double-click them here to open them up. So there we have the right eye comp, the right arm comp, the head comp, the character comp.

Now if you want to, you can create a folder called precomps and keep them separate from the main comp. So I would select my right arm, my right eye, my left eye. and my head, and I'll pop them into the precomps folder, keeping them nice and tidy.

Show transcript

This video is part of

Image for 2D Character Animation with After Effects
2D Character Animation with After Effects

27 video lessons · 2956 viewers

Angie Taylor
Author

 

Start learning today

Get unlimited access to all courses for just $25/month.

Become a member
Sometimes @lynda teaches me how to use a program and sometimes Lynda.com changes my life forever. @JosefShutter
@lynda lynda.com is an absolute life saver when it comes to learning todays software. Definitely recommend it! #higherlearning @Michael_Caraway
@lynda The best thing online! Your database of courses is great! To the mark and very helpful. Thanks! @ru22more
Got to create something yesterday I never thought I could do. #thanks @lynda @Ngventurella
I really do love @lynda as a learning platform. Never stop learning and developing, it’s probably our greatest gift as a species! @soundslikedavid
@lynda just subscribed to lynda.com all I can say its brilliant join now trust me @ButchSamurai
@lynda is an awesome resource. The membership is priceless if you take advantage of it. @diabetic_techie
One of the best decision I made this year. Buy a 1yr subscription to @lynda @cybercaptive
guys lynda.com (@lynda) is the best. So far I’ve learned Java, principles of OO programming, and now learning about MS project @lucasmitchell
Signed back up to @lynda dot com. I’ve missed it!! Proper geeking out right now! #timetolearn #geek @JayGodbold
Share a link to this course

What are exercise files?

Exercise files are the same files the author uses in the course. Save time by downloading the author's files instead of setting up your own files, and learn by following along with the instructor.

Can I take this course without the exercise files?

Yes! If you decide you would like the exercise files later, you can upgrade to a premium account any time.

Become a member Download sample files See plans and pricing

Please wait... please wait ...
Upgrade to get access to exercise files.

Exercise files video

How to use exercise files.

Learn by watching, listening, and doing, Exercise files are the same files the author uses in the course, so you can download them and follow along Premium memberships include access to all exercise files in the library.


Exercise files

Exercise files video

How to use exercise files.

For additional information on downloading and using exercise files, watch our instructional video or read the instructions in the FAQ .

This course includes free exercise files, so you can practice while you watch the course. To access all the exercise files in our library, become a Premium Member.

Join now Already a member? Log in

Are you sure you want to mark all the videos in this course as unwatched?

This will not affect your course history, your reports, or your certificates of completion for this course.


Mark all as unwatched Cancel

Congratulations

You have completed 2D Character Animation with After Effects.

Return to your organization's learning portal to continue training, or close this page.


OK
Become a member to add this course to a playlist

Join today and get unlimited access to the entire library of video courses—and create as many playlists as you like.

Get started

Already a member ?

Become a member to like this course.

Join today and get unlimited access to the entire library of video courses.

Get started

Already a member?

Exercise files

Learn by watching, listening, and doing! Exercise files are the same files the author uses in the course, so you can download them and follow along. Exercise files are available with all Premium memberships. Learn more

Get started

Already a Premium member?

Exercise files video

How to use exercise files.

Ask a question

Thanks for contacting us.
You’ll hear from our Customer Service team within 24 hours.

Please enter the text shown below:

The classic layout automatically defaults to the latest Flash Player.

To choose a different player, hold the cursor over your name at the top right of any lynda.com page and choose Site preferences from the dropdown menu.

Continue to classic layout Stay on new layout
Exercise files

Access exercise files from a button right under the course name.

Mark videos as unwatched

Remove icons showing you already watched videos if you want to start over.

Control your viewing experience

Make the video wide, narrow, full-screen, or pop the player out of the page into its own window.

Interactive transcripts

Click on text in the transcript to jump to that spot in the video. As the video plays, the relevant spot in the transcript will be highlighted.

Are you sure you want to delete this note?

No

Your file was successfully uploaded.

Thanks for signing up.

We’ll send you a confirmation email shortly.


Sign up and receive emails about lynda.com and our online training library:

Here’s our privacy policy with more details about how we handle your information.

Keep up with news, tips, and latest courses with emails from lynda.com.

Sign up and receive emails about lynda.com and our online training library:

Here’s our privacy policy with more details about how we handle your information.

   
submit Lightbox submit clicked
Terms and conditions of use

We've updated our terms and conditions (now called terms of service).Go
Review and accept our updated terms of service.