Tuesday, November 13, 2018

Shadow Mapping

Septima Skyggekort is an interactive map which visualizes the shadows cast by Denmark's buildings at any hour of the day and for any day of the year.

The map was created using the OpenLayers mapping library using height data from Styrelsen for DataForsyning og Effektivisering, the public data agency of the Danish government. The height data appears to come from a Lidar survey of the whole of Denmark. This means that you can use the map to view the length and positions of shadows for any building and for any tree in the whole country. Just use the two slider controls on the map to select the day of the year and the time of the day you wish to see visualized on the map.

Norway's The Shadow Visualization Demo is another impressive demonstration which shows dynamic shadows on an interactive map. This map uses digital terrain model data and building height data from OpenStreetMap. Because the map knows the height of the terrain this map not only shows the shadows of buildings but the shadows cast by hills and mountains as well.

Again you can use the slide controls to select any time of day and any day of the year.

In New York you can use the New York Times' Mapping the Shadows of New York City interactive map to visualize the shadows cast by the city's famous sky scrapers (and all of its other buildings as well.)

The Times says that most Manhattan neighborhoods will remain in shadow for at least half of all daylight hours. They also claim that the amount of time a location spends in shadow during daylight hours can affect everything from apartment rental prices to the flow of foot traffic on the city's streets.

The map uses building height data provided by the city. With the help of the Tandon School of Engineering at New York University the NYT used this height data to calculate the total number of minutes that a given point spends in shadow over the course of a day.

If you are interested in creating your own shadow map then you might be interested in SunCalc.js, a javascript library for calculating the position of the sun.