# Displacement Map from Normal Map

This topic is 4460 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

I was wondering if anyone knew how to create a displacement map from a normal map? Any and all help is appreciated. Thanks, Chuck

##### Share on other sites
What Shader Language are you using.

##### Share on other sites
well I really just looking for the theory behind it then I can take it use it where I need it. but I can use HLSL easily in the context of the program.

##### Share on other sites
Please don't assume my post to be correct - what I'm about to say is based on my limited knowledge of what displacement and normal maps are, and as such isn't necassarily correct.

Anyway...
A normal map can be used to determine the slope of the 'surface' compared to a flat surace (normals are perpendicular to the surface they represent). A displacement map is simply a measure of the distance from the surface (a map of 'heights').

By picking a displacement to start at, you could calculate and use the slope at between points to get the displacement of each point (point 1 is at height 4, the slope between 1 and 2 is -2, so point to is at height 2 - just do the same basic idea on a 2D plane...).

A normal map wouldn't be able to give the actual height of each point though - just their height relative to each other.

##### Share on other sites
Correct, you could only do this in a relative since, so it would not be an absolute displacement. But I think that this is really all that you need. I have a few ideas on how to do this from other sources but wanted to see what other people could come up with.

1. 1
2. 2
Rutin
24
3. 3
4. 4
JoeJ
18
5. 5

• 14
• 23
• 11
• 11
• 9
• ### Forum Statistics

• Total Topics
631766
• Total Posts
3002235
×