Grasshopper Intensity Patterns - Squares filling an curvilinear area and changing intensity and size

Hello everyone,
I’m trying to get square pattern generated across a curvilinear surface.
The intention is to be able to vary the size of the square and the distance between each square at every curve.
See the attached image that may be of help clarifying what I mean.
Thanks for the help in advance.