generative modeling for Rhino
Tags:
Permalink Reply by Michael Pryor on May 13, 2012 at 7:25am
Permalink Reply by Karol Wawrzyniak on May 13, 2012 at 2:24pm 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
best,
karol
Permalink Reply by Mateusz Zwierzycki on May 13, 2012 at 3:10pm "Skin" cells or "skin" surfaces ? (something like naked surfaces ?)
Permalink Reply by Karol Wawrzyniak on May 13, 2012 at 3:19pm Mateusz,
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)
best,
k
Permalink Reply by Mateusz Zwierzycki on May 13, 2012 at 3:37pm
Permalink Reply by Mateusz Zwierzycki on May 13, 2012 at 3:45pm
Permalink Reply by Karol Wawrzyniak on May 13, 2012 at 3:53pm 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.
k
Permalink Reply by Michael Pryor on May 13, 2012 at 4:38pm 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.
Permalink Reply by Mateusz Zwierzycki on May 13, 2012 at 5:09pm 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
Permalink Reply by Michael Pryor on May 13, 2012 at 5:31pm 100 percent understand now, if the cell is fully enclosed then the sum of that entire cell is 0, really smart method. Thanks.
Permalink Reply by Mateusz Zwierzycki on May 13, 2012 at 5:38pm This method is really close to one used in "skeletal mesh" approach, where 'pairs' with 0 distance are used to identify neighbour cells.
Added by Mgeorgio 0 Comments 0 Likes
Added by Mgeorgio 0 Comments 0 Likes
© 2013 Created by Scott Davidson.
Powered by