Normal, Displacement & Bump Maps

We have been asked to research into normal, displacement and bump maps. Hopefully in this post I’ll point out the differences and what each are used for. All of these maps do something akin to adding detail on the surface of geometry without an increase in geometry.

Bump Maps

A bump map is now an older type of map, I remember using them when I was first learning 3D many moons ago. They create the illusion of depth on a surface using lighting tricks using a greyscale image. Differences in white and black values (8-bit 256 colour choices) tell the software package up or down faking depth.

bump1

White details are raised, black are lowered. They’re great for creating small surface details such as pores and relatively easy to make. I used to throw them together back in the pre-historic days of Photoshop 4. The weakness of bump maps is they break pretty easily if viewed from the wrong angle. Since all detail is fake, the silhouette of the geometry will never change.

Displacement Maps

Displacement maps don’t fake additional detail, as long as the source mesh has enough subdivisions a map will displace geometry. They can be created from a high poly model and baked or painted by hand like bump maps of old, better results can be found using 16-32bit greyscale maps rather than 8-bit.

profilelg

However unlike the fake detail of other maps, displacement takes a lot of rendering power and therefore time consuming. Therefore most applications only calculate displacement maps at render time and not in the viewport. It’s hard to beat the results of displacement maps but the end quality should always be weighed against the extra rendering time to see if its required.

Normal Maps

Normal maps are the newer better replacement for bump maps, they work in the same fashion, faking surface detail by light tricks. The maps they use are RGB rather than 256 bit greyscale and this changes the way they work over traditional bumps. While bump maps can only represent an up and down value, the RGB corresponds to the X,Y,Z axis in 3D space. This allows the map to tell the software the direction each normal is facing, allowing for more complex light shading.

NormalMapping

There are two types of normal map:

  • Tangent Space Maps – A mix of purples and blues, work great for meshes that have to deform during animation. Great for characters.
  • Object Space Maps – Rainbow assortment of colours, improved performance. Works best for meshes that won’t deform at all.

Normal maps are very difficult to create by hand and are usually generated by software packages. Most often baked out from a high poly mesh to use on a lower poly mesh. Which brings me onto today’s exercise.

Maya High to Low Baking

The exercise we were given was to create some form of crate, first modelling a low poly version, duplicating this and then going to town on it for the high poly version. This would then be baked down to the low poly to demonstrate the technique.

We had around an hour to create both models. Since this was a learning exercise I simply tried to copy the design of one of the crates in the demonstration slides.

boxes1

I knew what ridges I wanted on the box and after some advice that these would still be required on the low poly, I made sure to sculpt as much as possible of the core shape without adding detail. The high poly was achieved through a combination of adding new meshes and boolean operators, it seems that when making a high poly for baking that mesh neatness isn’t too much of an issue as long as there aren’t any ngons. The low poly was auto unwrapped and the two were placed sharing the same co-ordinates. Time to bake!

Following Matt’s powerpoint slides I baked out the normal map. The process doesn’t appear too complicated however there is a lot that can go wrong. In Maya’s rendering menu, go to Lighting/Shading > Transfer Maps, assign your low poly to target mesh, your high poly to source mesh. Choose normal map, tangent space normals, image format and quality settings, hit bake and go make a cup of tea while it creates your normal map.

Capture1

sampledNormals

For a first attempt it succeeded quite well, especially considering all the warnings we were given of things that can go wrong.

Here is the model on sketchfab too: https://skfb.ly/6o7nR with wireframe and textures turned on so its easy to see the difference.

Brilliant stuff and although I already knew of their purpose, they’re as essential tool especially for making games. The illusion of extra detail rather than having to render extra polygons reduces the amount of draw calls needed and keeps a game engine running happily and efficiently. I look forward jumping into this more in future lessons, it’ll be a valuable skill.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s