Grasshopper

algorithmic modeling for Rhino

Hi everybody, I´m a GH newbie, I´m trying to create multiple lines connecting random points on different curves to their closest point on other curves.
I thought that the best thing to do is to compare the z coordinates of the points, group them in branches and then connecting them to the lines, but how to do it?

I hope the image can explain better...

Thank you!

Views: 4144

Replies to This Discussion

Or you can use Curve CP, much easier.

Curve>Analysis>Curve CP
that´s what i tried, but i get all the closest points on the first curve..
The definition I´m working on is much more complicate than the image i posted so i cannot reference the points manually.
In which case I would say it probably has something to do with your data structures. Here is an example of the CP working with multiple points on multiple curves each with their own offset.

still not working.lines and points are in 3d, that shouldn't make a big difference, but it apparently it does..
Untitled-1.jpg
this is the definition i made, I know it is quite complicate but what i need now is just to get the lines from the green points to the upper lines... how can i do it?
Try this. A different aproach.
Attachments:
That's working! Thank you very much!

Now I have one last problem, concerning the shatter command. I want to split the curves where I just project the point according to the points itself... that's what i did, but it doesn't work and it splits only the first curve...

Try reparameterizing the c input of the shatter component.
(right click on the c input, and choose reparameterize)
Sorry but this is driving me crazy...
I try to reparameterize but i cannot get it anyway.
I have 1292 points that are on the curves I want to divide but what i get are 1256 curves on the highest point and 36 on the other positions. and they are not divided at all!
In the image you can see in green the end points of the result of the shatter.
What am i doing wrong?
Attachments:
This is to do with your data structures. Have a look at using the Param Viewer component to give you a look at whats going on with each input. Another good idea is to turn on fancy wires (from the view menu) this gives you a visual clue as to what the data streams are made up of. if you can post the 3dm and ghx files it might be easier to get to the bottom of this.

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