Easy-to-follow video tutorials help you learn software, creative, and business skills.Become a member
Now we've all been in that situation where your client's come up to you and said, "Hey, can you cut this out of the background," and you look at them and go, why didn't you shoot this on green screen? But you and I both know most of the time when that happens you really don't have a choice anyway. So the best thing to do is actually cut out the piece of video using a mask. I am going to be using kind of an interpretation of a cut-out since the edges of her hair are so soft and there are so many fine details, there's no possible way where I'm going to actually create an edge of the mask that actually looks real, like she's standing over the background.
What I need to do is create kind of a soft interpretation of her being cut out of the background, and we are actually going to blend that into a graphic and create an interesting graphic build. This will be a title card for this person in the scene. To get started, let's press F5 and view what we have got going on here. As you can see, we've got our video layer and we have a background graphic. If I turn on its visibility, you can see it's kind of a bokeh effect. This was created with a cellular generator, and I am going to show you how this was created in the Generators chapter, but for now, let's focus on masks.
Just for speed's sake, I am going to turn off this generator for right now and turn back on the visibility of our video layer. Since I don't need to use the File Browser for the time being, let's press Command+1 and hide it so we have a little bit more real estate to work with. Now to create a mask you need to first make sure you have the proper layer selected that you want to mask, so I'm going to select the portrait_ claire layer. And also, you typically want to start drawing your masks from off the edge of the scene, especially when you have an image like this where this is a tight crop and she goes off the edges of the image.
So press Command+Minus to zoom out just a little bit here. As you can see, this piece of video is a little bit larger than our projects, but I like how this is looking, so I am just going to leave it the way it is, and grab our Mask tool. If you notice, it's the rightmost tool out of all the tools on the left side of the bottom of the interface. And if you click and hold, notice we have a bunch of different options from rectangle to circle to freehand masks. The one I want to choose is called a B-Spline Mask. The reason I want to choose this, it's automatically going to create soft-edge transitions without having to draw out any Bezier handles to control the shape.
With the B-Spline Mask tool selected, notice as I move my cursor over the canvas, I can see I have the Pen tool and it's a B-Spline Mask. That's what that little icon is in the lower-right corner. If we go ahead and click, what you want to do is click around the edges of Claire and make sure that you have enough points to get the kind of detail that you are looking for, but not so many that it takes absolutely forever to render.
Another reason you want to watch the number of points is the fact that you don't what to have to add any points later on if the shape became more complex. See, if you add points, when they go to animate, you'll get this weird kind of jumping effect, and you definitely don't want to have that. If you are cutting out something that's a little more complex than what I'm showing you here, you want to actually start by masking the most complex shape you can find and then just work forwards and backwards up and down the Timeline, adjusting where the points are to actually animate your mask.
You can notice I've stopped here, as I was yapping about points and all that stuff, because I wanted to show how important it is when you get back to the first point, you want to make sure that the icon changes to that open circle. That's letting me know that I'm closing off that mask. So when I click, it's closed off. Now that I have this rough outline shape I just want to click off of the B-Spline Mask that's been applied to the video layer just by clicking anywhere else in the Layers panel.
And here you can see the edge that I've created. This is a little hard edge for what I'm looking for, but it's relatively close. So all I need to do is just select the B-Spline Mask and press Command+3 to open the Inspector. In the Mask section here you'll notice I have several different mask controls. If we go to the Mask blend mode the two most common ones you will want to use is Add and Subtract. As you can see, one adds the video, the other subtracts the selection.
Replace and Intersect actually worked if you have more than one mask applied to your video layer. Just to show you how to do that, I am going to reselect the video layer and go back to my B-Spline Mask tool and I'll just add another shape. Just to kind of show you again, I will mask off this one section here, again, making sure to close the mask. And notice by default when two masks are applied, it creates one huge mask.
This is really nice if you have got a complex shape. You could actually create one shape for one part of the image and another shape for another part and once the multiple masks are added together, it will look like it was all just created with one mask. Let's reselect our first B-Spline Mask and look at the Mask controls. Change the Mask blend mode from Add to Replace. Now you notice when you choose Replace it's just going to replace any subsequent masks below. If you choose Intersect, it's only going to show you the area of the image that intersects between the first and the second mask.
So now that you understand how multiple masks work, let's just delete this second mask by selecting it and pressing Delete. What we want to do is actually animate this mask. So to animate it over time, all you have to do is turn on your Automatic Keyframing by pressing the A key. With this selected, notice I've automatically got the Adjust Points tool selected. All I have to do is literally just reposition the points the way I'd like them to appear in the scene before I actually start my animation. So, here we go.
I was a little close there. Now I am cutting a fair amount of the image off, and that's just because I am going to feather this mask once I'm finished creating the general shape. That will be the first one. And notice I have a keyframe that's automatically been created. If I wanted this to be really precise, I can track this frame by frame by literally moving one frame down the Timeline each time I hit the arrow key. But just to give you a general idea, I'm going to move quickly right ahead to around 1 second.
Since her general shape is the same, rather than clicking on each individual point, what I am going to do is click on one point and then press Command+A to select all the points and quickly just move the entire shape over. And if I did want to tweak some of the different points, I'd just deselect the mask really quickly by clicking off of it in the Layers panel and then when I go back and select an individual point, you can see that I can actually control the overall shape just by adjusting the individual points here.
I am just going to turn that off for now and move down to around two seconds, and we will move this one more time. Again, select one point, Command+A, and drag back over. All right! This is looking pretty close to what I was looking for. I just want to preview this one section, so I will change the preview range by pressing Command+Option+O and pressing A to disable our Automatic Keyframing.
Now let's click off of the B-Spline Mask and press the spacebar to preview our mask. So as you can see I've got a fair amount of drift and to deal with this, I would have to go in and reposition the playhead and move the mask points accordingly, but for illustrative purposes, this is good enough for now. What I want to do is just soften the edge of the mask by selecting the B-Spline Mask and adjusting the Feather. You can also adjust the Falloff, which is how quickly the feather starts to disappear, just by adjusting the Falloff with the slider.
Now we will adjust that to 100%. You can actually increase the Roundness between the different points if you want even less detail, but I will just leave that alone. We have got our basic shape cut out. Let's see how we can blend it into the background. If I select my Cellular graphic here and activate it, you notice on this side it's actually looking pretty darn good. I bet if I went in and tweaked this other side, I could get something that looks relatively acceptable, which is really kind of pleasantly surprising.
If you wanted to go for more of an open interpretation, you could select this video layer and go to the different properties in the Inspector and adjusting things like the blend mode. For example, if we chose Lighten, she blends into the background. I kind of dig what this is doing, other than this large section over her face. In order to fix this, I am going to select the B-Spline Mask that we've already animated and hold Option and drag it down to the Cellular graphic. That way the same mask has been applied to the subsequent layer.
In order to adjust to this a little bit, all I am going to do is, with the mask selected, I am going to choose the Subtract Blend mode. I can just go ahead and scale this whole mask down just a little bit, and as you can see, I am getting kind of a funky blend back into the scene with the colors adjusting accordingly. If I really wanted to keep tweaking this, I would duplicate this layer and move it above the other layer and create more blend modes and adjustments, but I think you get the general idea.
When it comes to creating animated masks inside Motion it's just as simple as creating your mask using the same principles we used for creating any shape with the Bezier points, actually activating Automatic Keyframing in your Timeline.
Get unlimited access to all courses for just $25/month.Become a member
110 Video lessons · 47409 Viewers
86 Video lessons · 9792 Viewers
350 Video lessons · 99658 Viewers
79 Video lessons · 13305 Viewers
Access exercise files from a button right under the course name.
Search within course videos and transcripts, and jump right to the results.
Remove icons showing you already watched videos if you want to start over.
Make the video wide, narrow, full-screen, or pop the player out of the page into its own window.
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.
Your file was successfully uploaded.