Results 1 to 5 of 5

Thread: From 2D to Shaded relief?

  1. #1
      at1981 is offline
    Guild Applicant Facebook Connected
    Join Date
    Aug 2014
    Location
    Stockholm (Sweden)
    Posts
    2

    Help From 2D to Shaded relief?

    Hello!


    I need help so I can transform my 2D map to a shaded relief map! .


    ---
    In Adobe Illustrator I have each separately elevation level in their own layers, such as all lines 10 feet above sea level in a separate layer and all lines 20 feet above sea level in another separate layer that I have lime off from a topographic map.

    ---
    What should you do to make your own maps using existing information from a topographical map so that, for example, looks like this?


    Link:
    http://geochristian.files.wordpress....lanalyst11.jpg

    (In the right picture you can see a topographical map with contours and in the left picture you can see the end result, so I would like to have it!)


    ---
    Thank you in advance for your help! Greetings at1981!

  2. #2
      xpian is offline
    Guild Journeyer Gracious Donor
    Facebook Connected
    xpian's Avatar
    Join Date
    Sep 2010
    Location
    Golden Gate Park Panhandle, San Francisco
    Posts
    161

    Default

    If I were doing it by hand, I would begin by tracing out all of the ridge lines and the trough lines. Some of those ridge lines are pretty obvious--basically, you are starting with your pen at the peak of the mountain and then drawing a line to one of the "spikes" in the topo-line, then to the corresponding spike in the next outer-most topo-line, and so on. When you draw the trough lines, you are probably drawing them from the outside-in, following one divot in the topo-line to the next divot. Make sure you keep the ridges and troughs distinct for yourself.

    The magic comes in when you begin shading and highlighting. Pick a direction for the light, then shade the "backside" of the ridge line. Do this gently at first, and make sure that the darkest shading is right along the ridge line itself. When highlighting, put down a light color on the side of the ridge that faces the light. Again, the brightest intensity of the light should be right along the ridge line, just next to the darkest region of shadow. For the troughs, reverse this advice.

    That said, I'm sure others here will have more "automatic" methods that allow the computer to do most of the shading work. I'd be eager to hear about those methods as well.

  3. #3
      xpian is offline
    Guild Journeyer Gracious Donor
    Facebook Connected
    xpian's Avatar
    Join Date
    Sep 2010
    Location
    Golden Gate Park Panhandle, San Francisco
    Posts
    161

    Default

    That's Mount Shasta in your example, isn't it? Now, for me, this is the kind of image I'm obsessed with: ( http://www.siskiyous.edu/Shasta/map/map/3dmap.jpg ) But I can see the value in the top-down approach as well.

  4. #4
      waldronate is offline
    Software Dev/Rep Gracious Donor waldronate's Avatar
    Join Date
    Mar 2007
    Location
    The High Desert
    Posts
    1,670

    Default

    Shaded Relief – Home and Relief Shading are two excellent resources on the topic. Imhof's "Cartographic Relief Presentation" ( https://www.google.com/#q=cartograph...f+presentation ) is also very useful.

    For real-earth data, it's fairly simple to get fully-functional height fields that can be used as inputs to 3D rendering tools to get that exact look shown on the left side. The USGS offers DEMs for the whole US at high resolution.

  5. #5
    Guild Master Gracious Donor Midgardsormr's Avatar
    Join Date
    Aug 2007
    Location
    Los Angeles, CA
    Posts
    2,443

    Default

    You'll need to convert your contour map into a heightmap. A heightmap, or Digital Elevation Map (DEM) is a raster image where the value of each pixel corresponds with the elevation of the land that pixel represents. Such an image generally needs to be in a color mode greater than 8-bit, which is the mode you're most familiar with. The reason is because an 8-bit channel can contain only 256 discrete levels, so if you try to use it to cover, for instance, a 2,000 foot change in elevation, you'll create a series of 8 foot terraces (2,000 / 256 = 7..

    All of that to say that the first thing you'll need is a way of getting access to more "steps." That means working in 16-bit or 32-bit floating point mode. Floating point images give a practically infinite (not truly infinite, but close enough that you probably won't be able to tell the difference) number of divisions in your luminance, which will allow you to have smooth slopes. Okay, then: 16-bit floating point image.

    The next thing you need is to designate a value for your highest and lowest points in the map. This can be arbitrary, setting the lowest point to 0 and the highest point to 1 (which allows you to view the heightmap without have to normalize it for display), or you can use real numbers, with the value of a pixel set to the actual elevation of the terrain. Although in a floating point image, 0 is black and 1 is white, you're allowed to go outside those boundaries. The trouble is that you can't really view the resulting map—everything above 1' above sea level will simply appear to be white. The advantage to using real numbers is that you don't need a formula to convert real-world values into your digital scale. Also, your heightmap will be valid for other uses—if you want to extend coverage to the west, but that land is lower, you don't have to adjust your entire scale to make a new black point.

    So then, regardless of which way you decide to go, you now have the information you need to start setting up the heightmap. Fortunately, you already have vectors of your contour lines, so you don't need to find a way to convert that. You will need to bring the layers into a raster editor such as Photoshop or the Gimp in order to make the heightmap you need. Although I suppose it's possible that Illustrator might able to work in floating-point color, I don't think it has the ability to actually make the shaded relief, so one way or another you're going to wind up in PS or equivalent. I'd start with layer filled with your lowest elevation color. Then make a selection of the level right above that and fill it with the color for that elevation. Now you need a way to blend between the two colors. I think in Photoshop, I'd do an outer glow on the upper layer, setting the color of the glow to the same as the layer and adjusting the size until I got a reasonably good blend from low to high. It probably won't line up everywhere, but you can touch it up later. Proceed the same way for each layer up to the top, where you'll have to come up with another solution to do the peaks. Perhaps a shapeburst gradient or just paint it with a very soft brush.

    Once you have the heightmap constructed, you can use it to generate the shaded relief. The simplest way if you're in Photoshop will be to normalize it using a Levels adjustment layer if you're in real-world units, flatten (save as a new version first!), and copy the image into a new channel. Bring in your color map and run the Lighting Effects filter on it—Lighting Effects uses an alpha channel as its heightmap, which is why you have to copy the information over there first.

    You could also use the heightmap as a displacement on a plane in 3d software, which will achieve the look xpian is after. Done that way, you can use an actual light to get the shaded relief.

    Sorry if that's a little scattered. I'm at work right now, so I can only devote a small portion of my attention to what I'm saying here. Hopefully it's coherent!
    Last edited by Midgardsormr; 08-30-2014 at 09:00 PM.
    Bryan Ray, visual effects artist
    http://www.bryanray.name

Posting Permissions

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