ADOBE AFTER EFFECTS: Forum Expressions Tutorials Creative Cloud

Reset rotation each revolution

COW Forums : Adobe After Effects Expressions

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
Mikko Miettinen
Reset rotation each revolution
on Sep 15, 2017 at 12:43:12 pm

Hi
I´m trying to rotate a shape through expression so that on each revolution rotation value resets to 0. So basically I want a shape rotate only through 0-360 degrees and then reset to 0 degrees again and continue rotating. I don´t want to use keyframes and loop expression.

Thanks


Return to posts index

Dan Ebberts
Re: Reset rotation each revolution
on Sep 15, 2017 at 6:00:19 pm

Something like this maybe:

dur = 2; // rotate 360 degrees every 2 seconds
((time-inPoint)*360/dur)%360


Dan



Return to posts index

Mikko Miettinen
Re: Reset rotation each revolution
on Sep 15, 2017 at 6:28:21 pm

Hi Dan,
Thank you! You´re the boss! ☺ Could not get my head around this.

Mikko


Return to posts index

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