-
Needs of cycle or reset expression for an offset (Roughen Edges)
Hi, I have this scenario:
I have a simple bar made with a box Shape layer. To get fancy i added a Rough Edges effect (RE).
Then i animated the height of my box but the RE remains static, so no problem, i linked by expression the Y Offset of the RE to the height of the box, and works great, it gives the illusion of move accordingly to the growth of the bar.
The problem came when i noticed that the RE has an offset limit of 32000 pixels, so when the height of the box exceed this amount (and it does by a lot), the RE stop moving, losing the illusion.
So, my idea to solve it, is to get a kind of expression that reset the RE offset every time the height’s box gets 32000 or a multiple of it, and start from zero again but still linked to the growth of the bar. I think that this can still maintain the illusion of movement.
So if you could help me with this expression or with another solution, i will apreciate.
//code to link RE Offset to box heightx = value[0];
L = thisLayer;
y = L.sourceRectAtTime(time-L.inPoint).height;[x,-y*5];