Have you shot a time-lapse that looks perfect for the most part, but want to amp it up by adding in a different sky? You can add in a new sky or even another background element with masking. In this video, author Keith Kiska demonstrates how to use masking in Adobe After Effects to add in a cool sky to a time-lapse shot.
- [Instructor] Now that we have compositing down pretty well let's apply what we've learned with masking to add some cool skies to our shot. So for this example, we're taking a look at this shot of Los Vegas skyline from the Stratosphere Hotel tower. And, as you can see, it's a really nice, solid shot. It's static, the camera's not moving, but I'm shooting through a plate of glass. And this is a great shot for a number of different reasons that we're going to get into in the next couple of chapters. The first of which is the sky. The sky is very, just, let's face it, it's boring.
There's nothing happening. There's no clouds. There's a couple exciting planes, but that doesn't really do it for us. So we're going to want to go ahead and replace the sky. Another couple of things that we notice is that in the bottom right-hand corner over here, keep your eye on that. You'll see a lot of reflections from the door behind us. Someone was going in and out over and over again, and I guess there was an elevator, and that is a little bit of an issue that we're going to actually fix later. And as you can see, too, the reflections are right here in the upper top-hand corner.
So by replacing the sky, we're going to go ahead and fix all those little reflection issues, and then later we're going to go ahead and adjust to fix the reflections in the ground. So to replace the skies, first thing we're going to have to do is create an alpha. We're going to have to crop out the existing sky right along this edge. Now, After Effects only has a masking tool, so we're going to want to do this in Photoshop. So I went ahead and I found one of the images from that time lapse sequence, the full quality image, the same exact size as the sequence itself.
And it's a JPEG, and we're going to go ahead and open this in Photoshop. Okay, so as we see right here, here's our shot, full-res photograph. Now we're going to basically just cut out the sky because we're trying to create an alpha in the After Effects comp. So to cut out the sky, we're going to go ahead and click on W for our quick selection tool, and we're going to just very nicely go across the sky. And in some cases, it'll be easy like this, in some cases it'll be a little bit more complicated. To make sure we have a nice, clean selection we're going to go ahead and click on the Select A Mask.
And this'll give us some options to work with. Let's try to invert the mask itself so that we can see the bottom, and we're going to zoom in as much as we can here. Some things I like to play with is the Shift Edge. As you can see, this'll give us some more sky, and this'll cut into the mountain a little bit. I guess I just want to make sure that it's cutting into the mountain so we don't see any sky. And you can smooth it out. This'll smooth out everything a lot, and this'll retain a lot of the sharpness.
I don't really want to mess with feather, I don't really want to mess with contrast. Everything else looks good, so I'm going to go click Okay and zoom out. I'm now ready to click on the mask layer right here, and that's going to go ahead and apply the mask based on our selection. Okay, so as you can see, it basically knocked out our entire sky, perfect job. So now we have this layer right here and the sky knocked out and we're going to go ahead and right-click on the mask, and Apply Layer Mask.
And that is basically going to apply all into one, so this is now one layer with a hollow background right there as an alpha. Okay, so now let's go ahead and save that as a PSD. Photoshop, there we go. Okay, and let's go back to After Effects, and let's import file, there we go. And we're going to want to import it as a composition.
So now that we have our new alpha-ed layer in our bin, and again, this is a single photograph with just a cut-out sky. We want to basically take the cut out sky with the edge and apply it to this motion time lapse, and basically just create an alpha and knock out the current sky. To do this, we're going to go ahead and let's duplicate this layer so that the top one stays correct. And the bottom one, let's right-click and pre-comp that.
So let's double-click into the pre-comp, okay, and now let's duplicate this again. Grab that layer that we just made, drag it over it, hold down Option, and that should replace that file with a new file. Keeping the scale and position exactly the same. So now we have the image directly over the other one. This is our photograph, photograph right there, and time lapse.
So now we basically just want to Mode, Stencil Alpha, and just like that, the sky is knocked out, and the static photographed image is gone now, and what we are left with is a time lapse of the bottom, the main part with all the motion, and no sky. So now we're very happy campers and let's go back to our original composition.
And as we can see right here, this is the sky version. Let's go ahead and put this underneath. Okay, so this is our foreground layer with our time lapse city bottom, and then here is the old sky time lapse. Now what we do want, we don't want all the sky, but we're going to go ahead and put a new sky underneath right here. But before we do that, let's keep a little bit of the original sky so that it helps the whole shot look a little bit more real. And let's grab the mask layer, the pen tool, and create a mask.
Let's do a little bit of a slight tilt like that, there we go, okay. So as you can see, we're only using some of the original, and let's add a little bit of a feather on that mask to blend it. A little bit more, very nice. So now at the very least some of those pinks and oranges, some of those natural hues come through. And as you can see, the line, the hard line is still right there, so anything we put behind here and behind there is going to work very well.
Now, when choosing skies to actually replace you want to make sure that your angle is the same. So for this shot, we're going to replace a sky that's directly on the horizon line. So if you used a shot where you just pointed the camera directly up at the sky with no horizon, and tried to place that in here, it would look entirely odd. So what you want to do is replace it with a shot where your angle is very much similar, so your horizon line is very similar so it reacts very, very authentic.
So what I did was I went ahead and chose this shot, which is another shot from Death Valley, and let's put this on top for now so we can take a look at the shot itself. Okay, so this is the sky that I want to use. And I already pre-played with this, so I know exactly what I want to do, and I want the shot reversed. And I want to use the end of it, right about here. The end of it being the new beginning, there we go.
So, the moon rose, and the sky brightened up a lot. So let's bring it right about there. Now let's drag it underneath, okay. Zoom in a little bit, and there we go, so now let's move and adjust our sky. See, so the natural horizon is right there, so we want to bring it just about there. So it kind of matches. Now let's grand preview and see what we got. Very nice, we see a little bit more of the sky we can do a pan up and down if we'd like to, the sky's moving really nicely.
The angle seems to match, they're both shot with a 16 millimeter lens, I believe. And we can go ahead and move this around, we can stretch it a little bit if you'd like, and maybe get a little more wider, maybe this area is a little bit more appealing, we can move this gradient of the sky. See, 'cause without it, you notice that you really see the hard edge of the cut. But if we add in a little bit of the old background, and we use some of the actual real element that was actually there, and it really helps sell the illusion.
Let's add a little bit more feathering to it, that's just perfect. See, so, you barely can tell that it's fake. The only way you could tell is was fake was by someone saying hey, you can't expose for the stars and for colors at the same exposure! But it must be a really good HDR type of camera, so that's what we're trying to do here. We're trying to sell the illusion to make it look as authentic as possible.
- Adding 3D motion to static shots
- Enhancing motion in motion shots
- Creating a HyperZoom in time-lapse shots
- Adding text to shots
- Compositing natural skies or background elements
- Compositing foreground elements for motion or depth of field
- Removing unwanted elements from shots