Deform surface with attractor curve, making a surface from points

Hello there,

I’m trying to deform a surface with an attractor curve.
For that purpose I projected a curve onto the surface and then moved this projected curve away from the surface.
I internalized the base surface, the attractor curve and the vector (direction in which I moved the projected curve).

Now, for some reason many of the points which result from divide surface are Null. Can someone explain to me why that’s the case?

In the end I wanna make a surface out of the attracted points. But for some reason the origin is now part of my list of points and therefore I do not get the desired result.
I tried removing the origin by culling all indices where there was the point {0,0,0} and by replacing the origin with Null. Both didn’t work as expected.

Has someone here got an explaination for me why the origin is in my list of points and how I can solve my problem?surface from points.gh (25.5 KB)

That’s because your base surface is a “Trimmed Surface”.
I don’t fully understand what are you up to but, in this case, I usually do something like the attached…


Surface from points_re.gh (29.5 KB)

Thanks a lot! You solved my problem :slight_smile:

I have a follow up question.
This time I’ve split the attractor curve into three parts. I wanna control how much the middle part deforms the surface without getting those spikes at the curve transition points.
Do you have an idea how I can make it smooth? I think the problem is that points on the surface near those two transition points are effected both by the endpoint of the one curve and the start point of the other.
I need a rule to counteract this behavior.
Another idea is to do not split the curve in the first place but use a graph that rises to the first transition point, then plateaus to the second and then declines again.
Do you have an idea how to solve my problem?
deforming surface with a split curve.gh (29.7 KB)

I was able to solve it myself, see attached code.
But if someone has a more elegant solution, I would be glad to see it.

deforming surface with a split curve 2.gh (35.0 KB)

1 Like