Roofs: Difference between revisions

From Tygron Support wiki
Jump to navigation Jump to search
No edit summary
Maxim@tygron.com (talk | contribs)
No edit summary
 
Line 5: Line 5:


* The BAG building polygon is then divided into sections (garage, house, conservatory etc.). We calculate the standard deviation per section. If it is higher than a certain threshold and the model probably has a sloping roof (for example houses from the 1960s), we calculate a roof height attribute, which is the difference in height between the gutter and the ridge.
* The BAG building polygon is then divided into sections (garage, house, conservatory etc.). We calculate the standard deviation per section. If it is higher than a certain threshold and the model probably has a sloping roof (for example houses from the 1960s), we calculate a roof height attribute, which is the difference in height between the gutter and the ridge.
* We then use a ''Skeleton algorithm'' to determine the ridge of the roof. We include adjacent terraced houses (same construction date and height) so that you get a nice continuous roof ridge.
* We then use a ''Skeleton algorithm'' to determine the ridge of the roof. We include adjacent terraced houses (same construction date and height) to ensure a continuous roof ridge.


Based on the ridge lines and the gutter lines (polygon edges) we use a ''triangulation algorithm'' to build triangles which are needed for the 3D model.
Based on the ridge lines and the gutter lines (polygon edges) we use a ''triangulation algorithm'' to build triangles which are needed for the 3D model.
Line 13: Line 13:
* The color of the roof (based on aerial images).
* The color of the roof (based on aerial images).


The advantage of this calculation method is that it is completely procedural. You can easily make new buildings with it and give them a visual representation.
The advantage of this calculation method is that it is completely procedural. You can easily make new buildings with it and give them a visual representation. However it still remains an approximation of the roof shape.
A disadvantage is that it is an approximation and therefore not 100% accurate.


The location of the ridge is determined as being the center of the building and not directly based on the height data.
The location of the ridge is determined as being the center of the building and not directly based on the height data. This approach works for many common Dutch terraced houses, although deviations may occur with complex roof shapes.
This is adequate for many common Dutch terraced houses, but there may be a deviation, especially with more complex roof shapes.


{{article end
{{article end

Latest revision as of 07:36, 9 July 2026

The roof shapes for building sections in the Tygron Platform are calculated as follows:

  • Based on a BAG building polygon, we look at the DTM (height points every 50cm).
  • Then we use the Hough Line algorithm to recognize lines in the elevation data (https://docs.opencv.org/2.4/doc/tutorials/imgproc/imgtrans/hough_lines/hough_lines.html). These lines are often the division between higher and lower parts in the BAG building polygon. Think of a garage next to a house that is lower than the house itself. The advantage of these lines is that you get a sharp demarcation instead of fuzzy deviations in an inaccurate height model.
  • The BAG building polygon is then divided into sections (garage, house, conservatory etc.). We calculate the standard deviation per section. If it is higher than a certain threshold and the model probably has a sloping roof (for example houses from the 1960s), we calculate a roof height attribute, which is the difference in height between the gutter and the ridge.
  • We then use a Skeleton algorithm to determine the ridge of the roof. We include adjacent terraced houses (same construction date and height) to ensure a continuous roof ridge.

Based on the ridge lines and the gutter lines (polygon edges) we use a triangulation algorithm to build triangles which are needed for the 3D model. We also store the following data:

  • The outer walls (for insulation), but you cannot yet query them with TQL.
  • The different sections as separate polygons. Each section has its own building height and an estimated number of floors.
  • The color of the roof (based on aerial images).

The advantage of this calculation method is that it is completely procedural. You can easily make new buildings with it and give them a visual representation. However it still remains an approximation of the roof shape.

The location of the ridge is determined as being the center of the building and not directly based on the height data. This approach works for many common Dutch terraced houses, although deviations may occur with complex roof shapes.

See also