OSM-4D/Roof table

From OpenStreetMap Wiki
Jump to navigation Jump to search

This page was created by: Marek Strassenburg Kleciak, Kendzi

This page collects a list of 3D roof forms and is the part of OSM-4D-definition and as this part of the 3D building-definition.

The 3D roof forms are currently supported (visualization) by JOSM PlugIn Kendzi3D.

"Implemented:<Yes/no/soon>" means implementation in Kendzi 3D plugIn.

NOTE: For the correct application of this schema, the building should be marked tag roof:shape=3dr


The total building height (H) is the same as defined in the specification S3DB.

This parameter is not included in the description below (Parameters), because it applies to all roof shapes.

Flat roofs

3D View


Top view + Sideviews

Roof0 0.jpg










Typ numerisch (3dr) 0.0 0.1 0.2 0.3 0.4
Value flat flat_with_terrace flat_with_two_terraces flat_with_three_terraces flat_with_four_terraces
Parameters height=* H, H1, L1 H, H1, L1, L2 *.a H, H1, L1, L2, L3 *.a H, H1, L1, L2, L3, L4 *.a
Restrictions none L1< depth L1< depth, L2< width L1< depth, L2+L3< width L1+L4< depth, L2+L3< width
Implemented yes yes yes yes yes

(*a) = if only L1 then all other L parameters = L1

Roofs with one sloping face

3D View


Top view + Sideviews

Roof1 0 parm.svg Roof1 1 parm.svg
Typ 1.0 1.1
Value skillion skillion_diagonally
Parameters H1 H1, H2 *a
Restrictions none none
Implemented yes yes


How to define roof direction? The FIRST point you draw, and direction of drawing of outline shape, defines it. Simply: The first two points of outline shape, you draw, are the lowest. The angle of roof inclination is perpendicular to the first two drawn points and go to the top. Note:This is roof definition from this page. Some renderers may use other definition. Please check results ofother definitions by use ok JOSMPlugIn Kendzi3D.

Attention: H1 means still the difference between height=* and roof:height=* !

see Simple 3D Building: [1]

(*a) = if only H1,H2 then H3 = H2 (Info: H4 is not necessarily then H4=2 x H2)

Roofs with 2 faces

3D View


Top view + Sideviews

Roof2 0 parm.svg


Roof2 1 parm.svg


Roof2 2 parm.svg


Roof2 3 parm.svg


Roof2 4 parm.svg


Typ 2.0 2.1 2.2 2.3 2.4
OSM tagging value gabled gabled_height_moved side_hipped half-hipped hipped
Parameters H1, L1 *a H1, H2, L1 *a H1, L1, L2 *a, *b,

roof:orientation=<north, east, south, west, north_east, south_east, south_west, north_west> this example is roof:orientation=south

H1, H2, L1 *c H1, L1, L2, L3 *a,*b,*d
Restrictions L1<depth L1<depth, H2>H1 L1<depth L1<depth L1<depth
Implemented yes yes yes yes yes

(*a) = if no L1 then symmetry: 2xL1 = width

(*b) = if no L2 then symmetry: L2=L1

(*c) = if only H1 then H2 = 0.5xH1 , L1=0.5 x width

(*d) = if no L3 then L3=L2

Note: How to tag roof:orientation for roof:shape=side_hipped and similar roof shapes?

This should be self explaining: RoofOrientationForSideHipped.JPG, RoofOrientationForSideHippedExplaining.JPG, RoofOrientationForSideHippedExplaining2.JPG, RoofOrientationForSideHippedExplaining3.JPG

This tag should be added for roof shapes:

  • flat_double_terraced
  • flat_triple_terraced
  • skillion_diagonally
  • side_hipped
  • double_skillion
  • triple_skillion
  • corner_saltbox
  • triple_saltbox
  • round_skillion_cutted
  • round_skillion_double_cutted

3D View


Top view + Sideviews

Roof2 5 parm.svg






(image has mix l1 and l2)
Roof2 8.jpg


Roof2 9.jpg


Typ 2.5 2.6 2.7 2.8 2.8 (subform)
Value pyramidal double_skillion triple_skillion diagonal_pass diagonal_pass
Parameters H1, L1, L2 *a H1, L1 *b H1, L1, L2 *c ,

