Você está na página 1de 18

With a Tutorial for 3DS Max 2011

Written and Illustrated by C. J. Madsen


Using and Understanding Bump
Mapping: The Theory and Application for
Creating Surface Detail in 3D Modeling
with a Tutorial for 3DS Max 2011
Written and Illustrated by CJ Madsen
January 2011
All technical illustrations, bump maps, and renders were created myself using Adobe
Photoshop CS4 and 3DS Max 2011. Screencaptures used in the tutorial are from Autodesk
3DS Max 2011. A base photograph of bricks was supplied by www.cgtextures.com. This
document was created in Framemaker 9.
www.coroflot.com/cjmadsen
cmadsen.work@gmail.com
Using and Understanding Bump Mapping
C. J. Madsen
Table of Contents
Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
Technical Theory
How Bump Mapping Works . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
Perturbing the Normals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
James Blinn . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
Use and Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
Tutorial . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
Bump Mapping a Brick Wall . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
Procedures

Set up the Scene:. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
Set up Continued... . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
Creating the Geometry . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
Modifying the Geometry . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
Texturing the Wall . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
Texturing Continued. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
Rendering the Scene . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
Textures for Tutorial
Diffuse Texture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
Bump Texture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
Conclusion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
Using and Understanding Bump Mapping Introduction 1
C. J. Madsen
Bump mapping is used in 3D computer
modeling to create surface detail like bumps
and wrinkles that allow for a more
convincing look. It is an efficient technique
for adding complexity and realism to an
object without further modeling or lengthy
rendering. It is useful for creating surface
textures such as the dimpled peel of an
orange, an embossed logo, or a brick wall.
A bump map is a grayscale texture map that
creates the illusion of bumps and surface
roughness by a process called perturbing the
normals. Because it is a surface shader,
geometry is neither added nor modified.
Bump mapping is often used in the video
game industry where file size and poly count
restrictions limit the amount of modeling.
This guide was written for artists, students,
teachers, and other 3D professionals. It is
intended to provide an understanding of
bump mapping, its uses and limitations,
along with a tutorial for application. Bump
mapping is common in most 3D modeling
packages and beginning to intermediate
artists will find this information useful.
Bicentennial quarter created from a cylinder
with a bump map.
A diffuse (color) and bump map applied to a
flat pane with one polygon to create a
detailed brick wall.
The 3DS Max Teapot rendered with the
same diffuse and bump map on the left.
Introduction
i
Using and Understanding Bump Mapping Technical Theory 2
C. J. Madsen
Bump mapping manipulates normals to
control light and shadow in order to create
surface detail. In lighting, the brightness or
darkness of a surface is relative to that
surfaces distance and orientation to a light
source. In 3D, a normals orientation to a
light source is used to calculate the surfaces
illumination.
A smooth, flat surface has normals pointing
in the same direction. When photons,
particles of light, hit an objects surface they
reflect or bounce off in a uniform manner.
An irregular or bumpy surface has normals
pointing in multiple directions and causes
the light to reflect in multiple directions.
Bump mapping forces light to treat a flat
surface as if it were bumpy. The process is
called perturbing the normals because the
bump map unsettles the normals by imitating
a tilt based on the intensity values of a
texture map. The intensity values are simply
how black (dark) or how white (bright) the
color is.
Mapping refers to a mathematical operation
or function that associates each element of
one set, in this case the pixels of the objects
surface, with the elements of a second set,
the pixels of the texture map. The surface
remains flat but the rendering engine,
deceived by the bump map, can only see the
perturbed normals and calculates it as
uneven surface.
Note: Normal vectors are invisible by default
and are not renderable.
Sphere with upper hemisphere
normals visible in red.
Cube with normals indicated in red.
1 How Bump Mapping Works
Normal: a vector that protrudes at 90 from the
center of a polygonal face to indicate its
direction.
Technical Theory
TIP To display the normal vectors of a face in
3DS Max select Show Normals on the Selection
rollout of an editable mesh or for an editable poly
add a Normal modifier.
Using and Understanding Bump Mapping Technical Theory 3
C. J. Madsen
Perturbing the Normals
To perturb the normals bump mapping
changes the brightness of each pixel on the
objects surface corresponding to the pixels
of a heightmap, acting as the domain and
codomain of the function.
Located within the texture, a heightmap
stores data on surface elevation and is used
to calculate the minimum and maximum
values with black being the lowest elevation
and white being the maximum elevation. The
intensity determines the relative height of a
faces normal from the cameras viewpoint.
When rendering an object with a bump map
darker areas will appear recessed and lighter
areas will appear raised.
James Blinn
James Blinn introduced the method of bump
mapping in 1978. With a bachelors in
physics, a masters in engineering, and a
Ph.D. in computer science Blinn was able to
devise techniques that were ahead of their
time and are still in use today. In addition to
bump mapping, Blinn developed
environmental mapping and the Blinn-Phong
shader. All three of these rely on vectors and
interpreting the way light and objects
interact in virtual 3D space. He is noted for
his work at NASAs Jet Propulsion
Laboratory animating the Voyager spacecraft
and animation for Carl Sagans Cosmos
documentary.
A. The normals on a flat, smooth
surface.
B. The normals on a bumpy, rough
surface.
C. A flat surface with a bump map
perturbing the normals.
A 512x512 bump map texture saved as a
jpeg. White areas will appear raised; black
areas recessed.
The bump map texture has been applied to
a single polygon plane. A slight blur to the
bump map results in a smoother bump
effect.
Using and Understanding Bump Mapping Uses and Limitations 4
C. J. Madsen
Realistically no surface is entirely smooth.
Small imperfections and pits cause light to
reflect and scatter. To achieve realism and a
sense of tangibility bump mapping is
effective and adds the irregular details found
in life. These are examples of surfaces where
bump mapping is best used: the dimpled peel
of an orange, a textured interior wall, an
embossed design or logo, human skin, rust,
dirt and grime, or a brick wall.
There are limitations to bump mapping and
its illusion will fail when used improperly.
Because the process neither adds nor alters
geometry, the silhouette and shadow of an
object remain the same. Imagine a sphere
with a bump map applied to make it look like
a lumpy ball of clay. When rendered, its
silhouette and shadow will be that of a
smooth sphere, even though the surface
appears bumpy. To achieve realism in this
situation additional modeling is needed or
the use of a displacement map.
A displacement map is almost identical to a
bump map with the key difference being that
the displacement map displaces geometry,
altering the underlying surface and
increasing the poly count. The results of
displacement mapping will be more accurate
at the cost of rendering time and system
resources like memory.
Using a bump map to create the treads on a
car tire is another situation where it would
produce poor results. However, it would be
of great use for creating the pitted and waxy
surface of the rubber.
Bump mapping is generally effective for
creating surface detail that is shallow. In the
example of the car tire, the treads are much
too deep to use a bump map, unless the tire
will be viewed from a distance. If a close-up
is required, bump mapping may not be a
suitable choice. Knowing when to use a
bump map depends on the level of realism,
the render quality, or poly count restrictions
of the model.
:A sphere with a bump map applied. Note
the perfect, circular silhouette and smooth
shadow.
:The same sphere with a displacement map.
Note the irregular silhouette and
corresponding shadow.
2
Use and Limitations
Using and Understanding Bump Mapping Tutorial 5
C. J. Madsen
When applying bump maps a bitmap file or a
procedural map may be used. Procedural
maps, such as noise or smoke, use a
mathematical algorithm to generate a pattern
or a random effect. With a bitmap, such as a
jpeg, grayscale images work best. White
areas are raised, and black areas are lowered.
This example illustrates the process for
creating and applying a bump map to make a
simple brick wall using 3DS Max 2011.
Textures have been provided at the end of
this guide (pages 13 and 14).
To save them, do the following:
1. Select the image and right-click. Then
select copy Copy Image.
2. Paste the image in any program such as
Photoshop or Paint.
3. Save as jpegs with respective names:
Brick Wall Texture.Diffuse.jpg
Brick Wall Texture.Bump.jpg
There are four sections in this tutorial:
Set up the scene so units and display
settings of this tutorial will match your
system.
Create and Modify the geometry.
Texture the brick wall using the
supplied bump and diffuse map.
Render the scene.
Bump Mapping a Brick Wall
Tutorial
This is the Bump map texture used in this
tutorial. This map provides the height
information.(Use the image on page 14)
This is the Diffuse or color texture used in
this tutorial. This map provides the color
information. (use the image on page 13)
T
Using and Understanding Bump Mapping Tutorial 6
C. J. Madsen
Set up the scene:
To produce the desired result and for ease of
use, it is important to first set up 3DS Max so
that the tutorials settings and your settings
match.
1. Load 3DS Max.
2. From the main menu bar select
Customize then in the drop-down list
select Units Setup.
3. In the Units Setup dialog box select US
Standard and Feet w/Decimal Inches in
the drop-down list.
4. Next to Default Units select Feet.
5. Select OK to close the dialog box.
6. Press F10 or select Rendering from the
main menu bar then in the drop-down
list select Render Setup.
7. In the Render Setup dialog box select the
Common tab.
8. Scroll down the rollout and open Assign
Renderer.
9. Next to Production, Default Scanline
Rendered should be displayed. If not,
select the box () next to it and choose
Default Scanline Renderer from the
Choose Renderer dialog box and press
OK.
Procedures
S
Using and Understanding Bump Mapping Tutorial 7
C. J. Madsen
The following settings are to limit aliasing
when rendering bump maps. Aliasing is the
jagged appearance at the edge of a curve or
diagonal line caused by low resolution.
10. In the Render Setup dialog box select the
Renderer tab.
11. In the Antialiasing section set the filter
to Cook-Variable from the drop-down
list.
12. In the Global Supersampling section,
check Enable Global Supersampler
13. Close the Render Setup dialog box.
After the tutorial, you may want to
experiment with different filters as each
yields a different look. Hovering the cursor
over the filters name gives a brief
description of its purpose.
TIP If your computer is a multi-core processor
selecting Enable SSE in the options section
should improve rendering speed.
Material Editor Setup
1. Press M on the keyboard to bring up the
Material Editor.
2. If it displays Slate Material Editor
select Modes, then select Compact
Material Editor and then close the
editor.
S
Set up continued...
The top text has been
filtered to prevent aliasing
while the bottom has not.
This is the Render Setup dialog
for the Default Scanline
Renderer. The settings change
depending on what renderer is
selected.
Using and Understanding Bump Mapping Tutorial 8
C. J. Madsen
1. From the Command Panel select
the Create tab to open the Create Panel.
By default, the Create Panel is normally
open.
2. Select the Geometry button.
3. Select Box from the Object Type rollout.
4. In the top viewport, click and hold the
left mouse button at any point (do not
release)
5. Drag the mouse to define the length and
width parameters for the box. (It does
not matter what size as we will change it
later.) Release the mouse button.
6. Without clicking, move the mouse up or
down to set the height and then click the
left mouse button. By looking in the
front, left, or perspective viewport you
will see the change.
7. Right click to complete the creation.
Creating the Geometry
C
This is the Command
Panel. Here you can
access the following
tabs, from left to right:
Create, Modify,
Hierarchy, Motion,
Display, and Utilities. By
default, this panel is
located on the upper,
right hand side of the
3DS Max window.
Here is the
wireframe view in
the top viewport. Its
good practice to
create geometry in
the top viewport to
ensure it is properly
aligned in 3D space.
The 3DS Max workspace displaying the box
in each viewport. Viewports are, clockwise
from top left: Top, Front, Perspective, and
Left. All are in wireframe mode except for
Perspective.
TIP With a viewport selected, press ALT+Q to
expand the viewport and fill the workspace. You
can also right-click on a viewports name and
change it from the popup menu.
TIP Pressing F3 in 3DS Max switches to
shaded mode.
Using and Understanding Bump Mapping Tutorial 9
C. J. Madsen
1. Select the box if its not already selected.
2. From the Command Panel select the
Modify tab to open the Modify Panel.
3. Just beneath the Command Panel the
object name is displayed. It should be
something similar to Box001. Highlight
this and type Brick Wall.
4. Within the Modify panel, move down to
the Parameters section.
5. Enter the following values:
Length: 1
Width: 10
Height 10
6. Next we want to position the Brick Wall
in the middle of 3D Space. Select the
Brick Wall if it is not selected already.
7. Press W on the keyboard or select
the Move tool from the main toolbar
8. At the bottom of the screen is the Status
Bar. Find the coordinate display for the
x, y, and z.
9. Right click the spinners for all three to
set them at 00.0.
10. The Brick Wall is now positioned in the
center of 3D space.
Modifying the Geometry
M
Click and drag in the
gray box with the
object name
Your screen should
look like this now.
TIP Naming objects is good practice. Your
workflow will be faster and more organized,
especially as the scene grows larger and more
complex.
You can change the
value by using the
spinners but it is faster to
double-click in the box
and type the value. Since
the units have been set
to Feet, you can type 1
and press enter. The
value will automatically
change to 10.0.
The status bar with coordinate display.
Spinners are the vertical arrows to the right
of the values they control.
TIP You should always model an object
centered in 3D space. Modifiers such as
symmetry and mirror will produce undesirable
results if not centered as the axis is set to
0,0,0.
TIP Pressing Z on the keyboard will zoom and
center the selected object in each displayed
viewport.
Using and Understanding Bump Mapping Tutorial 10
C. J. Madsen
Applying the Textures:
1. Select the Brick Wall.
2. Press M to bring up the Material Editor
3. With any sample slot selected, highlight
the name located beneath the tool bar
and type Brick Wall.
4. In the Blinn Basic Parameters section
click the button to the right of the color
swatch for Diffuse.
5. The Material/Map Browser opens.
6. Beneath Maps/Standard Maps, double-
click Bitmap.
7. A window opens to locate the file on
your computer.
8. Select the file Brick Wall
Texture.Diffuse.jpg
9. Press open and the window closes.
10. Navigate up the Material Editor by
pressing the Go To Parent button.
Texturing the Wall
T
Using and Understanding Bump Mapping Tutorial 11
C. J. Madsen
11. In the Material rollout, open the Maps
tab.
12. Place a check next to Bump and assign a
value of 250.
13. Select the button next to it that says
NONE.
14. Double-click Bitmap.
15. A window opens to locate the file on
your computer.
16. Select the file Brick Wall
Texture.Bump.jpg
17. Press open and the window closes.
18. Navigate up the Material Editor by
pressing the Go To Parent button.
19. With the object Brick Wall selected,
press the Assign Material to Selection
button.
20. To preview the diffuse (color) texture in
the viewport press the Show Standard
Map in Viewport button.
Texturing continued...
T
Remember, you will not be able to see the
bump map effect in the viewport. You must
first render the scene.
Using and Understanding Bump Mapping Tutorial 12
C. J. Madsen
1. Press F10 to bring up the Render Setup
Window.
2. Go to the Output Size section of the
Common Parameters rollout and change
the Width and Height values to 800.
3. Click in the Front viewport, then right-
click the word Front and select Show
Safe Frames. You could also press Shift
F4. This brings up a yellow frame within
the viewport and represents what the
camera will render.
4. If still in wireframe, press F3 to display
shaded mode.With the Brick Wall
centered, press Z and then zoom in to fill
the viewport entirely with the Brick
Wall.
5. You can now press F9 or the Render
button on the Render Setup Window.
6. After pressing either button, the
rendered frame and render progress
windows will appear.
Now you can experiment by rendering
without the bump map, changing the bump
values, using different Antialiasing filters, or
rendering from a different camera view to
observe how it affects the bump map. You
could also apply this same material to
different objects such as the Teapot.
TIP Press the Clone Rendered Frame Window
button to create a current copy. When you
experiment with changed settings you will want
something to compare the new render with.
R
Rendering the Scene
Sample document. Diffuse texture has been removed to decrease file size.
Sample document. Bump texture has been removed to decrease file size.
Using and Understanding Bump Mapping Conclusion
C. J. Madsen
Thank you for taking the time to read this document. I hope this summary of bump mapping was
informative and helpful.
Additional Resources:
Textures:
www.cgtextures.com
Tips, Tutorials, and Resources for anything CG related:
3D Total - www.3dtotal.com
The Area - http://area.autodesk.com/
CG Society - www.cgsociety.org/
3D World Magazine - www.3dworldmag.com/

The help section of 3DS Max and the Autodesk website have additional tutorials and
would be a starting point for anyone wanting to learn more about the software.
Thank you,
C. J. Madsen
www.coroflot.com/cjmadsen
Conclusion
C

Você também pode gostar