cartagen.amalgamate_buildings#
- amalgamate_buildings(building1, building2)#
Amalgamate two buildings by computing their most compact junction.
The amalgamation algorithm was proposed by Nicolas Regnauld [1] (pp. 150-154). The algorithm is based on the edges of the convex hull that join both buildings. The algorithm chooses the links that create the smallest joined polygons.
- Parameters:
- Returns:
See also
amalgamate_buildings_morphologicalAmalgamate multiple close buildings.
References
Examples
>>> buildings = [Polygon([(1, 0), (9, 0), (9, 6), (1, 6), (1, 0)]), Polygon([(10, 0), (17, 0), (17, 6), (10, 6), (10, 0)])] >>> morphological_amalgamation(buildings, 1.0, 1.0) <POLYGON ((1.207 1.983, 2.547 5.885, 16.768 4.282, 15.42 0.148, 1.207 1.983))>