(electronic chimes)
- Hello, and welcome to the 27th video
in this beginner's guide to Adobe After Effects.
In this tutorial, we're going to look
at how to create null objects
and parent layers in After Effects.
Now, over the past few episodes,
we have looked at precomps,
and how they help to group layers together
to apply effects and track mattes as a whole.
Now, in After Effects, there is another way we can group
multiple layers and manage things like
position and scale of multiple layers at once.
In After Effect, we can create what is called a null object,
and use something that is called parenting.
In this video, I will be discussing
null objects and parenting,
and how these work in After Effects.
So, in this video, we will be covering the following topics:
What is a null object?
What is parenting?
And how to create a null object, and how to parent layers.
After this video, you will get a better understanding
of what null objects are, and how parenting works,
so you will feel more comfortable
and confident moving forward.
So, let's get into it.
So here I am in After Effects,
and I have a project open here
that I'm going to use to demonstrate
how null objects and parenting works.
So right now, I have an animation of a swarm of butterflies
flying over a field of daisies.
Also, as they fly over, the scale of them all is changing
to create an appearance of zooming out a little.
Now, if I look in the timeline panel,
we can see that each butterfly is on its own layer.
So there is quite a few butterfly layers here,
and they are all flying together.
Now, up until this point on the course,
we have learned about how to animate layers individually,
applying key frames to each layer,
for example, position and scale, to animate specifically.
Now, if I select all the butterfly layers,
and press P to activate position,
we can see that there are no key frames for position.
If I press S to activate scale,
again, there are no key frames for scale.
So, how are all these butterflies moving and changing scale
all together without any position
or scale key frames applied?
Well, what is happening here, is that we have a null object
that is moving, and all the butterfly layers are parented
to that null object.
So, what exactly is a null object?
Well, in After Effects, we can create what is called a
null object layer.
A null object layer is essentially an invisible layer
that exists with no visual content.
The null object acts like a bearing,
and just like any other layer,
position and scale key frames can be applied.
And just like any other layer, animation can be applied,
such as position or scale.
Now, a null object on its own is pretty useless,
but we can use them in After Effects
to parent other layers to.
So what exactly is parenting?
Well in After Effects, we can parent
multiple layers to one layer.
It will help to think of parenting
as linking one layer to another,
and in After Effects you can link multiple layers
to just one layer.
For example, if we wanted to animate one layer
instead of animating 20 individual layers,
we can parent link 20 layers to one layer,
and only animate the one layer.
Think of this as like an airplane, dragging lots of boxes.
The airplane is the object that moves,
and the boxes are the static layers without movement
that get linked to the airplane, which drags them around.
Wherever the airplane moves, in whichever direction,
so do the boxes.
Now, just to come back to the null object,
in this instance, our airplane can be a null object,
and because the null object is invisible,
it can appear like the boxes are moving around
in a group by themselves.
Now, in After Effects it is common when creating
complex animation sequences to parent layers
to a null object to move multiple layers around in unison.
So if we look in the timeline panel of the layers,
at top we can see we have a null layer,
and here we can see that there are
position and scale key frames applied.
What is happening here is the invisible null object
is moving from left to right, as well as scaling down.
And all the butterfly layers are parented
to this one null object.
So as the null object moves and changes scale,
so do all the butterfly layers below.
So instead of having to spend lots of time
animating each butterfly layer individually,
I have simply animated one layer,
and parented all the butterfly layers to that.
So let's take a look at how we can do this in After Effects.
Now, if you have the project folder,
you can open up the document I have here.
With the project folder open, click into the
S2 Essential Practise folder, into folder 27,
Null Object and Parenting, and open the
Null Object and Parenting After Effects file,
and you will have the same document I have open here.
This is a document you can use to quickly experiment
with null objects and parenting with me in this video.
Now, if you don't have the project folder
and you want to follow along with this tutorial
using this document I've prepared especially for you,
you can download this project folder for a small fee.
The download link with instructions is in the description.
The download folder comes with lots of exercise documents
we will be using on this course,
that have been carefully developed
to aide your learning experience.
The folder also comes with document resources,
such as videos, graphics and images you can use
to build your first video presentation
from scratch later on in this course.
To get the full learning experience,
I recommend you get the project folder.
Download link with instructions is in the description.
So with the project folder open, click into the
S2 Essential Practise folder, into folder 27,
Null Object and Parenting, and open the
Null Object and Parenting After Effects file,
and you will have the same document I have open here.
So now, I want to draw your attention over
to the project panel.
Here, you can see I have a folder called Preview,
and one called Worksheets.
For now, I need you to pay attention
to the Worksheets folder.
So double-click on the composition here,
Butterfly Fly Over Test.
So, I'll make sure the time indicator
is at the start of the timeline,
and I'll press space bar to activate the preview.
So right now, we have a bunch of butterflies
positioned in the composition.
As we preview this, we can also see
all the butterflies are flapping their wings in unison.
Each butterfly looks to be the same size,
and there is a static image below them.
Now looking at the butterfly layers in the timeline panel,
we can see they are all composition layers.
Now if we come and double-click on one of the comp layers,
it will open up in another tab,
and we can see that this is a
separate animation sequence of its own.
I make sure that the time indicator
is at the start of the timeline,
and I'll press space bar to activate preview.
Here, we have an animation of the wings changing scale,
creating the appearance that the butterfly
is flapping its wings.
This is something I have prepared earlier.
So I'll close this, and come back to the main comp.
So, each butterfly is a comp layer of a separate animation.
So now, I want to create an animation
of all these butterflies flying together
from left to right over the field of daisies below.
Now, I could animate each comp layer separately,
but that might take a while.
So what I can do here is create null object,
animate that one layer,
and parent all the butterfly comp layers to it.
So to do this, first, we will want
to create a null object layer.
To do this is easy.
I'll come up to Layer, scroll down to New,
and come across and click Null Object,
and upon click, you will have a new null object layer
on top of the layer stack.
Now, if you look carefully in the compositions panel,
we will now have this square shape appear.
Now, if for whatever reason you cannot see this,
come up to View and make sure
Show Layer Controls is checked.
Now, this null object layer is essentially invisible,
but we have to see this square outline in order
to know where exactly the null object is positioned,
so when we move it around, we know where it is.
And this is what we can click, and move around, and animate.
So that is how we create a null object.
Next, we need to parent all the butterfly layers
to this null object.
So if we look carefully in the timeline panel,
we can see the controls and switches of our layers.
Here, we can see the blending mode,
and track matte options we have used previously.
But now, we are looking for something new.
Now right now, I cannot see it on my panel.
So what I'm going to do, is carefully come up to the
top of panel, where it says Mode and Track Matte,
I'll right click, and come down to Columns.
What I need to do is come down to Parent and Link,
and click this.
Upon click, we should now see a new Parent and Link column.
Now notice this little squiggle here.
This is called the pick whip.
Now if we select a layer, and in this instance
I'm going to select the top butterfly layer,
I can click and drag the pick whip
on this layer around like so.
This is After Effects asking me which layer
I would like this to parent to.
In this instance, I'm going to drag my pick whip
onto the null object layer at the top.
Easy!
So next, I want to link the rest of the butterfly layers
to the null object, so I'll click on the next layer down,
hold shift, and select the bottom butterfly layer,
and with them all selected, I can grab a pick whip,
and drag it onto the null object.
Upon release, all these layers
are now parented to the null object layer.
Also, notice that on the parent link drop down
for each layer, it will state which layer it's parented to.
So if I click off the layer to deselect, or press F2,
if I select the null object layer,
and press V to activate the selection tool,
and click and drag the box around the composition layer,
we can now see that they all move around together in unison.
So now what I can do, is animate this null object layer
using the same techniques we learned previously.
so I'll place my time indicator at the start of the comp,
with my null object layer selected,
I'll press P to activate position,
I'll come over and place the first key frame
by clicking the stopwatch, and with my arrow keys,
I'll move my null object left, while holding shift
to move across in larger increments.
And I'll move the butterflies off-screen.
Next, I'll drag my time indicator
over to the end of the comp, and with my arrow keys,
I'll move the null object over to the far right,
while holding shift to move over in larger increments.
And I'll do this until the butterflies are off the screen.
So just like that, I have moved
multiple layers quite easily.
Now, we can also apply scale to the null object.
So I'll place my time indicator at the start of the comp.
With the null object layer selected,
I'll press S to activate scale,
I'll come over and place the first key frame
by clicking the stopwatch.
Then, in the settings, I'll drag the scale up to 120.
Next, I'll drag my time indicator
over to the end of the comp, then in the settings,
I'll drag the scale down to 70.
And upon changing the scale settings,
we will get a new key frame for scale.
So I'll make sure the time indicator
is at the start of the timeline,
and I'll press space bar to activate the preview.
So now, the butterflies are moving
and changing scale as a group.
And I'll press space bar to stop the preview.
Now, the really cool thing about parenting layers like this,
is that it allows you to then make changes
to the individual layers that are parented.
For example, what if I want to change
the formation of the group,
and perhaps change the scale of some of these layers?
Well that's really easy.
So I'll click on the timeline in the middle,
so I can see all the butterflies,
and with the selection tool, simply click on a layer.
I'll press S to activate scale,
and scale down the layer like so,
and we can do this to any layer.
So I'll click around on some of the butterflies,
and change the scale by pressing S,
and scaling them down like so.
Now, we can even move them around.
With the selection tool active,
simply click and drag them into new positions.
So, I'll make sure the time indicator
is at the start of the timeline,
and I'll press space bar to activate preview.
And now, we have a variety of shapes and sizes.
So when we animate a null object,
any parented layers will follow.
This will give us the flexibility
to tweak the individual parented layers themselves.
We can change position, change the scale,
or change the opacity.
Now, we can even change time here too.
So right now, they are all flapping their wings
at the same time.
This is because each animated comp
has the same animation to the same time.
To create a more dynamic effect, we can mix it up a bit,
so they all appear to flap on their own time.
To do this is easy.
Simply come down into the timeline panel,
and click and drag each layer slightly left or right.
This will break the unison they all currently have,
so some will start earlier,
and some will start later than others,
which will create a more random flapping appearance.
Easy!
Now, we can even go one step further,
and add animation sequences to each layer.
For example, I'll move my time indicator to the middle,
and let's grab a butterfly layer.
Now, let's say, as the butterfly flies over,
I want it to scale down and then back up again,
so it looks like it's diving and flying back up.
Well, I can press S to activate scale,
I'll come over and place the first key frame
by clicking the stopwatch,
I'll drag my time indicator over a little,
and I'll click the scale down like so,
where the butterfly dives.
I'll drag my time indicator over a little again,
I'll select the second key frame, press Command C on Mac,
or Control C on PC to copy,
and press Command V on Mac, or Control V
to paste the same key frame with the same value.
Next, I'll drag my time indicator over a little, again.
This time, I'll select the first scale key frame,
press Command C on Mac, or Control C on PC to copy,
and press Command V on Mac, or Control V on PC to paste
the same key frame with the same value
as the first key frame, and the butterfly
will be back to the original size.
So here, we have four key frames applied.
First, the butterfly scales down,
stays small for a few frames here, and then scales back up.
So now, I'll quickly add some easing to the key frames.
By right clicking on the frames,
I'll add an ease out to the first key frame,
and then ease in to the last key frame.
Now, I'll click before the sequence on the time ruler,
press B to set the beginning of the workspace area,
then click after the sequence
and press N to set the end of the workspace area.
I'll click into the workspace area
and press space bar to activate preview.
So now, as the butterfly moves along,
it now performs its own animation,
swooping down then swooping back up again.
So that's how a null object can be created,
and how it can be used to parent multiple layers
in order to control multiple layers at once.
So remember, you can parent multiple layers
to one null object to animate as a group.
When we parent layers to a single layer,
we still have the flexibility to control layers individually
and apply their own animations.
This allows you to animate and manage
very complicated sequences in After Effects.
So now, we are coming to the end
of the essential practice section on this course.
Once we have finished our animation sequences,
and built our video presentations, it's time to export.
Now, there are few ways to export in After Effects.
In the next video, I'll be demonstrating the ways
you can export your finished projects off in After Effects.
So, see you in the next video.
(techno music)