What you need is a peak detector. This is being brought into the audio library but isn't yet released (SFAIK). It's a full wave rectifier which, combined with a tunable lowpass filter gives you...