ADOBE AFTER EFFECTS: Forum Expressions Tutorials Creative Cloud

Expression to randomise color value for an 'x' amount of time in the course of an 'x' duration amount.

COW Forums : Adobe After Effects Expressions

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
Nitin Burli
Expression to randomise color value for an 'x' amount of time in the course of an 'x' duration amount.
on Feb 21, 2017 at 7:37:18 am

Hi,

My light has a colour value 'x' that I need to change randomly every 5 seconds. I'm looking for an expression that allows me to seed color value, as well as the amount of duration it exists for. Also, can it stick to the initial shade that is provided?

This would truly sort out a lot of work for me. Please let me know if an expression for this is possible, and if so, I'd like it if someone could come up with one :D.

Thank you.

Mr. Burli


Return to posts index

Dan Ebberts
Re: Expression to randomise color value for an 'x' amount of time in the course of an 'x' duration amount.
on Feb 21, 2017 at 1:49:10 pm

Maybe something like this:

seedColor = [206,146,20,255]/255;
dur = 5;
seedRandom(Math.floor((time-inPoint)/dur),true);
hsl = rgbToHsl(seedColor);
newH = random();
newS = random();
hslToRgb([newH,newS,hsl[2],1])


Dan



Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2017 CreativeCOW.net All Rights Reserved
[TOP]