Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions unpredictable valueAtTime proj

  • unpredictable valueAtTime proj

    Posted by Eric Sanderson on January 25, 2010 at 9:24 pm

    Ive uploaded my project since this would be a little complicated to explain. Basically i have a bunch of layers with some basic reference/offset expressions on them creating the effect you see. The problem came when i added a valueAtTime to the x,y…the layers are referencing each layer index-1 for Z space offset and index+1 for x,y since i want to animate the bottom one and have the rest above in layer order follow. But im getting unpredictable, inconsistent results…almost a different result in each playback, some will follow one time but stop following a few layers up, some positions are just offset completely wrong.

    “Layer 15” has the key frames on it, so when i scrub before the keyframes and play from there youll see the different results im talking about. Thanks for the help as always.

    link to file: Project file is AE CS4

    500_archive.zip

    Dan Ebberts replied 16 years, 3 months ago 2 Members · 3 Replies
  • 3 Replies
  • Eric Sanderson

    January 25, 2010 at 9:52 pm

    well i found a work around for now by adding a transform effect and doing the animation there instead but would still like to know what made it all screwy.

  • Eric Sanderson

    January 25, 2010 at 10:33 pm

    So scratch my last quick work around…it voided my lights in the scene…still lookin for a fix to either still the valueAtTime issue or maintaining my 3d layers attributes with any transform effect on the layer

  • Dan Ebberts

    January 25, 2010 at 10:53 pm

    My guess is that you’ve created a dependency loop where Layer A’s positon depends on Layer B’s position which refers back to Layer A’s position, etc. As you’ve observed, the results are unpredictable.

    You’d be better off basing your calculations on the index difference between the layer with the expression and a master layer, something like this:

    indexDiff = Math.abs(thisComp.layer(“Master”).index – index);

    That gives you a value proportional to how far away in the layer stack this layer is from the master. Then just use that in your calcs to get the graduated/time delayed effect you’re after.

    Dan

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