roof:orientation=<north, east, south, west, north_east, south_east, south_west, north_west> this example is roof:orientation=east

H1, H2, H3 *d H1, H2, H3 *e
Restrictions none L1>0, L1<building width *a L1>0, L1<building width, L2>0, L2<building width, L1+L2<building width *a, *b H1, H2, L1 *c H1, L1, L2, L3 *a,*b,*d

(*a) = if no L1 then symmetry: 2xL1 = width, if no L1, L2 then symmetry: 2xL1 = width, 2xL2 = depth

(*b) = if no L1 then L1 = width

(*c) = if no L1,L2 then L1 = L2 = width. If L1+L2> depth then L1=L2=0.5 x depth

(*d) = Only three heights neccesary because the lowest height H, is the defined facade height.. H>H1 and H2>H3

(*e) = Possible subtype when H<H1 and H2<H3

Roofs with 2 Faces. L and T type

Buildings on the corner of 2 streets in the closed row of houses have often gabled roof shape which is difficult to generate only by use of roof:shape=gabled.

For this geoemtry I suggest the description roof:shape=L_gabled See example:

MarekLgabledAxonometry.jpg MarekLgabledTop.jpg

Roofs with more sloped faces

Subtype 3

3D View


Top view + Sideviews

Roof3 0.jpg


Roof3 1.jpg


Roof3 2.jpg


Roof3 3.jpg


Roof3 4.jpg


Type 3.0 3.1 3.2 3.3 3.4
Value saltbox double_saltbox corner_saltbox triple_saltbox quadruple_saltbox
Parameters H1, H2, L1 H1, H2, L1, L2 H1, L1, L2 H1, L1, L2, L3 H1, L1, L2, L3, L4

Examples: Marek30Dimensions.jpg 3.0 basic. 3 0DimensionsFreeOutline.jpg 3.0 free outline.

Subtype 4

3D View


Top view + Sideviews

Roof4 0.jpg


Roof4 1.jpg


Roof4 2.jpg






MarekRoofType4 3.jpg

Marek431Dimensioning.jpg Marek432Dimensioning.jpg

MarekRoofType4 4.jpg


MarekRoofType4 5.jpg


Typ 4.0 4.1 4.2 4.2.1 (L5<0) 4.2.1 (L5>0) 4.3 4.4 4.5
Typ gambrel mansard_onesided mansard thai_cutted thai pyramidal_diagonal skilion_windmill double_gabled
Parameters H1, L1, L2, L3 H1, L2, L2, L3 H1, H2, L1, L2, L3, L4* H1, H2, H3, L1, L2, L3, L4, L5 H1, H2, H3, L1, L2, L3, L4, L5 H1, H2 H1 H1, H2, H3

(*) If Symmetry, then only L1, L2 necessary

Typ 4.2 has, depending on the values ​​of the parameters, sub forms which are not "mansard" roof:

4 2subexample1.jpg Side view:4 2subexample1side.jpg

4 2subexample2.jpg Side view: 4 2subexample2side.jpg

Subtype 5

3D View


Top view + Sideviews

Roof5 0.jpg


Roof5 1.jpg


Roof5 2.jpg




Roof5 3.jpg


Roof5 4.jpg


Roof5 5.jpg


Roof5 6.jpg




Typ 5.0 5.1 5.2 5.3 5.4 5.5 5.6 5.7 5.8
Value round round_pyramidal round_skillion round_gabled round_skillion_cutted round_skillion_double_cutted round_hipped dome dome_overlapped
Parameters H1 H1 H1 H1, L1 H1, L1, L2 H1, L1, L2 H1 H1 *
Restrictions L1<width L1+L2<width L1+L2<width H1≤0,5*depth H1≤0,5*depth
Implemented yes
  • Valid only for rectangular shapes!

Subtype 6

3D View


Top view + Sideviews

Roof6 0.JPG


MarekRoofType6 1.JPG Marek3DviewRoof6 2.JPG

MarekRoofType6 2TopView.JPG

MarekRoof6 3.JPG MarekRoof6 4 4.JPG


