Groups > Multimedia > Adobe After Effects expressions > Re: make duration of comp 1 = duration of comp 2




make duration of comp 1 = duration of comp 2

make duration of comp 1 = duration of comp 2
Mon, 14 Jan 2008 10:19:23 -080
I found the comp attributes and methods section in the help file, but of course
as usual it doesn't say anything about how they could be used.

First, I don't know where you apply an expression to an entire composition.
I tried just adding the expression to a layer, but that didn't work.

I tried doing this, but figured it wouldn't work. And no suprise, it didn't.
thisComp.duration = comp("Comp 2").duration

I figured you could add one expression to a single attribute to control many
attributes. Is this not so? If I want to control the position, do i actually
have to write that section of the expression after the position attribute of the
layer? I thought if I was effecting position and scale I could put them together
somewhere. Can you tell I'm a little new to this?

I have a bunch of compositions and I would like to change one later that will
change the times for all of them at the same time.

Post Reply
Re: make duration of comp 1 = duration of comp 2
Mon, 14 Jan 2008 13:25:19 -080

      First, I don't know where you apply an expression to an entire
composition.




You can't.

      I figured you could add one expression to a single attribute to control
      many attributes. Is this not so?




Nope. An expression can only control the property to which it is applied.

      I have a bunch of compositions and I would like to change one later that
      will change the times for all of them at the same time.




You'd need a script for that. It wouldn't be too tough, for example, to write
one that made the duration of all other comps the same as the one you have
selected in the project window. But you'd have to run the script whenever you
changed the duration of your master comp - the others wouldn't update
automatically.

Post Reply
Re: make duration of comp 1 = duration of comp 2
Mon, 14 Jan 2008 18:35:13 -080
setInterval("Duration_equ()", 5000);

function Duration_equ()

{

......

}

===========

Every 5 sec , it'll execu the function duration_equ

but ,it'll execy forever~~~

Post Reply
about | contact