Changes between Version 3 and Version 4 of ZoomLevels


Ignore:
Timestamp:
Jul 27, 2018 8:55:30 PM (7 years ago)
Author:
Uriel
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • ZoomLevels

    v3 v4  
    1111|| 5 || 11.25 ||
    1212|| 6 || 5.625 ||
    13 || 7 || 2.813 ||
    14 || 8 || 1.406 ||
    15 || 9 || .703 ||
    16 || 10 || .352 ||
     13|| 7 || 2.8125 ||
     14|| 8 || ~1.406 ||
     15|| 9 || ~.703 ||
     16|| 10 || ~.352 ||
    1717
    1818More info can be found on the [https://wiki.openstreetmap.org/wiki/Zoom_levels OSM Wiki]
     19
     20= Generating A Map
     21Obviously we can't just load up all the SRTM data at once and click "go". This would require many Gigabytes of RAM, and presumably you do not have access to that kind of hardware. Instead, let's think about breaking the world down into smaller, manageable pieces.
     22
     23Let's assume we want to generate a map at zoom level 7. Each web tile at this zoom level is a square, 2.8125 degrees on a side. SRTM data comes in squares, 1 degree on a side. It's not possible to load only part of an SRTM tile in Maperitive. We also need to be sure to load more data than we need. If we only load a single 1 degree tile, Maperitive will not be able to fill the entire 2.8125 degree tile with data and will generate nothing instead.
     24
     25How much data do we need to load at a time? To keep things simple and small, we'll do our math in only one dimension, and we'll only try to generate 2 web tiles at a time. In practice one would generate these tiles, then start Maperitive over to clear the RAM and generate the next two tiles.
     26
     27The most data we could possibly waste on the left side of the tile is just about 1 degree. We'll say .999. So if our (fictional) tile at zoom 7 starts at 6.999 degrees, we will still need to load the SRTM data starting at 6.0 to ensure we cover that little bit before 7.0. The right border of our two-tile window is 6.999 + 5.625 = '''12.624 degrees'''. Since our SRTM data needs to overshoot that, our SRTM window must go from 6 to 13 degrees. That's 7 tiles.