Typ 6.0 6.1 6.2 6.3 6.4
Value basilical cross_gabled basilical_five_aisled apse_gabled
Paramaters H1, H2, H3, L1 H1, H2, H3, H4, H5, H6, H7 H1 H1, H2, H3, H4, H5 H1, n
Description 3x nave Basilika Building on the cross floor plan,

Wings can have different lengths,

Nave and transept must be continuously and

they must each have the same width.

five-aisled basilica. Building with an apsis

Values: 0-semicircle, 2 to 9

indicates resolution of the half circle.



Subtype 7

This subtype describes roofs with repeatable geometry. There are at the moment 5 repeatable geometries.

  • Simple saw form
  • Trapezoidal shape
  • Double inclined saw form
  • Semicircle
  • Wave

The last, 3. number below "n" describes the number of repeat.

3D View


Top view + Sideviews

Roof7 1 2.jpg


Roof7 1 4.jpg


Marek2D7 19.jpg


Roof7 2 2.JPG




Roof7 3 5.JPG


7 4 5.jpg


Marek2D7 43.jpg





Type 7.1.n 7.1.n (subtype) 7.2.n 7.3.n 7.4.n 7.5.n
Value sawtoth trapeze gabled_row round_row wave
Parameters H1 H1,n H1,n H1,n H1,n H1,n

Inversion and half end

Marek752i5.jpg Syntax 7.m.n,5 means the half end of the "wave"

Marek752i5inverted.jpgSyntax 7.m.ni mirrors the shape

Subtype 8

Subtype 8 describes


Rotation bodies based on round / regular polygonal ground view. In the default visualization the circle is divided into 24 segments.

3D View


Top view + Sideviews

Roof8 0.jpg




MarekRoof82.jpg MarekRoof83.jpg MarekRoof8 0n.jpg

MarekRoof8 0nSection.jpg

Typ 8.0.1 8.0.2 8.0.3 8.0.4 8.0.n
value cone mansard_cone double_mansard_cone triple_mansard_cone onion
Parameters H1, D1 H1,H2,D1, D2 H1,H2,H3,D1, D2, D3 H1,H2,H3,H4,L2,L3,L4 Sehe Beispiel oben:


Description Ebener Verlauf


1 x Knick

in dem Dachflächenverlauf

2 x Knicks

in dem Dachflächenverlauf [2]

3 x Knicks

in dem Dachflächenverlauf

n x Knicks in dem Dachflächenverlauf

z.B Zwiebelkuppel



Surfaces of higher degrees

3D View


Top view + Sideviews

MarekRoof8 1.jpg MarekRoof8 2.jpg.. MarekRoof8 2L1isL2.jpg MarekRoof8 3.jpg MarekRoof8 4.jpg MarekRoof8 5.jpg MarekWikipediaEllipticParaboloid.png MarekRoof8 7 draft.jpg


MarekGeodesicDomeDescriptionOfParameters.JPG MarekSphereCuttingTop.jpg


Type 8.1 8.2 8.3 8.4 8.5 8.6 8.7 8.8 8.9
Value hyperbolic_paraboloid parabolic hyperbolic_tower elliptic_hyperboloid ellipsoid_cutted elliptic_paraboloid tent geodesic_dome spherical_cutted
Parameters H1,H2,H3 H1,H2,L1,L2,ResolutionH, ResolutionV H1,D1, Twist, ResolutionH, ResolutionV H1,D1,D2,ResolutionH, ResolutionV, Twist H1, ResolutionH, ResolutionV, *a


H1, ResolutionH, ResolutionV, Twist *a H1, D, alpha, ResolutionH, ResolutionV, Twist Type=



value=<number of triangles>



(height of middle point

of the sphere), radius=<value>

(radius of the sphere)


Hc - Horizontal cutting plane

of the sphere on the top



Hc - Horizontal cutting plane

of the sphere down

Description Sehe: [3]

Any floor plan possible

If H1=H2 and L1=L2 then

A horizontal parabolic cylinder (see pict right) Any floor plan possible

Often used in industry The same mathematical definition

like 8.3 but not cutted in the middle

tent surface


Geodesic dome,


just a sphere
Restrictions no negative values
Implemented no no no no no no no no no

(*a) clarify: are this parameters enough?

