Applying gradient to a grid based on distance from point

Hello!

I have been having trouble applying a gradient to a grid. I want the the colour of the gradient to lighten as you move away from the tensor points (As shown in the image) However the definition I have so far applies the gradient to the entire curve of the grid, irrespective of how close a point on the curve is to the tensor.
I have attached an image of what I have so far, my Gh definition as well as an image for how I would like it to look.

I hope someone can help me out :smiley:
Cheers!

ColorCurvesaccordingtoDistancefromPoint.gh (14.1 KB)

Have a try Pinch’n’Spread Points of pufferfish plugin. it’ll let you more control over the grid deformation than field components.



ColorCurvesaccordingtoDistancefromPoint_re.gh (17.7 KB)
2 Likes

Thank you! I Will check it out :smile: