4

I have a set of detached building polygons and I can merge them together in order to form a single building polygon. However, when merged output polygon may not preserve the orthogonality of building sides depending on the orientation of the original detached polygons.

In order to make the sides of merged building orthogonal, is there any open-source building squaring algorithm/ tool?

Kadir Şahbaz
  • 76,800
  • 56
  • 247
  • 389
Sanjeewa
  • 660
  • 4
  • 17
  • This is a follow on question to this question:http://gis.stackexchange.com/questions/24428/aggregate-detached-polygons The first answer to that question directly addresses orthogonal vs non-orthogonal datasets. – Get Spatial May 11 '12 at 09:30
  • Please follow up on your previous question instead of opening a duplicate. – underdark May 11 '12 at 09:50
  • Is it really a duplicate? This question asks for a squarring algorithm, while the other one is for an amalgamation algo. – julien May 11 '12 at 09:52
  • Yes, this is not a duplicate question. You can see the result of the aggregation of a set of buildings into one building with orthogonal option does not preserve orthogonality. – Sanjeewa May 11 '12 at 09:57
  • 2
    If I understand the question correctly, the first answer to the previous question addresses orthogonal merging it already. It seems necessary to explain how this is different, probably with a sketch. – underdark May 11 '12 at 10:02
  • I think if you look at the example of the aggregated result of the set of buildings it is obvious that it has sides that are not orthogonal. – Sanjeewa May 11 '12 at 10:08

2 Answers2

4

There is such polygon squaring algorithm in the JGiscoTools java lib. Have a look at the class Squarring of the algo module. This algorithm is quickly described in this paper.

Good luck!

julien
  • 10,186
  • 6
  • 55
  • 93
  • Hi Julian, More details of the paper? Is it published? I need to cite it. – Sanjeewa May 11 '12 at 17:29
  • 1
    @Sanjeewa, since the link that was provided to the paper is from a conference, and the path references proceedings, it is at least published in one form, though maybe not a journal. As for other details, the entire paper is in the linked pdf, with contact info on the first page and references on the last. You should be able to cite it based on the information contained therein. – Get Spatial May 11 '12 at 17:58
4

There is also a QGIS 3.x tool (Orthogonalize) orthogonalises line or polygon-shaped geometry. It depends only on an angle tolerance.

enter image description here

Kadir Şahbaz
  • 76,800
  • 56
  • 247
  • 389