Skip to content

Skillion roofs are 7.5 storeys tall if no levels or angle are set #146

@zuzak

Description

@zuzak

I have a building part thus:
https://beakerboy.github.io/OSMBuilding/?id=1426868383
https://www.openstreetmap.org/way/1426868384

building:colour=lightyellow
building:levels=2
building:part=yes
roof:colour=grey
roof:direction=10
roof:shape=skillion

This is rendering in OSMBuilding as having a height of 22.5 metres, which is the equivalent of 7.5 storeys.

Image

It looks like if the roof:shape is skillion, roof:levels is not defined, and roof:angle is not defined, we default to 22.5.

(calculatedOptions.roof.shape === 'skillion' ? (calculatedOptions.roof.angle ? Math.cos(calculatedOptions.roof.angle / 360 * 2 * Math.PI) * shapeHeight : 22.5) : null);

Should this fall back instead to null so that we end up with a roof that is 1 storey tall if no more specific values are set?

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions