I am trying to move the control points of a curve in x and y direction so I can make it more irregular, but something went off and I am having a lot of points in the 0,0,0 while my curve doesn’t close properly.
I want to be able to move the points in x and y cordinates but having a single graphmapper to each one.
There are many things here that don’t make any sense to me.
The Sub List output is identical to its input so what’s the point?
The output of Range is only a series of integers 0 to list length, which has one more value than the number of control points. The bounds of those values (0 to 26) must be remapped before connecting it to Graph Mapper. Normally that would be 0 to 1 but has been reconfigured to a non-standard domain.
You are remapping the Graph Mapper output for X but not for Y.
Don’t change the default domain of Graph Mapper, remap to and from it instead.
P.S. One of the most essential keys to mastering Grasshopper is to examine and understand both the values and data tree structure going into and coming out of all components.
I’m sorry my words are apparently not helping. This bit of code distills what I was trying to say and show the correct way to use Graph Mapper(at least the way I use it). The values from Range you are using though, (0 to 25) still make no sense to me.
On two occasions I have been asked, “Pray, Mr. Babbage, if you put into the machine wrong figures, will the right answers come out?” … I am not able rightly to apprehend the kind of confusion of ideas that could provoke such a question.
I started to look at this, but I don’t understand the desired behavior by reading the extremely brief explanation of the desired output, so I’m unable to help. Maybe if you can more clearly describe how you expect the points/curve to behave then people will be empowered to help to solve your problem.
Sorry, I want each unit of the control points to move in y and x directions, but not in a big range so it will distort the curve. all i want is to “rebuild” the curve as a more irregular one by moving the position of the control points but not all of them in the same time.
Hi, I guess you are mixing two things here. Arranging controlpoints doesn’t make curve to follow the same shape. What you want is probally something different.
A.) you subdivide the curve into a equally spaced list of points and then you move them. After that you basically just interpolate them, with the disadvantage of having a very heavy Nurbs. So some sort of reapproximation/refitting/rebuild would benefical to reduce the amount of cps after doing that.
B.) you use the Greville points instead and move them. You then need to interpolate them, ideally with a ‘DeBoor-In-Reverse’ (which is not accessable from Grasshopper) or with the more generic Interpolation method. This way you could skip the refitting, but it likely does not result in the disered shape anyway. So you definitly should go for approach A.). GH has all the tools you need for this.
If you look carefully, you’ll see three control points that have two white lines each instead of the expected one. That’s because your curve has three duplicate control points, as seen in the purple group. An argument can be made that those duplicate points should be moved together instead of in different directions and distances?