-
“DVD screeensaver” change color when bouncing off the wall
Hi everyone,
I’m trying to do a “DVD screensaver” via AE expressions. (Like this) I’m at the point when the bouncing works perfectly, but I don’t know how to achieve the “when bouncing change the color” thing. Actually it should pick a random value for Colorize Hue – I think – . It should work via expression, not by keyframes, because I want it to work with any comp size, and length.
Can anybody help me? Thanks ☺
Here is the position bouncing part below. The margins has been calculated from the DVD logo.hSpeed= 222;
vSpeed= 200;marginh = 76;
marginw = 175;cw=thisComp.width - marginw*2;
ch=thisComp.height -marginh*2;
x = value[0] - marginw + time*hSpeed;
y = value[1] - marginh + time*vSpeed;
x = x<0 ? -x : x;
x%=2*cw;
x = x>cw ? (2*cw)-x : x;y = y<0 ? -y : y;
y%=2*ch;
y = y>ch ? (2*ch)-y : y;[x,y]+[marginw,marginh]