Results 1 to 2 of 2

Thread: The GRASSlands

  1. #1
    Guild Journeyer
    Join Date
    Jun 2011

    Wip The GRASSlands

    This is a shaded relief map made in GRASS and QGIS. It's meant as an experiment and proof-of-concept, I'm not likely to create a "finished quality" map.

    Click image for larger version. 

Name:	roads_test_shaded_relief.png 
Views:	1244 
Size:	1.48 MB 
ID:	37086

    This is a summary of the steps to create the map. It's not a how-to; you'd need to know QGIS and GRASS to follow it.
    1. Start a new QGIS project. Choose and set a map projection if desired. I used Mercator, good for a small to medium region near the Equator.
    2. Create a new mapset in GRASS. Make the projection match that in QGIS. Set a region. I chose a 100x100 km region at the Equator-Prime Meridian intersection.
    3. Set your region's resolution. I chose 100m.
    4. Create a DEM with Display it, and don't worry that it's a grey box. I chose a fractal dimension of 2.25.
    5. In QGIS, set symbology to colourmap, and create a colourmap for topography. I used the conventional colours: deep blue to light blue in the sea, dark green through light greeen into brown in the land.
    6. Save the style for your topography layer. You will need to load it for other layers.
    7. If you don't like your topography, rerun Increasing fractal dimension increases complexity.
    8. Run r.fill.dir on the topography a few times, to remove small depressions. Don't overdo it or things will end up weird. Display it. I ran it twice.
    9. Run r.watershed on the filled topography. This will do your rivers. Display it, don't worry about the colours yet. I used a threshold of 1000, lower means it'll show more detail and smaller streams.
    10. Run r.mask, using your filled terrain and values 0 thru 9999. This limits following operations to the land only. Note that in GRASS the mask describes the area INCLUDED in operations, not an area excluded.
    11. Run r.grow on the streams. As well as making them a little wider, since the mask is set they'll be clipped to the land instead of showing underwater rivers. Display it. Set symbology to colourmap, classify with 2 values, and make them both the same to make all rivers the same colour.
    12. Run r.contour on the filled terrain to make some contour lines. Don't make the spacing too small or you'll bog down your PC. Display it, but don't label it (that bogs the PC down even worse). I used 25 m steps.
    13. Run r.shaded.relief on the filled terrain to create relief shading. Display this, move it above the terrain layer and set transparency to about 50%. (Note how much this changes the appearance).
    14. Run r.mask -r (in the shell) to remove the mask.
    15. Identify a lake location. This will be somewhere where the contour lines completely enclose a stream segment, indicating a depression in that area. Run r.lake.xy to create a lake to the highest level that doesn't flood the ocean or to the edge of the map. Finding this level is basically a game of higher or lower, the contours should help you make a starting guess. Display it. Repeat this for all the lakes. This is probably the most time-consuming part.
    16. Run r.patch to combine all the lakes into one raster layer. Display it.
    17. Remove unnecessary layers, organise the needed ones, and tweak the symbology. I place terrain lowest, then relief shading, then streams, and lakes on top.
    This was an experiment, and there are some flaws in the method and the resultant map.
    • There's no control over the terrain.
    • The rivers "sit" on the terrain, there aren't valleys.
    • There may be too many lakes. This may be related to the above.
    • The rivers are all the same width.
    • Doesn't fractal terrains do all this stuff with much less effort?
    • The rivers don't meander in lowlands.

    These all could I think be addressed.

    Next steps
    GRASS has a module to calculate the most efficient walking routes between points, balancing distance against factors like slope and difficulty of terrain. I plan to experiment with this for producing paths between villages, and possibly see if it can be extended to things like roads, railways, and canals. Indeed, testing this out is the main reason I've made the map.

    And yes, the thread title is an incredibly lame pun.

  2. #2
    Guild Expert Gracious Donor Hai-Etlik's Avatar
    Join Date
    May 2009
    48° 28′ N 123° 8′ W
    Blog Entries


    Cool, GRASS has been on my "Things to learn" list for a while now. I'll have to give this a try when I've cleared some of the other projects from my list.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts