Return-Path: Received: from mail-bk0-f41.google.com ([209.85.214.41] verified) by media-motion.tv (CommuniGate Pro SMTP 4.2.10) with ESMTP-TLS id 4710102 for AE-List@media-motion.tv; Wed, 09 May 2012 16:41:28 +0200 Received: by bkcjm19 with SMTP id jm19so358950bkc.28 for ; Wed, 09 May 2012 07:43:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:from:date:message-id:subject:to:content-type; bh=TIE/AMxfI+lID+dWwApZQc4YPUca6D7HBjw53FCKp0k=; b=GH9i86GmhHfHFbUZXEwXlmLn4u2ppjT+V3/8EEKRW7AUAvKFQM7yC5u3ATj9Jnnu5e nvd+Qw0TIohN4LA5+4iz3WPXMBgADKCUhjYWeXPkmElklq6Ck7if8mHUfD+j5LBnW/vf QjLAmSNk9QMjp0bdIrMfDJuXwTMiqTwDlnGkU2DqhFzbmFd470OdsNEYQTtIFfDdNYZA 07wUTeW22NZRfqZ6yGF1dosjrZFnh6IaPaVeHjxedY8yfsYB/x7gQr3emBvyKDH2nwu7 eGd0i0Ce1RfDvuZL9fjr5avjbAe26BxdoMGdVDKB1VMmV8GX7vIhMaNTrENd4yByh9CP hzGA== Received: by 10.204.152.203 with SMTP id h11mr101063bkw.122.1336574583890; Wed, 09 May 2012 07:43:03 -0700 (PDT) MIME-Version: 1.0 Received: by 10.204.232.81 with HTTP; Wed, 9 May 2012 07:42:43 -0700 (PDT) From: Byron Nash Date: Wed, 9 May 2012 10:42:43 -0400 Message-ID: Subject: Expressions: Decay after trigger To: After Effects Mail List Content-Type: multipart/alternative; boundary=0015175cabd849e20404bf9b85df --0015175cabd849e20404bf9b85df Content-Type: text/plain; charset=ISO-8859-1 I am writing an expression to bring the opacity of a layer up when it another layer comes close to it. I'd like to have it decay at a different rate than it builds. Here's what I have going on: o = transform.opacity; s = thisComp.layer("center").transform.scale[0]/100; //use the scale to affect the radius of influence of the null l = length(transform.position, thisComp.layer("center").transform.position); lprev = length(transform.position.valueAtTime(time-thisComp.frameDuration), thisComp.layer("center").transform.position.valueAtTime(time-thisComp.frameDuration)); if(lprev > l){ l = lprev; } o - (l/s); My attempt to look at the previous frame doesn't seem to be working. --0015175cabd849e20404bf9b85df Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable I am writing an expression to bring the opacity of a layer up when it anoth= er layer comes close to it. I'd like to have it decay at a different ra= te than it builds. Here's what I have going on:

o =3D transform.opacity;
=
s =3D thisComp.layer("cente= r").transform.scale[0]/100; //use the scale to affect the radius of in= fluence of the null
l =3D length(transform.position,= thisComp.layer("center").transform.position);
<= font face=3D"courier new, monospace">lprev =3D length(transform.position.va= lueAtTime(time-thisComp.frameDuration), thisComp.layer("center").= transform.position.valueAtTime(time-thisComp.frameDuration));
if(lprev > l){
=A0 l =3D lprev;
= }
o - (l/s);


My attempt to look at the previous= frame doesn't seem to be working.=A0
--0015175cabd849e20404bf9b85df--