Sparky@Posted: Wed May 18, 2005 8:48 pmĀ :
Here are step by step instructions detailing the process of creating a normal mapped texture using only the GIMP. This is largely based on the generic texture creation tutorial ( http://www.doom3world.org/phpbb2/viewtopic.php?t=482), but is written using the GIMP instead of Photoshop. I had a bit of trouble figuring this all out, so I thought I'd write up what I learned in the hope that it will help others. I will also make a tutorial explaining how to use Blender to create normal maps, but it hasn't been written yet (the link will be here).

1)First off, you'll need to download and install the GIMP. Go to http://gimp.org/ and click on the "Downloads" link on the left.

2)You'll also need the GIMP normalmap plugin, which can be found here: http://nifelheim.dyndns.org/%7ecocidius/normalmap/.

Most of the materials in Doom 3 have three source textures: a diffuse map, a specular map, and a normal map.
3)For starters, create a folder to house all the textures in. Let's call it Doom 3\base\textures\custom.

4)Create a new document in the GIMP: File>New (ctrl-N). It's a good idea to have your dimensions be powers of two, such as 256x256, or 1024x512.

5)Now draw your height map. Dark points are low, light points are high. Color information is discarded when the normalmap filter runs, so it makes sense to use only grays for this process. (You may want to save a copy of this in height map format.)
Image

6)Run the normalmap filter: right-click>Filters>Map>Normalmap (right-click>R>M>Normalmap).
Image

7)Save your normal map: right-click>File>Save (ctrl-s). Let's call it "yourtexture_local.tga"

8)Now create another new document: File>New (ctrl-N).

9)Now draw your diffuse map. If you need inspiration, you might want to look at this thread: http://www.doom3world.org/phpbb2/viewtopic.php?t=1649&highlight=industrial.
Image

10)Save your diffuse map: right-click>File>Save (ctrl-s). Let's call it "yourtexture_d.tga". This will save it as a TarGA image. This can go into the new directory we created.

11)Let's create another new document with the same resolution.

12)Now draw your specular map. If you saved a copy of your height map, it may make sense to refer to that as you draw. Maybe you'd like to make the high points smooth and shiny, or fill the crevices with non-specular grime. It can also be very effective to mottle the entire surface as though it's oxidized, or create shiny patches where the surface is frequently abraded. Wet spots or parts made out of a smoother material will also be specular.
Image

13)Save a copy of the specular map: right-click>File>Save (ctrl-S). We can call this one "yourtexture_s.tga".

14)All we need now is an editor preview image. Let's just create a placeholder for now, and we can replace it with a screenshot later. Save it as "yourtexture_ed.tga"

Now that you've got all your source textures drawn, we just have to write a basic material definition. If you've made materials before, there's a good chance you know more about this bit than I do!

15)Create a directory to put material files in: Doom 3\base\materials.

16)Here's a sample material definition:
Quote:
textures/custom/yourtexture
{
qer_editorimage textures/custom/yourtexture_ed.tga
bumpmap textures/custom/yourtexture_local.tga
diffusemap textures/base_trim/mintrim2_d.tga
specularmap textures/base_trim/mintrim2_s.tga
}

Just type this up in a text editor, and save it as "yourtexture.mtr" in Doom 3\base\materials.
You're done! Now when you open DOOMEdit, your texture will appear in the material browser: Textures/textures/custom/yourtexture
ImageImage

If anyone has any trouble getting this to work, feel free to ask questions.