Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions Changing random seed in a precomp.

  • Changing random seed in a precomp.

    Posted by Andrew Nelson on September 23, 2010 at 5:54 pm

    Hello all. I’ll try to keep this question simple.

    So, I have a precomp in my main comp. Inside this precomp, I’ve generated a timeless value, and plan to use it to remap a video in the comp to stick to a certain frame.

    Now, in the main comp, I’m duplicating this precomp, and I want to somehow make it so that each of the copys have a different seed value in them.

    Is this possible?

    Pete Burges replied 6 years, 3 months ago 4 Members · 4 Replies
  • 4 Replies
  • Kevin Camp

    September 23, 2010 at 8:06 pm

    i believe you would have to duplicate the precomp in the project window, then add it to the main comp… otherwise you’d have just one expression that you would want to have receive multiple variables, and i don’t see how that’s possible.

    but if you duplicated the comp in the project window, you’d then have a unique expression that could address a unique value for random seed.

    in this case something like this could work:

    seed=thisComp.name.split(” “);
    seedRandom(seed[seed.length-1],true)

    Kevin Camp
    Senior Designer
    KCPQ, KMYQ & KRCW

  • Dan Ebberts

    September 23, 2010 at 8:09 pm

    Not really. For them to be different they actually have to be separate comps in the project panel.

    Dan

  • Pete Burges

    February 12, 2020 at 4:51 am

    I have a related question: I am setting up an effect rig that will need to be copied multiple times across different comps. They all use Particular, which has it’s own random seed functions. Is there a simple expression I could use to alter the random seed value automatically for each comp? I tried this but it said ‘could not turn result into numeric value’.

  • Pete Burges

    February 12, 2020 at 5:06 am

    Aha- don’t worry I found it. seedRandom and then a random range did the trick.

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