Grasshopper

algorithmic modeling for Rhino

How to group polygons according to distance from certain points and then sort them in 2D

Hi,

I have 64 outlines (closed polygons) of plan views of rooms and the outlines of their windows arranged in a grid (8 X 8). By following the GH definition of David (http://www.grasshopper3d.com/forum/topics/sort-mesh?) I have managed to sort the room outlines in 2D. What I'm trying now is to firstly group the windows according to the distance to the centroids of the rooms' outlines (http://formularch.blogspot.ch/2012/04/gh-distance-grouping.html) and then sort them in 2D as well. In this way, it will be possible to have the same index number for the room outlines and their windows (the same will happen later with doors, fireplaces, stairs, etc)

The problem is in that, the 2d sorting of the grouped windows doesn't seem to be working perfectly. I thought -and tried- different values in the distance parameters of the definition, but it doesn't seem to be solved.

Grasshopper crashes at the moment, so I can't export an image of the definition, but I'm uploading the files. Any help or advice would be welcome.

Thanks in advance.

Periklis

Views: 567

Attachments:

Replies to This Discussion

Hi Periklis,

If I get it right I believe you can achieve what you want without the windows 2d sorting group.

The thing is you have already sorted the outlines so if you use those for the windows' grouping you will be ok. Just plug  the sorted outlines into the Outline Crv container and it should work:

It seems that you're absolutely right. Great help, thanks!

RSS

About

Translate

Search

Photos

  • Add Photos
  • View All

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service