PDA

View Full Version : [Award Winner] Making mountains in Gimp using an overlay layer



torstan
04-02-2009, 03:07 PM
This is a basic run through of how I make mountains in Gimp using an overlay layer. The same method can be used to provide light and shade to general maps and is something I use very regularly.

Let us say that you have an image with the colours that you want in the right place. Here I have an image with a grass texture blurred into brown and then light brown-grey to designate a mountain range:

11962

Now this looks very flat. To create an illusion of depth we need to all light and shade. One way to do this is to create a new layer and fill this with 50% grey (7f7f7f in html notation). Set the layer mode to overlay:

11965

Now take a large round brush and paint with pure white on the edge of the mountains towards the light and black on the areas away from the light. This will generate light and shade for you. I use a tablet, so I just allow the pressure to give me more or less light and shade. If you are using a mouse I would suggest that you set the opacity of the brush quite low and build up the areas of light and shade.

After doing this it's often useful to take the smudge tool and just smooth away any hard edges. Now, this is the overlay layer that I created for my mountains:

11963

This is the result of that layer set to overlay over the coloured layer I had before:
11964

Now obviously the colours underneath are important too. If I was doing this with more care then I'd try to texture the mountain properly rather than having flat brown as the colour.

This method requires a little care, and is most useful with a tablet. I'll show a slightly longer, but perhaps more foolproof method next.

torstan
04-02-2009, 03:18 PM
Okay, so as promised, here's the second method.

As before the image will have a base layer with the colours on it, and an overlay layer that generates the light and shade. This post (and the couple that follow it) will show how to generate a decent overlay layer using filters rather than drawing it in by hand.

First create a new transparent layer using the layers dialogue, or Layers->New Layer (shift-ctrl-n). On this layer use the lasoo tool to select the border of your mountain shape. It doesn't have to be exact. Here's mine:
11966

Now we want to use gradient fill to fill this with a gradient that goes from white along the ridge lines to black along the edges. Here's the settings I use for my gradient settings. I've highlighted the important ones - especially Shape: Shaped(angular):
11967

Now click and drag a line from the middle of your selection to one of the edges of the selection. This should fill the selection with your gradient. Now invert the selection (ctrl-I), grow the selection by 1 pixel (Select->Grow selection) and fill with black, you should have something like this:
11968

This will be the layer we use as a bump map.

Next, create a new layer and fill it with 50% grey. This will be our overlay layer. Go to Filters->Map->Bump Map. In this dialogue select your gradient filled layer as the map in the drop down menu. Play with the depth setting to get a reasonably dark shadow and make sure you select the angle for the azimuth so that you have the light coming from the right direction:
11969

When you are happy with the preview, hit okay and you should get something that looks a little like this:
11970

torstan
04-02-2009, 03:28 PM
Now this is a nice start on a mountain ridge - however beware! The shaped(angular) gradient in gimp gives vertical and horizontal striping and the bump mapping can often leave a lip around the edge of a selection - both features you can see in this example. If you just go ahead and use this layer as your overlay layer you'll get something that looks like this:
11977

Now anyone who ends up with something looking like that should be shot. It only takes a couple of steps to get something looking a lot better. I'll show you two different ways to improve this. First, the easiest. Run a gaussian blur on the layer (Filters->Blur->Gaussian blur):
11978

Fiddle with the settings until the preview has no signs of the defects left over from the bump mapping. With your new smooth overlay layer you will now have the much more attractive result:
11979

Note that the gaussian blur has also smoothed out the transition from the shadow to the flt ground. This is great because mountains do generally smooth out before the ground levels off.

Another means of fixing the defects is to manually go in with the smudge tool. This gives you a little more direct control and also allows you to keep the sharp ridge lines. I use the following settings:
11981

Now use the smudge tool by scribbling in lines going back and forth from the ridge to the edge of the mountain shape and back. This will smooth out the defects. I got this from my original bump mapped layer:
11987

torstan
04-02-2009, 03:32 PM
Now when I set the layer to overlay again, I get the following:

11988

