Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions traffic light expression

  • traffic light expression

    Posted by Muna Waryanto on May 10, 2012 at 11:59 pm

    I would like to apply traffic light concept to control opacity of some layers, i prefer to control it by typing a number in slider control.
    eg. I have 8 layers
    type 10, the opacity of layer 1 is 100 and other layers are 0,
    type 20, the opacity of layer 2 is 100 and other layers are 0.
    Can you help me please..
    Thank you and have e great day,
    Muna

    Muna Waryanto replied 14 years ago 2 Members · 2 Replies
  • 2 Replies
  • Dan Ebberts

    May 11, 2012 at 12:32 am

    I’m not sure where your slider will be, so you’ll have to add that, but the opacity expression would look like this:

    s = (link to your slider control);
    if (Math.round(s/10) == index) 100 else 0

    Dan

  • Muna Waryanto

    May 11, 2012 at 7:01 am

    Thank you very much Dan.

    Muna

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