I am trying to divide a curve into segments by using a scale factor. If for example my scale factor is set to 1.25 and the first line segment is from point (0;0;0) to point (1;0;0) then the next line segment will be from point (1;0;0) to point (2.25;0;0) and so forth.
What I’m aiming at is a parametric way of determining:
the number of line segments
the length of the last line segment
based on:
the length of the first line segment
the scale factor
the total length of the curve
I have been trying to figure this out for a while, but haven’t found any sensible solution yet. I have tried to write the idea out using standard Grasshopper components, which will hopefully make it clearer than the explanation above. I have no experience in writing code.
Hope it made sense and that someone may have a great idea with which I can move forward.
I made a python component that works as described ( I did it quickly so please test)
I’m short in time so I just drop it here without explanation, but if you have more questions just ask.
it is not code, but vanilla GH. The only thing that should be checked is the count in Series component so evaluated points go beyond end point of curve. On that purpose i have set large number of 100.
I’m not looking for code or anything like that, so standard Grasshopper is great
I have been fooling around for a while with a solution as you describe it. However, I would like to have a workaround in regards of the Series component, so that I don’t have to set any steps. What I’m looking for is a way for Grasshopper to determine the number of steps on its own based on start segment length, scale factor and total curve length. I guess setting a higher step number and then use a cull pattern to remove any segments above the total length is a solution for now.