How to do it...

Let's start this recipe by creating the material that we'll use throughout, and also setting up some settings in it:

  1. Create a new material and give it a name. We've gone with M_ Walls_ QualitySwitch this time. Double-click on it to open up the material graph. 

Just like we did in a previous recipe, we'll want to use tessellation in this material, so select the main material node and look at the Details panel to change certain parameters.

  1. Head over the the Tessellation panel and choose PN Triangles instead of the default No Tessellation option under the D3D11 Tessellation Mode setting.
  2. Turn Adaptive Tessellation on and set the Max Displacement to 100.

Doing that will allow us to use the tessellation technique we've seen ...

Get Unreal Engine 4 Shaders and Effects Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.