Split any shape into rectangles

Hello
you have surely not tested every thing, the idea is there from some of the scripts.

and mine I didn’t post

But the logic of the 2 are the same. Make perpendicular curves and the start/end of line curves.


But it works less well here

Some logic must be added, depending on type of curve (linear), obtuse acute angle …
Then when rectangle are found, it will be also possible to join some of them.

Gilbert Tessellation will be on Nautilus plugin, but you find it is some discussions
Split shape into rectangle.gh (16.1 KB)

Other logic could be implemented. For example find 2 consecutive right angle which mean that a rectangle could surely be found. Doing that with some recursion could help to cut the shapes. It requires time and/or money to develop this kind of tool.