Grasshopper

algorithmic modeling for Rhino

Hello All, 

I am working on a project where I need to trace vectors from the 3d point grid and check for intersection with surrounding meshes. I tried using the Mesh | Ray intersection component, but it doesn't work the way I expected. Basically not all rays and collision points are being detected. Any help would be appreciated. GH file attached. 

Apoorv 

Views: 3255

Attachments:

Replies to This Discussion

Hello

i am trying to undestand what you are after.

you have 360 mesh vertices where you have 6 direction vectors starting from each mesh vertex?

Hi Alex, 

Sorry for not being clear on this. Yes, I have 360 mesh vertices, and essentially I am plotting solar vectors for 7 hours at each vertex. I want to see which of these 7*360 vector are blocked by the meshes around. ( and eventually get rid of those). 

Hope this helps. 

Apoorv 

Hello Apoorv

with mesh ray component i cannot have the data structure that could be usefull for culling the lines. so i tried another way.

i used physucal brep curve intersection to find intersection events between the lines and all the breps (buildings). this component outputs points so with trim tree and list length component you can get to a tree with the same structure as the tree of lines (7 branches with 360 items in each). this new tree has the list lengths of the intersection points.If list length is zero then the line does not intersect anyt brep etc.

hope that helps.

cheers

alex

Attachments:

Alex

This is perfect! thank you so much!

Cheers! 

Apoorv 

Alex, 

thanks again for the help. I am using this method, however the intersection component takes a long long time to process the geometry. I have a lot of lines and breps/meshes in the definition. I was wondering if there is any way to make this faster? 

Apoorv 

using other components i believe would end up the same time of calculation in the end, although i am not sure since i did not try another definition.

maybe this could be a solution but cant help you with that.

cheers

alex

Hm, Ya I am considering python as well. Will have to learn this. Thanks for your help anyway! 

Hi Apoorv,
Check attached file, for multithreaded example (increases the speed 7 times on my Intel Core 2 Duo 1.8GHz).

Attachments:

some djordje magic! 7 times! i hope GH2 is multi thread.

Well I should have said that I used a different method: RayShoot, and not CurveBrep which is what grasshopper's Brep/Curve component uses. In that case the speed would probably be (only) two times faster, at least on my PC.

David mentionedcouple of times that he might try to implement multithreading for GH2 components.

THANK YOU SO MUCH! I will test it out and let you know! 

I am a newbie in this..but I was thinking if using a mesh instead of brep would make it any better? 

RSS

About

Translate

Search

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service