Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions convert value increase to decrease

  • convert value increase to decrease

    Posted by David Wiffen on January 24, 2011 at 10:44 am

    Hi Everyone,

    I have a null scale value increasing from 100% to 700%.

    All i want to do is pickwhip the value and turn the value around so 100% = 100% and 700% = 25%.

    So basically as the driver null increases in size another driven null decreases with the ability to adjust the value ranges.

    Many thanks for any help!!

    David Wiffen replied 15 years, 3 months ago 3 Members · 3 Replies
  • 3 Replies
  • Darren Chappell

    January 24, 2011 at 1:14 pm

    Will the following expression work . .
    linear(value,a,b,c,d)

    a=your observed min val
    b=your observed max val
    c=your proposed min val
    d=your proposed max val

    therefore, this should be good for you = linear(value,100,700,100,25)

    linear(value,100,700,100,25)

  • Dan Ebberts

    January 24, 2011 at 4:18 pm

    Assuming that your layers are 2D and uniformly scaled, this should work:

    s = thisComp.layer(“Null 1”).transform.scale[0];
    linear(s,100,700,[100,100],[25,25])

    Dan

  • David Wiffen

    January 24, 2011 at 5:36 pm

    thanks guys – will give it a try and post back 🙂

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