Hi everyone. I have trouble with the code I uploaded. I want to create lines inside a surface, without them sticking out or not filling the surface completely. I also want to be able to modify the lines’ angle using the centre of the surface as an axis. I tried to create a grid and create lines to make this possible, but I cannot get them to rotate following the border of the surface (a closed curve) as a path. Does anyone have any idea of how I can achieve it or if there is a better way to do this? I have read many topics on this forum with similar problems but nothing seems to work for me. Thanks a lot
HELP.gh (11.7 KB)
rotate_contours_2024Mar1a.gh (6.7 KB)
P.S. Oops, I forgot to rotate around the center.
rotate_contours_2024Mar1b.gh (7.6 KB)
1 Like
That’s brilliant! Thank you so much. Do you know if this can be used on any surface? Even non planar or irregular ones?
Not “brilliant”, just experienced. 
Yes, Contour will work on any brep, though you might need to change the center point detail. Perhaps use the center of a bounding box?
That works for me. Thanks again!
One more thing, I just noticed that the lines are generated from the centre of the surface. Is there any way to generate them from one of the surface’s edges?
Nevermind, I just figured out. I just changed the point parameter in contour to a point of the surface’s edge 
Yes, the Area ‘C’ (Centroid) that I added to my code can be changed to one of the vertices of the surface, or anywhere you like.
Hi again. I have encountered an issue regarding contour. I have noticed that the first line it generates isn’t located on the bottom edge of the surface, but at the designated distance between lines. Is there a way to force contour to generate the first line on the bottom edge of the surface without rotating the surface or the lines? Thanks!
Contour curves are aligned to the ‘P’ (Point) input, eh? So it can be wherever you want it.
But when I define one of the surfaces bottom points, the lines keep generating at a distance
rotate_contours_2024Mar11a.gh (10.9 KB)
You have all the information to answer your question.
11_03_24.gh (14.0 KB)
Even when establishing the bottom point it generates the line at a distance.
It’s an edge case (literally), deal with it!