tyFlow Forum
tyParticleSkin filter by MatID - Printable Version

+- tyFlow Forum (https://forum.tyflow.com)
+-- Forum: tyFlow Discussion (https://forum.tyflow.com/forum-1.html)
+--- Forum: Feature Requests (https://forum.tyflow.com/forum-4.html)
+--- Thread: tyParticleSkin filter by MatID (/thread-1496.html)



tyParticleSkin filter by MatID - clasyc - 02-29-2020

I think it would be great if inside particle skinner there would be an option to filter out by particle Material ID. This is useful when single simulation will be used for separate objects to skin and if any of those objects are close edge to edge, particle skinner will be overlapping, causing artifacts.


RE: tyParticleSkin filter by MatID - tyFlow - 02-29-2020

Why not use the group filters already there? Smile Then you can filter in/out which particles you want, without having to change your particle material IDs.


RE: tyParticleSkin filter by MatID - clasyc - 03-01-2020

Damn you are right, missed these. The only concern is that the birth operator from surface allows assigning material ID from the original object. So all separate elements automaticly are ready with IDs. With groups i would need to make a lot of events (split them manually  and then assign groups(or is there a better way)).


RE: tyParticleSkin filter by MatID - tyFlow - 03-01-2020

Can you post a screenshot or something of your setup just so I can get an idea of how you want to split up your tyParticleSkins? Just so I can see if there's not a better way...

Also particle groups are just bitflags, so technically as long as your particle matIDs overrides are between 1 and 15, you could convert matIDs into groups using the Script operator with a line of code in your particle event for-loop like this:

Code:
tf.SetSimulationGroups(sInx, 1 << tf.GetMatID(sInx));

But I think if you've got a setup where matIDs are the most convenient way to filter particles for a skin, I could be convinced to add that as an option Smile


RE: tyParticleSkin filter by MatID - clasyc - 03-01-2020

(03-01-2020, 05:03 AM)tyFlow Wrote: Can you post a screenshot or something of your setup just so I can get an idea of how you want to split up your tyParticleSkins? Just so I can see if there's not a better way...

Also particle groups are just bitflags, so technically as long as your particle matIDs overrides are between 1 and 15, you could convert matIDs into groups using  the Script operator with a line of code in your particle event for-loop like this:

Code:
tf.SetSimulationGroups(sInx, 1 << tf.GetMatID(sInx));

But I think if you've got a setup where matIDs are the most convenient way to filter particles for a skin, I could be convinced to add that as an option Smile

Woah, I didn't think of this solution. I appreciate the help, the script will do this! Thanks!

Now I think the simulation group filter is enough for the skinner  Smile