generative modeling for Rhino
thanks, but that works for voronoi in box...
I have already selelcted group of cells from voronoi (which fit in some other envelope) and now i want to divide them in to this two groups. B form voronoi would be ok if i can get it from colection of cells.
Please give me another hint
"Skin" cells or "skin" surfaces ? (something like naked surfaces ?)
I want to divide cells in two groups;
cells which have contact with exterior (at least one wall create skin surface)
cells which are inside no contact with exterior
(to get skin surface is relatively easy solid union make the trick- unfortunately indexes are lost in the process)
I know. boolean are not inteligent at all...
Thank you so much i am testing definition now. few tricks like mass addiditon wich didint know. thanks for a lesson man.
this is a great method for this, I am confused by it tho, can you explain in a bit, I am kind of lost after closest point. You are grouping in twos each points closest two points. Then adding the two distances, Then path mapper to put back into the original face list structure. Then adding those distances together? I'm lost there, if I am even correct at all. Thanks in advance.
Each point represents center of face. faces touching each other have same center point (thats one of marvelous properties of voronoi diagram).
So there are some points in given point cloud that share same location (pairs with 0 distance between). to find these pairs we need to get closest point in point cloud for each point. to make it easier lets use closest points component, and find 2 closest points for each one (one point itself and other - potencial pair).
Closest points gives us data tree with distances (cp output D), where each branch contains 2 values - 0 for point itself and 2nd distance for potencial pair. next add these two values - it should give some value greater than 0 (what means there is only one point at that location) or equal to 0 (if point shares location with other guy)(tolerance needed due to really small values like 1.9e-15 which for us = 0).
Now we can tell that each point has some information about neighbours. Going back to faces - we can tell that face is 'naked' or 'clothed' - if its center point has pair in same location it means face is clothed, if its alone its naked.
Next we use path mapper to add all values from faces from each cell (path mapped ->mass add). Now if all faces are clothed, than adding all values should give 0, which means cell is clothed. If this value > 0 than cell is naked.
THE END :D
100 percent understand now, if the cell is fully enclosed then the sum of that entire cell is 0, really smart method. Thanks.
This method is really close to one used in "skeletal mesh" approach, where 'pairs' with 0 distance are used to identify neighbour cells.