Height Maps and Pixel Displacement

Jack Leavey
2 min readFeb 4, 2022

Now that I am working in HDRP, one of the features available is utilizing pixel displacement for a height map. This allows you to take a plane (flat surface) and give it three-dimensional visuals. It’s great for finely textured walkways or walls!

First off, I took a simple cobblestone material and slapped in onto a plane.

A very flat cobblestone plane.

Now to make a height map, I grab the original diffuse map and drag it into photoshop.

Go to Filter > 3D > Generate Bump (Height) Map

Once the map is generated, you can go to Image > Auto Contrast if it is too bright.

Save and go back to Unity.

In the material, change the Displacement mode to Pixel. This will open up a new section called Height Map.

Drag the newly made height map into the aforementioned slot.

Before/After

The third dimension gives that extra detail to make something stand out!

There are several option to edit as well, such as the distance at which the height is visible. Try some of the options, but be aware of the performance cost!

--

--

Jack Leavey

I am a software engineer with years of experience branching into game development, specifically in Unity. Follow along for guides on creating game mechanics!