Grasshopper

algorithmic modeling for Rhino

Hello guys!!!

I need help!

I want to move the selected points of the curve to their relative surrounding points in a random way.

The catch is that I need to move them and not copy them with the "move" button. The goal is to deform the curve by moving the points

Thanks in advance!

Views: 1947

Replies to This Discussion

anyone???

Hi Georgios..It's generally easier to answer questions when you also post a definition/rhino file.  But without your definition, first you should know that while it's possible using a script component to actually transform geometry in rhino, that's really the only way that you're going to be "moving" any points using grasshopper, and it is not only a bit difficult, but there are all sorts of issues that go along with it.  What you actually want to do is in fact use the "move" component in gh, which then creates new instances of your input points, and then use those moved points to rebuild your curve.  Whether you're using control points or interpolating a curve through points - the details of how you reconstruct your curve - is really up to you.  But grasshopper primarily works as a means to "remember" the history of objects, and that invariably means desconstructing components, duplicating them, and recombining them to achieve new forms.

thank you for your answer david but to be honest you dint tell me smth new!

here is the gh file!

If iI reconstruct the curve I loose all these mid movements the curve is doing!

thank you very much. If you can give me any further hint based on the gh file I post I would be grateful

Attachments:

well...with your base curve so complex, it will be fairly difficult to actually interpolate the points you'd like to adjust through your adjustment points.  But you can replace control points from your base curve with them, and increase their weighting when rebuilding to get them very close, all the while retaining the continuity of your curve elsewhere.  Basically this definition identifies the control points closest to your adjustment points, picks from your adjustment points randomly at each segment, and replaces the control point with it.  You have the option to increase their weighting as well.

For simplicity I wrote a little script to renumber your paths in order to make the data matching simpler (I didn't really delve into your setup in order to try to fix it upstream).  If you like, you could also install tree sloth which has a renumber paths component in it.

Attachments:

Sorry I don't have it installed...you can reconstruct my solution from here:

The vb component is incredibly simple.  Just put one on the canvas, double-click it to open it up, and then past this into it in the white space between the Private Sub and End Sub lines.:

x.RenumberPaths
A = x

David, what can I say...

Thanks a million!!! It's not exactly what I was looking for but it surely shown me the way on how to continue...!

no worries...also just realized that in the vb component you'll have to right-click on the "x" input and select "tree access"...

RSS

About

Translate

Search

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service