Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expression Slider

  • Expression Slider

    Posted by Brad Strickman on June 20, 2007 at 6:25 pm

    I have 2 layers, an audio layer and a still image. I have converted the audio to keyframes, giving me all the keyframes for amplitude. I am attempting to alter the scale of the still through expressions linking it to the audio. The issue is that the amplitude range is 0-100 and the range of scale I need is 60-80. How do I convert the ratio of the amplitude keyframes so that they fall within the proper range? Thanks for any help.

    Brad Strickman

    Lord Scales replied 18 years, 10 months ago 2 Members · 1 Reply
  • 1 Reply
  • Lord Scales

    June 20, 2007 at 6:57 pm

    Try:

    A = thisComp.layer(“Audio Amplitude”).effect(“Both Channels”)(“Slider”); //the audio layer
    minScale = [60, 60]; //minimum scale
    maxScale = [80, 80]; //maximum scale
    linear (A, 0, 100, minScale, maxScale) //as A goes from 0 to 100, Scale value goes from minScale to maxScale in a linear interpolation

    Change the values as necessary. I tested here and worked fine.

We use anonymous cookies to give you the best experience we can.
Our Privacy policy | GDPR Policy