afx Posted March 10, 2009 Share Posted March 10, 2009 How would I get an expression to evaluate every 3 frames?? Probably an easy answer, but i must overlooking something in exhelp. Quote Link to comment Share on other sites More sharing options...
anamous Posted March 10, 2009 Share Posted March 10, 2009 depends. which context, POPs, SOPs, ..? if your expression is frame-dependent (meaning that it uses the $F variable), it's pretty easy using the modulo operator. Just use ($F - $F%3) instead of $F. this will make $F increment in steps of 3 frames instead of every frame (0 0 3 3 3 6 6 6 9 9 9 etc.). If you need it to increment by 1 every 3 frames, use (($F - $F%3) / 3) instead of $F - the resulting sequence will be (0 0 1 1 1 2 2 2 3 3 3 etc.). cheers, Abdelkareem 2 3 Quote Link to comment Share on other sites More sharing options...
afx Posted March 10, 2009 Author Share Posted March 10, 2009 (edited) Dude awesome thanks, that worked perfectly. I was going about it all the wrong way. I created a attribute create with a module in the first variable and then inputed that into an if() and was going by it that way. Now what is the difference between $FF and $F? That might of been my issue also. Edited March 10, 2009 by Angelo 2 Quote Link to comment Share on other sites More sharing options...
anamous Posted March 10, 2009 Share Posted March 10, 2009 $F is the current frame number as an integer (1 2 3 etc.), whereas $FF is the current frame as a float. $FF is important for certain effects (think particles or DOPs), and for correct motion blur and time shifting/stretching for example. cheers, Abdelkareem 1 Quote Link to comment Share on other sites More sharing options...
ykcosmo Posted March 11, 2009 Share Posted March 11, 2009 (edited) $F%3 == 0 or use : if($F%3==0, stateA,stateB) have fun:) Edited March 11, 2009 by ykcosmo 2 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.