Hi
I have a model wich I fractured with the standard Voronoi workflow, then I created a primitive attribute called “toDel” wich can be 0 or 1.
The purpose of this attribute is that it must be set to 1 for those polygons who are part of a piece of the original fractured model, that has a volume smaller that a certain value, and 0 if greater. (1 means it will get deleted, 0 will be kept)
So to set the “toDel” attr I created a foreach running over each piece of the fractured model by using the name attributed created by the assemble sop, then inside it I measured the volume with the measure sop, then converted it to a detail attribute with the “sum” option , so I get the volume of the piece Im currently iterating on.
After that I used an attribute vop to check if the volume is greater or smaller than a certain value, and based on that with a two way switch I set the attribute to be 1 or 0.
The problem is that it always stay at 0…is the first time for me attempting to set an attr value inside a vop, so maybe Im doing something wrong.
See example scene below.
Thank you
Setting attribute based on volume
1422 2 1- SteN
- Member
- 55 posts
- Joined: March 2015
- Offline
- friedasparagus
- Member
- 402 posts
- Joined: June 2014
- Offline
Hi Stefano,
it looks like there's just a couple of hitches with that attrib VOP… make sure you're running over primitives, not points. Next, in the ‘Set Attribute VOP’, make sure you've hooked up the ‘i1’ input to the incoming primitive number. If you use the ‘bind export VOP’ it will automatically set the attribute on the current primitive, but the ‘Set Attibute’ needs a bit more information,
Hope that helps
it looks like there's just a couple of hitches with that attrib VOP… make sure you're running over primitives, not points. Next, in the ‘Set Attribute VOP’, make sure you've hooked up the ‘i1’ input to the incoming primitive number. If you use the ‘bind export VOP’ it will automatically set the attribute on the current primitive, but the ‘Set Attibute’ needs a bit more information,
Hope that helps
Henry Dean
- SteN
- Member
- 55 posts
- Joined: March 2015
- Offline
-
- Quick Links