Jump to content

Cloth generation from particles copy sop


merlino

Recommended Posts

Hi!

I'm trying to create a leaves generator to attach to a fluid simulation and I'm doing this way:

Create a particle system, create the geo (planes) with the copy sop, import it as cloth and then make it work with the existing pyro simulation. It work well, but I have a problem: I can emit particles just the first frame, otherwise the cloth give me an error, as the initial geo has changed. How can I emit particles/geo on every frame I need? Other point: is there a way to pass the particles ID info to the cloth object, so I can vary the mass attribute per object?

Link to comment
Share on other sites

For the second point, about the particle ID, you can check `Use Template point attributes` to transfer id to each copy. attribute promote the id from point to prim. Attribute create class primitive `surfacemassdensity` with a value like this ie: fit01(rand($ID),1,5).

I think it should work

  • Like 1
Link to comment
Share on other sites

For the second point, about the particle ID, you can check `Use Template point attributes` to transfer id to each copy. attribute promote the id from point to prim. Attribute create class primitive `surfacemassdensity` with a value like this ie: fit01(rand($ID),1,5).

I think it should work

Many thanks Dominik! I'll make a try as soon I'll be back on that effect (possibly this week)

Link to comment
Share on other sites

It's not working yet, hope that someone could check I've link a file and tell me what wrong :).

I've modified the cloth object - creation frame, number of object and object name channel

I've also modified the prim group channel of the sopgeo initialgeometry node inside the cloth object otl.

But when I modify the prim group, It give an error for the initialpid attribute. Look like the cloth solver does create the attribute needed at the creation frame...

I'm sure that I'm the problem and I'd be happy to know how it can be achieve.

Doum

multiple_cloth_leaf_v01.hipnc

  • Like 1
Link to comment
Share on other sites

Hi Doum! Maybe my approach to the problem was the wrong: and I found this blog really interesting

http://ihoudini.blogspot.com.ar/

Especially this post:

http://ihoudini.blog...-paper-sim.html

It does exactly what I was looking for and give us a hip file! :)

Really many thanks to the blogger!

And thanks to you to for your interest Doum, I hope this could help you too.

Now it's time to carefully understand the file!

EDIT:

Actually the blogger is Sam Hancock, so: thank you Sam!!!

EDIT 2:

My first problem was add cloth geo from the copy/pop generator. I found that my error was to leave all the particles generated from the pop network, so the solution was delete the particles with more than one frame of life. In order to do that you can give a name to the Birth Group, in the Source node, and after the pop network blast the particles outside the Birth Group.

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

Actually not that part of his solution. I generate particles with the pop and then leave only the ones emitted in that specific frame. Than, in the Cloth Object node, as cration frame I put an expression like if($F < 24,$F,0) so it crate cloth objects on every frame till F23. This way you can always cache the points after the blast node and plug a read node to the copy node (if is necessary).

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...