- Tracking the shot in Mocha (at 1:46)
- Stabilizing the shot (at 5:45)
- Fill in missing parts at the borders (at 11:26)
Note:This tutorial uses an old version of MochaImport. The new version MochaImport+ creates an even more powerful stabilization in a single click. See this video for details of the new method.
In this tutorial you learn how to stabilize a shaky shot with the Mocha tracker and MochaImport. After stabilization, you usually need to zoom in a bit to get rid of empty areas that show up at the borders of the image. Instead of this, we use a clever technique to fill the missing parts at the borders such that there is no need for zooming any more. The technique uses frames before and after the current frame to fill in parts of the image that are missing in the current frame. Sounds complicated but works very well and is done with a few clicks using MochaImport.
Things to learn in this After Effects tutorial:
- Learn how to track in Mocha (I use Mocha Pro, but it also works with any other variant)
- Learn how to stabilize a shot with the MochaImport script.
- Learn how to smooth the camera movement with a simple expression.
- Learn how to fill in missing parts at the borders of the stabilized footage by inserting appropriate material from the frames before and after the current point in time.
Expression for Smoothing the Camera Movement
smooth(width = 1, samples=5, t=time)The smoothness can be controlled by the value for "width". To get an even more smooth movement make this value larger, to make it less smooth make it smaller (e.g. "width=0.5"). "width=1" means that the values over the duration of one second are smoothed (i.e. averaged).