Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions Using Checkbox to Invert a Value

  • Using Checkbox to Invert a Value

    Posted by Gabriel Ferrão on September 11, 2014 at 9:29 pm

    Hi there,

    if got this expression going, and I’d like to invert the value of ‘s’ with a checkbox.
    How would I go about doing that?
    Thanks!

    s=thisComp.layer("SOUND KEYS MASTER").effect("Sound Keys 1")("Output 3")*effect("strength multiplier")("Slider");
    x = effect("min scale")("Slider")+s;
    y = x;
    [x,y]

    Dan Ebberts replied 11 years, 8 months ago 2 Members · 1 Reply
  • 1 Reply
  • Dan Ebberts

    September 11, 2014 at 10:18 pm

    Just add something like this after your definition of s:

    cb = effect(“Checkbox Control”)(“Checkbox”).value;
    if (cb) s = -s;

    Dan

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