Dynamic Grid — Proportionally resizing tiles

Hey all,

When moving the line(s) of a grid, the sizes of the squares change. I have manages to make a 2D grid where I can move the lines about; however, I want to fill the squares which the grid makes with a colour. I have only found how to do this with the intersecting point of two grid lines, not within the actual spaces the grid makes.

Any ideas on how to do this? I am looking for dynamically changing rectangles in a grid where I can move the grid lines about.

I’ll link how far I’ve gotten below.


Dynamic_Grid.1.toe (7.7 KB)

Take a look at Mathew Reagan’s instancing examples tutorial; if you want to have unique colors for each square of the grid, I would try instancing a unique grid on each point of the grid to get you there.

You could then set the scale of the instanced geometry to dynamically size based on the number of points you have, with a modifier if you want some negative space between them to appear as the lines.