Jump to content

Why fit expression work to reverse scrolling ?


lzoper

Recommended Posts

Hi Izoper.

I think the reason is

Attrib liff == $AGE*24. When $VY becomes zero $AGE doesn't remain constant it keeps increasing.

if($VY == 0,fit($FF,$LIFF,$LIFF+24,0,180),0)

so in the above expression $LIFF is not a certain fixed number but keeps on changing as you play on that is why it is not working.

As you are using POP when you play reverse there is no change in output unless you reach first frame, POP will reset then. As there is no change in values of LIFF (refer the detail view) while playing reverse you expression is working as LIFF values are constant.

One of the solution is to find out max ty pos of each particle when frame no is equal to $NFRAMES, you can use timeshift sop for this.

and create some attrib with value equal to

$TY/point("ADDRESS of timeshift node",$PT,"P",1) - this value will change from 0 to 1. Multiply this by 180 to get 180 degrees rotation and stamp this value in the rotation of the box.

Edited by sadhu
  • Like 1
Link to comment
Share on other sites

Hi Izoper.

If you write $NFRAMES in timeshift sop it will give you the output of the last frame irrespective of which frame currently you are on(assuming that particles would have reached max ty pos by then). By the last frame particles would have reached their rest position so even if you are on frame 1 you can access the output of last frame by timeshift sop .

1)Apply timeshift node after pop and write $NFRAMES in it(or any frame no by which all the particles have reached their rest pos).

2) Connect attrib create sop after pop (dont connect after timeshift, create seperate chain from pop), name of attrib - test

3) Value of this attrib - $TY/point("ADDRESS of timeshift node",$PT,"P",1)

4)$TEST will change from 0 to 1. Multiply it by 180

5)Create stamp variable using test attrib and stamp this value in the transform node after the geometry you want to copy.

Edited by sadhu
  • Like 1
Link to comment
Share on other sites

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...