How To Find Open Spaces Given List Of Rectangles

44 Views Asked by At

I am trying to find the open spaces given list of rectangles. So a base rectangle of a given size has rectangles placed down on it covering space the now open spaces that are not covered by the recently placed rectangles make new rectangles I am trying to find those.

I want to create an algorithm to find those open space rectangles. Any pointer would be greaterly appreciated.

Below are some examples I am trying to reproduce algorithmicaly.

First example:

enter image description here

Second example:

enter image description here

Third example :

enter image description here

0

There are 0 best solutions below