How To Remove Moving Objects in After Effects

To remove moving objects in After Effects just create a mask around the object you want to remove. In the tutorial above that was a car that I want to remove from the street.

With the clip selected and the rectangle tool just drag a mask around the object. Set the mode of the mask to ‘None‘ so you can see what’s going on.

In our case here we want to make sure there is enough room around the car so it also captures the shadow of the moving object. Otherwise, it would be visible later and you would not get a perfect result. Also, you don’t want the mask to intersect with other details in the shot so when the content-aware fill is doing its thing you don’t get any weird glitches.

Now in the mask click the stopwatch next to ‘Path‘ and start animating the mask with the moving object.

Next step is using the ‘Content-Aware Fill‘ panel. If you don’t see this panel and enable it under ‘Window -> Content-Aware Fill‘.

When you now set the mask path to ‘Subtract‘ you can see which area the content-aware fill is going to target in the ‘Fill Target‘ preview area.

Set the ‘Alpha Expansion‘ to a value around 15 so it is feathered a little bit, which should give you a smoother result. You might want to play with the ‘Lighting Correction‘ value (just check the box if necessary) if you need to adjust the lighting but in this case that was not necessary. Now click on ‘Generate Fill Layer‘.

After Effects will start calculating and creating a new layer with the newly created content-aware fill frames!

When you play the preview area now the car should be removed from the shot. Actually not removed, but obscured by the new fill layers which will give the impression that the car has been removed.

The tool does a really good job when creating these new frames and using the content-aware fill to visually remove any objects. This works very similar to the function you might know from Photoshop. But on a video clip over multiple frames.

You can always double-check the result by toggling the new layer on and off. If it didn’t create the desired result consider going back and creating a more accurate mask and tweaking the settings in the content-aware fill panel.

As you can see it’s really easy to remove moving objects in After Effects with the Content-Aware Fill panel and just a few clicks.