(*b) nr of triangles=20*n*n or 60*n*n. For understanding of details see page of Werner Brefeld: [6]

  • Twist -rotation along z axis. Example see: [7]
  • ResolutionH : number of segments of floor plan (when change to regular polygon with n sides wished)
  • ResolutionV : number of segments of building height

Subtype 9

Subtype 9 describes the so called generic shapes. Assumption: All roof faces of the building with the beginning in the same height, have the same inclination. There are generated roof surfaces on any possible outline geometry.

Top view Roof9 0.jpg Roof9 1.JPG MarekRoofType9 2.jpg
Type 9.0 9.1 9.2
Value equal_hipped equal_mansard flat_mansard
Parameters alpha AlpfhaInSimple9dach.JPG H is the maximal height resulting from alpha H1, alpha AlpfhaInMansarddach.JPG, H1 ist the height of the lower roof side. H1, alpha 1
Restrictions none
implemanted yes in work in work

Tagging Proposal

Attribut Value Description
building yes, * just building..
3dr:type e.g. 2.0 Describes roof type. E. g. 2.0. Tagging for the quick manual input can be supplemented with the description of the dormers. Extended version can looks like 3dr:type=2.0.a.a)
Parameters for roof type :
3dr:height1 [m, d] default meter The parameter describing the first height for a given type of roof.
3dr:height2 [m, d] The parameter describing the second height for a given type of roof.
3dr:length1 [m, %] Domyślnie %. The parameter describing the first length for a given type of roof.
3dr:length2 [m, %] Domyślnie %. The parameter describing the second length for a given type of roof.
3dr:lengthX [m, %] The parameter describing the the next (X) lengths
3dr:dormer E.g. "aa.a" Atrybut opisujący kolejne lukarny uporządkowane w grupy. Grupy lukarn rozdzielone są kropkami. Grupa mogą zostać przypisane do krawędzi obrysu budynku lub do boku prostokąta opisującego dany obrys. W przypadku przypisania do krawędzi numer grupy odpowiada numerowi krawędzi obrysu. Sposób przypisania określa atrybut 3dr:donor:type. Domyślnie grupy przypisane są do krawędzi.

Brak atrybutu oznacza przypisanie grup do krawędzi =rect

Lukarny podane w tym atrybucie są nadrzędne względem tych podanych w atrybucie building:roof:3dr:type. Wartość dotycząca lukarn z atrybutu 3dr:type powinna zostać automatycznie przenoszona do tego pola po zakończeniu edycji.

3dr:donor:type "rect" Określa sposób przypisania grup lukarn. Wartości: Domyślne brak, rect - przypisanie grup do krawędzi prostokąta opisującego obrys budynku.
3dr:dormer:width [m] Wartość domyślna dla wszystkich nadbudówek dla danego dachu. Opisuje szerokość nadbudówki [domyślnie m]
3dr:dormer:heightX [m, d] Wartość domyślna dla wszystkich nadbudówek dla danego dachu. Wysokość nadbudówki [domyślnie m, dla niektórych dozwolone stopnie]
3dr:dormer:lengthX [m, %] Parametr opisujący kolejne długości nadbudówki

The position of the tagged point corresponds to the symmetry axis of the dormer.


Roof based on shape of rectangle

Some roof base on shape of rectangle and only for this shape can exist. Building polygon not always have only four nodes. And it can have different shape than rectangle. Example of this building polygon is:

MarekLbuildingwith2 0example2.jpg

Example of roofs based on rectangle are types: 0.*, 1.*, 2.*, 3.*, 4.*, 5.* ?, 7.*


Type 2.1 Type 5.2 Type 5.6
MarekExampleType21withFreeGroundFloor.jpg MarekExample52withFreeGroundFloor.jpg MarekExampleType56withFreeGroundFloor.jpg 3D view: MarekExampleType56withFreeGroundFloor3D.jpg

In case of type 5.6 we find the biggest circle inside building polygon. The circle is base for roof sphere (red surface on image, shared points are marked blue) rest of roof is generated flat (gray color).

Generation of building bounding box.

To generate 3D model for building polygon which is not rectangle at first place we need to find the smallest rectangle containing building polygon. It is easy to generate shape of building roof for rectangle and it is easy to place dormers using this rectangle.

Example of generating roof for complex building polygon:

