Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expression Order?

  • Expression Order?

    Posted by Ocean Byrne on July 12, 2011 at 6:32 pm

    I set up an expression to fade a bunch of 3d layers based on their distance from the camera, it works fine and all is groovy.

    then I set up an expression to position those layers based on a slider, it also seems to work, and is similarly groovy.

    EXCEPT – now the opacity expression doesnt work. It still thinks it’s valid, but the opacity is staying at 0?

    If I kill the position expression, the opacity works, is there some way I can specify to do the position 1st, and then think about opacity?

    Waa! ?

    Here are the expressions I have on every layer:

    Opacity:
    startFade = 1000;
    endFade = 111;
    L = thisComp.layer(“Camera 1”);
    d = length(L.position,position);
    if ( d > endFade )
    { linear(d,startFade,endFade,100,0) }
    else
    { linear(d,endFade,0,0,100) }

    Position:
    [1824,1368, (index-2) * thisComp.layer(“2008-11-07_19.02.19.jpg”).effect(“Slider Control”)(“Slider”) ]

    Any help would be much oblidged.

    Ocean Byrne replied 14 years, 10 months ago 2 Members · 2 Replies
  • 2 Replies
  • Dan Ebberts

    July 12, 2011 at 8:26 pm

    I think there must be something else going on. Have you verified that the position expression actually positions the layers where they should be visible?

    Dan

  • Ocean Byrne

    July 12, 2011 at 10:03 pm

    Huh, well that does seem to be the problem. Thank you sir.

    I zeroed out all the X’s and Y’s of the picture layers and the camera and it seems to work.

    I dont really understand though. Originally X was 1824 and Y was 1368 (center of the images)for all the layers and the camera, and the opacity expression worked fine. Once I added the pos expression though it went south.

    Functioning now though, weather I understand or not. Thanks.

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