So to recap, by using an overlay layer you can change a flat image to one with a bit of form and shape. This can be used to create light and shade fro scratch, but can also be used later on to enhance the light and shade already present in a piece. The trick really lies in creating a reasonable layer.

Here's the three different images created in three different ways during this tutorial. I hope it was useful.

11989 11990 11988

jfrazierjr
04-02-2009, 03:38 PM
I use the smudge trick all the time, and I have to say, that even thought it takes a long time, you can produce some stunning results. I typically take a second pass at bump mapping after I have run the smudge tool on the first bump mapped version and this really gets some very nice results after you have played with it for a while. The biggest issue with the second bump map pass after using smudge is that sometimes it looks horrible, so you have to choose your brush and brush size carefully to get the right effect when smudging.

Thanks for the nice tut Torstan!!! rep++++++

For those interested, here is an example using the third method plus a bit of playing around.

torstan
04-02-2009, 03:59 PM
Thanks Joe, I wanted to create a tutorial that shows both a hand drawn approach (I include smudging in this category) and an automated approach.

I like those mountains a lot. I'd perhaps say that the shadows near the ridgelines are a little extreme compared to the rest of the mountain - the shadows should stay dark for most of the width of the mountain before tailing off around the base. Also, the river bump mapping is really extreme - the banks of the rivers have a stronger shadow than the mountains! Great map though - and a lovely example of what can be done with texture and colour and then enhanced with a bit of light and shade.

jfrazierjr
04-02-2009, 04:08 PM
Thanks Joe, I wanted to create a tutorial that shows both a hand drawn approach (I include smudging in this category) and an automated approach.

I like those mountains a lot. I'd perhaps say that the shadows near the ridgelines are a little extreme compared to the rest of the mountain - the shadows should stay dark for most of the width of the mountain before tailing off around the base. Also, the river bump mapping is really extreme - the banks of the rivers have a stronger shadow than the mountains! Great map though - and a lovely example of what can be done with texture and colour and then enhanced with a bit of light and shade.

Thanks. The one I like THE BEST,was here(but I did not "do up" the entire mountain chain): http://www.cartographersguild.com/showpost.php?p=23501&postcount=22

As for the rivers, if you notice, there is only a bit of bump mapping in certain places. I was trying to signify some fairly steep cliffs in those few locations. OF course, they were the result of a bit more automation than the mountains also, so I can see your point but at the time, I really did not know how to do it the right way...

jfrazierjr
04-02-2009, 04:13 PM
Thanks Joe, I wanted to create a tutorial that shows both a hand drawn approach (I include smudging in this category) and an automated approach.


I really like your first example, but I have not been able to get something I like using that more hand drawn approach. Of course, when I try, it is usually at work during my lunch, so I don't have my tablet and probably forget to make multiple passes with the opacity dialed down. Will have to remember that next time I give it a whirl.

To be honest, re-reading the first steps, I am surprised you used the paintbrush instead of dodge/blur since you tend to use that so often when building up the shadows/highlights on the grey layer.

torstan
04-02-2009, 04:26 PM
I've gone back to using paintbrushes for this rather than dodge and burn because it's faster. I find it quicker these days to get a result I like with the paintbrushes and smudge to take off hard edges rather than dodge and burn. I also like being able to lay in precise highlights and shadows directly rather than having to build them up. I guess it's just the result of having to do maps to deadline these days rather than working over them over a length of time. However, as with all things in this, the more care and attention you pay and the more detail you build up, the better the final product will look.

Steel General
04-02-2009, 06:26 PM
Great stuff guys!

RobA
04-02-2009, 07:15 PM
I'll add a couple suggestions. If you have a tablet try the airbrush tool rather than the paintbrush tool as it is much more responsive. Also if you blur the angular gradient before using it as a bumpmap you can use the curve adjust to define the profile and sharpen the ridge. Lastly instead of greating a 50% grey layer and applying a bump map you can apply the emboss filter directly to the heightfield with a 30degree altitude and will end up with a layer where all flat surfaces are 50% grey.

-Rob A>

Midgardsormr
04-02-2009, 07:23 PM
Thanks for finally putting this up in an easily referenced form. Repped and rated!