Ease and Wizz has a preset for “bounce”, adapted from Robert Penner’s easing equations. It’s useful for basic simulations, but it doesn’t give much flexibility when it comes time to customise it. Fortunately, most everyone on Earth has plugged their computer into The Internet, so a solution is never far away.
Dan Ebberts gives a great introduction to After Effects expressions on his site, motionworks.com, including a slew of articles on physical simulations. I’ve taken the example that Dan provides for a basic bounce, modified it a little, and made it into a preset for you (hey, it’s that time of year):
Ebberts bounce.ffx.zip
There are sliders to adjust amplitude, decay, and frequency. By tweaking these you’ll be able to achieve a variety of effects. I recommend reading Dan’s original post about this expression too. If you don’t have time to peruse the original post, at least check out what Dan has to say about choosing the frequency:
Note that you need to choose your frequency carefully to sell this effect. For example, at 30 frames per second, a frequency of 2.0 will cause the first bounce to occur half way between frames 3 and 4. So it will look like the ball never quite hits the “floor”. To have it occur exactly at frame 3, you would need to change your frequency to 2.5, and to make it occur at frame 4, you’d change the frequency to 1.875.
Now: having quoted Dan’s sage words, I’m going to encourage you to screw it all up by tweening the frequency. In real life, frequency increases as the amplitude gets smaller (think of a ping pong ball, and the way the bouncing speeds up). By tweening the frequency (say, starting at 1 and ending at 2), I find I’m able to get it to look a little more convincing.
Note that this expression does not use keyframes – it only uses the values defined on the sliders.
If you’re still with me, I’ll go into a little more detail after the jump. Continue reading →