Creative COW SIGN IN :: SPONSORS :: ABOUT US :: CONTACT US
ADOBE AFTER EFFECTS: ForumAE BasicsAE ExpressionsTutorialsArticlesPodcastsMotion GraphicsTrainingCinema 4D

Script help.

Cow Forums : Adobe After Effects
Script help.
by reinstein on Nov 13, 2005 at 7:52:59 am

I am trying to create a graphic that has lines that hug the 4 sides of a box. So as it scales in either direction the lines move with it automatically. Go here for an example

http://www.ryan-turner.com/ae_files/lines_on_edge.mov

i did this one by just keyframing it.
So I was messing around with the position expressions of the lines.
i came up with these.

left line

temp = thisComp.layer("Royal Blue Solid 1").position[0];
[thisComp.layer("Royal Blue Solid 1").scale[0]*-3.6+360, position[1]]

Bottom Line

temp = thisComp.layer("Royal Blue Solid 1").position[1];
[position[0], thisComp.layer("Royal Blue Solid 1").scale[1]*2.7+270]

the other 2 are the same with negative numbers plugged in, so with these expressions, as i scale it, all the lines stay connected to the box.

So here is my question, is there a way to adjust the expression so that the lines will also follow the box if i move it around the screen. Right now it works great as long as the box is centered on screen. As soon as i move it the lines stay where they are.

Thanks

ryan

Respond to this post   •   Return to posts index

Re: Script help.
by Mike_S on Nov 13, 2005 at 11:03:38 am

What would be the drawback of "parenting" the lines to the box ..?

Respond to this post   •   Return to posts index

Re: Script help.
by Dan Ebberts on Nov 13, 2005 at 7:19:15 pm

You might find this helpful:

http://www.motionscript.com/expressions-lab-ae65/border-lines.html

Dan

Respond to this post   •   Return to posts index


Re: Script help.
by reinstein on Nov 13, 2005 at 10:57:25 pm

thats exactly what i needed. I looked for it on your site dan, but i guess i was looking in the wrong place.

Thanks

Respond to this post   •   Return to posts index

<< PREVIOUS THREAD   •   VIEW ALL THREADS   •   PRINT   •   NEXT THREAD >>


FORUMSTUTORIALSMAGAZINEDVDsBOOKSPODCASTSEVENTSSERVICESNEWSLETTERNEWSBLOGS

© CreativeCOW.net All rights are reserved.

[Top]