Pro Tips, Tutorials

A Beginner’s Guide to Content-Aware Fill in After Effects CC


I’ve worked on tons of TV commercials and film projects as a VFX guy, motion-graphics artist, and editor. A lot of times, clips in those projects would need some form of clean up or object removal. My usual workflow would include rotoscoping, painting, creating a clean plate, and then tracking that into the shot. Sometimes it’s straightforward, but it gets complicated when there’s camera movement or the thing being removed has a lot of motion.

So I was especially excited when Adobe announced that After Effects would now feature the popular Content-Aware Fill feature, previously only available for working with still images in Photoshop. Content-Aware Fill takes care of removing and tracking the object in your shot for you, as well as filling in the missing pixels. Read on to learn more about how to use Content-Aware Fill in After Effects CC, so you can start removing elements in your own clips and making your shots look even better.

Getting Started

If the Content-Aware Fill panel is not yet open, go to Window > Content-Aware Fill to launch it.

We’ll be using this clip of a car moving on the beach by Pond5 artist randomoperator. Here, I’d like to remove the entire vehicle from the shot.

After doing some color correction, I added a rough mask, also making sure it’s big enough to cover the entire car.

Next is tracking or adding keyframes to the mask to follow the car’s movement. Lastly, change the mask mode to “Subtract” (otherwise it won’t work).


Disappearing Act

You’ll now see a preview of your mask in the “Fill Target” section of the Content-Aware Panel. The Fill Target shows you the area that will be analyzed. You’ll also notice that the transparent area has a pink outline.

Under the Fill Target is the “Alpha Expansion”, which allows you to expand the area that will be analyzed.

There are three different “Fill Method” choices. The default is “Object.” This is great for removing moving objects. The second one is “Surface,” useful for static shots and flat surfaces. The last one is “Edge Blur,” which works well on static objects and on surfaces that lack textures.

“Range” lets you define if you want the Content-Aware Fill to work on the entire composition or just the work area.

For this example, we’ll use the Object method and the entire composition for our range, since the shot is short. Click “Generate Fill Layer” to start the object removal process. After Effects will analyze the shot and render a fill layer, automatically places a PNG sequence in the composition and fills up the missing areas in your shot.

Once everything is done, you should no longer see the unwanted objects in your scene. That’s how easy it is!

Here are other examples where I used the other fill methods:

I used the Surface fill method to clean up the outside parts of the wall in this clip of a graffiti-covered wall by america_stock. The result is more focused on just the graffiti in front of the artist.

The Edge Blend fill method works perfectly to remove the logo on the front and side of this delivery van clip by LoganImages.


Reference Frames

Of course, some cases won’t be so simple. In those instances, it’s better to create a reference frame, which will help the algorithm determine how the shot should look. 

Select “Create Reference Frame” to create a reference layer that’s placed under your original video. This will also open Photoshop automatically, so you can manually clean up the reference frame there. In Photoshop, you can use any tool you prefer to clean the frame. Once done, just hit save and close Photoshop.

Back in After Effects, select “Generate Fill Layer” again and wait for the whole process to finish.

Bonus Tips

  • It’s best to separate complicated objects with different masks. For example, separate a person walking and his shadow — especially if the shadow movement is very different.
  • Smaller masks are faster to render.
  • Fill layers are PNG sequences that may take considerable drive space, so be sure to delete the ones you won’t use.
  • Feather the mask if you’re seeing borders in your fill layer. The resulting mask will give you a fill layer with softer edges.
  • You can create selections using a mask, rotobrush, eraser tool, or keyframing.
  • Finally, remember that Content-Aware Fill is a great tool, but it won’t solve all your problems. Nothing beats proper preparation and planning when capturing your shots to reduce editing time during post-production.

    Related Post Object Removal in After Effects (with Help from Mocha and Photoshop)

    Do you have questions about working with Content-Aware Fill in After Effects? Are there other features you want to learn more about? Tell us in the comments below!