Roof sample 3 en.svg

Roof properties

Because roofs are base on rectangle, rectangle sizes are taken in to account in process of roof generation. Each roof type has properties describing it's shape eg. 3dr:length. If properties are write in presents true size of properties are calculated using presents and rectangle sizes.

Roof sample 2 en.svg

Some times automatically generated bounding rectangle (red color) is not as we expected (green color):


Starting point

When we need to describe roof with precision it is necessary to determinate roof direction. Now day proposals using tag building:roof:orientation= along|across. Unfortunately this tag is not enough because:

1. There are building polygons which are square. In that case value of tag is pointless and there are four way to generate roof model

MarekAlongAcrossQuestion1.jpg MarekAlongAcrossQuestion2.jpg MarekAlongAcrossQuestion3.jpg

2. There are roof shapes which have four like type 1.0 or more ways to generate roof model:


next tags leike along, rotated or mirrored make the tagging system prone to errors.

3. Dormers needs to precisely mark where roof “begins”

To precisely mark where roof “begins” we need to choose some point as start point. There is not need to add additional tags for node because building polygon has defined nodes direction. We can use start point as point first point on building polygon.

Warning. Starting point for building polygon is not visible in osm editors!

Polygon direction

By default bounding rectangle is generated as the smallest rectangle write on building polygon. Not always we expected this behavior. To change this we need add additional tags describing direction of bounding rectangle. Direction of rectangle affects on location of dormers because it describing where it is front of building.



BoundingBox1 en.svg

Method 1

Using tags assigned to nodes of building polygon. Two of nodes have assigned tag 3dr:direction=begin|end. Method may by used for single buildings which don't share walls.

Tag Description
3dr:direction=begin Begin of vector describing direction of roof.
3dr:direction=end End of vector describing direction of roof.

Status Implemented

Method 2

Points describing direction are write using relation. This allow for buildings with shared walls.

Relation type: 3dr

Any node with role 3dr:direction:begin

Any node with role 3dr:direction:end

Warning It may change

Warning Not implemented

Places for dormers

For roofs base on rectangle there are four place where we can put dormers. Places are connected with edges of rectangle containing building polygon. Example image:

Roof sample 1 en.svg

Places number on roof Tag Tag (Alternative) (not working) Description
place 1 3dr:dormers:front 3dr:dormers:1 Front
place 2 3dr:dormers:right 3dr:dormers:2 Right side
place 3 3dr:dormers:back 3dr:dormers:3 Back
place 4 3dr:dormers:left 3dr:dormers:4 Left side

Not for all roofs shapes all four places are available. In example above for roof shape type 2.0 there are only two places for dormers. There are places 1 and 3 (front and back). All others places are ignored.

Warning Currently not implemented. Currently dormers can be setup using tag 3dr:type=2.0.aa.b

Complex roof geometry

The complicated roofs should be described as a sum of single simple components

Name translation

The both descriptions for the roof geometry are compatible. You can write "0.0" or "flat".We are working on understandable description for every roof types.

Names for roof types:[8] :

"roof table" "building attributes"
0.0 flat
1.0 skillion
2.0 gabled
2.3 half-hipped
2.4 hipped
2.5 pyramidal
3.0 half_saltbox*
3.1 saltbox*
3.2 corner_saltbox
3.3 triple_saltbox
3.4 quadruple_saltbox
4.0 gambrel
4.1 , 4.2 mansard
4.3 helm
5.0 round
5.2 half_round
5.6 dome
6.0 three_aisled
6.2 crosspitched
6.3 five_aisled
7.1.n sawtooth
7.2.n trapeze
7.3.n gabled_row
7.4.n round_row
7.5.n wave
8.0 cone
8.1 hyperbolic_paraboloid
8.2 parabolic
8.3 hyperbolic_tower
8.4 elliptic_hyperboloid
8.5 ellipsoid_cutted
8.6 elliptic_paraboloid
8.7 tent
8.8 geodesic_dome
8.9 spherical_cutted
9.0 equal_hipped

  • note: the common german name for the both roof subtypes is "Berliner Dach". See: [9]

Comparison table with: Image - roof_table - building attributes at: Dachformen.pdf --Geri-oc 18:41, 7 December 2011 (UTC)