Put solver Sim into slider ( infection)

   1714   4   1
User Avatar
Member
12 posts
Joined: Sept. 2018
Offline
Hi, guys so I was following this infection/spreading tutorial made by Fabricio Chamon and tried to incorporate his spreading technique into my own project. Everything actually works but now I would like to use a slider which will determine the progression of the infection instead of just playing the simulation. So my question here is, is there a way of not using the solver and create a slider that would play the simulation at each iteration instead? I tried doing it with a wrangler node but the issue here is that I cannot really understand what need to change? Since the solver node always watches the previous frame he takes all the data from previous frame and updates it. What I would like to update is just the infection so I could use the data. And have a slider that determines how many times he has to run the code so I can control and animate the progression to my liking.

I also posted what I have for now but had to put a Torus in it because my imported fbx file makes the hip file too big to post.

Thanks in advance for your help.

Sincerely,

Nawfal

Attachments:
Torus_Solver_To_slider_02.hipnc (169.2 KB)

User Avatar
Member
8177 posts
Joined: Sept. 2011
Offline
Do you mean animating the timescale? You can use the retime node to hand animate the progression of the simulation. You'll probably want to save out the full animation first before the retime.

See example

Attachments:
infection.zip (24.7 KB)

User Avatar
Member
12 posts
Joined: Sept. 2018
Offline
Not really animating the timescale, I want to use the data as alpha map so I could use it in my material network as alpha. The slider would be used to determine the progression of the “infection/transition”. I already tried with the timeshift node but it also takes animation with it which I don't want, I also tried exporting geo of first frame -> importing it back again -> applying the simulation on it -> making a second node network with animated object imported and attribute transfer the color from still geo to animated geo. I thought that by doing this I could control the infection on each frame but the reality is that my “alpha” is swimming through my geo which isn't what I want. Here is what I mean by “swimming”, don't mind the animation right now, the color is not actually sticking to the geometry, I ownder if it's because of the attribute transfer?

https://gyazo.com/69fc3384e89e57b9806713d0671c2afc [gyazo.com]
User Avatar
Member
8177 posts
Joined: Sept. 2011
Offline
I'm still not exactly sure what you want, but if you want the infection to be copied from the static geometry to the animated mesh, an attribute transfer is not what you want, since it uses a spatial mapping. Use an attribute copy to copy point to point.

Edit:
attached a file demonstrating attrib copy
Edited by jsmack - Oct. 13, 2019 16:42:01

Attachments:
infection2.zip (20.7 KB)
acopy_ramp.png (943.9 KB)

User Avatar
Member
12 posts
Joined: Sept. 2018
Offline
It works! My mistake was that I used attribute transfer instead of attribute copy and now I can control the transition at any point in my animation ! Thanks a lot jsmack !
  • Quick Links