An Easy Way to Map a PreComp’s Frames to Position in After Effects

Joe Clay Has a Take on Using Expressions to Map frames to Position on the Screen Helping Add Some Appeal on a Parallax Effect

WorkBench’s Joe Clay runs through a handy way to add more of a three-dimensional look to objects when they are scrolling in a parallax effect, in After Effects. Joe shows a way that you can fake a slight 3D rotation as things move by the camera.

The fake-rotation technique is just moving anchor points around and keying their position. The good stuff comes in, using a layer dolly expression that can remap a pre-comp and its frames to the location of the objects on the screen. The expression will remap time to rotate the houses as they dolly by the camera.

Joe also gives a tip for doing the same expression with rendered objects from a 3D animation.

Layer Dolly Expression:

//Remap time to rotate house as they dolly by
s = this.source.name;
end = comp(s).duration;
x = this.toWorld(this.anchorPoint)[0];
linear(x,2052,-152,0,end);