Original Post
Hi I have a large set of arbitrary rectangles and I have to test them all against a given rectangle for collision FAST. Does anyone know an efficient data structure and/or algorithm to do this? I want to avoid looping thru the whole rectangle database, so they have to be sorted somehow. Dividing the whole region into subregions would be one solution, but I wonder if there are other solutions that lead to near-logarithmic complexity.