image1 image2 image3 image4 image5 image6 image7 image8


Sand Mesh and Material

This lesson will take us through the procedure of making a Procedural Deserted Land while we create a Sand Material and a Procedural Terrain by using Procedural Maps and Procedural Modifiers.

01          We will start by creating a plane in the scene which will define the sand layer. Name it as ‘Sand Plane’ and set its Length and Width to 200 feet each. We will also increase the Length and Width Segments to 100 each in order to provide enough segments for creating the sand dunes displacement.

02          We will add some elevation over the plane by using the Noise Modifier. As we require the elevation on the plane in Z axis, therefore we will Increase the ‘Z Strength’ value to ‘16’ and further scale the noise up by increasing the ‘Scale’ value to ‘400’. Apart from th is smooth uneven surface of the sand we will add another layer of dunes on top of it with the help of ‘Displace' modifier.

03          Now in order to make the 'Displace' modifier work we will add a map onto it which will define the form of Displacements. Open the Materials and Map browser by pressing 'M' on the keyboard and create a 'Standard Material' inside it. Apply a 'Noise' Map inside the 'Diffuse' color map of the material and paste an Instanced version of this Noise map into the 'Map' option of the Displace modifier.

04          Dive inside the Noise map settings and change the Noise 'Strength' parameter to '5' feet while turning on the 'Luminance Center' option in order to get the right level of the displacement. Now to get the displacement similar to the shape of the dunes over the land surface increase the Noise 'Size' option to '300' and 'Noise Type' to 'Turbulence' while hitting the 'Swap' option for changing the function of black and white colour in the displacement. Bring down the 'High' parameter value to '0.6' to stress the noise displacements on the geometry.

05          Make the surface a bit smoother by bringing down the noise ‘Levels’ value to ‘2.5’ and by increasing the segments on the Plane to '300' each. Further to give a bit more depth to the sand surface we will create a new ‘Composite’ map inside the ‘Slate Material Editor’. Pipe in the output of ‘Noise’ map into the ‘Layer 1’ input of ‘Composite map’ while piping out its output into the ‘Diffuse’ map input of the Material. Replace the noise map in the Displace modifier with the instance of ‘Composite’ map by just dragging its output up to the Image Map browser button.

06          Add another layer inside the Composite map by hitting ‘Add a New Layer’ button next to ‘Total Layers’ parameter in order to stratify all the detail that we like to have over the map to obtain a different sandy terrain. Add in another ‘Noise’ map as the second layer while bringing up its size to 150 and changing the ‘High’ and ‘Low’ values to ‘0.7’ and ‘0.3’ respectively.

07          We will use this Noise map to remove some detail over the older Noise map by changing its ‘Blending Mode’ to multiply. This will bring some randomness in the sand surface by giving us some areas with extra details and some with fewer details. Now we will add another level of detail by duplicating the ‘Layer 1’ and placing it on the top as ‘Layer 3’. Dive inside the ‘Noise’ map parameters of ‘Layer 3’ and bring down the size parameter to ‘150’.

08          Now in order to alter the influence of this layer on the sand surface we can change the opacity of the layer to a really lower value while also changing the blending mode to Average in order to average out the black and whites on the noise map. The result will be a subtle layer of dunes spread all around the sand surface leaving us just with the implementation of the sand shader onto it.

09          We will create a basic Sand shader for the sand surface so that we can use it with all the Rendering Engines inside 3DS Max. Create a new standard material in the Slate Material Editor with the name 'Sand' and change the 'Diffuse Color' to brown (130, 100 and 60) in order to give a sandy color to our material. Further to stratify multiple map effects into one material we will link a new 'Composite' map inside the Diffuse Color map parameters.

10          Connect a 'RGB Tint' map into the 'Layer 1' input of ‘Composite map’ and dive inside it. Change the ‘R’ color value to the shade of brown with the same settings as the diffuse color while changing the color values of ‘G’ and ‘B’ to black. Now we will try to randomise the shade of this brown color on the surface of the sand model by making the parts on the top of the sand surface brighter while darkening the lower parts.

11          We can do this by applying the ‘UVW Map’ modifier on the sand surface model while using the ‘Planner’ mapping vertically with the help of ‘Alignment’ settings in ‘Y’ axis. Hit the ‘Fit’ button in order to fit the planner gizmo to the height of the sand surface model. We will make these ‘UVW Map’ modifier settings applicable only on the 2nd map channel by changing the ‘Map Channel’ value to ‘2’.

12           Add another layer inside the ‘Composite’ map by hitting ‘Add a new layer’ button on top of the ‘Composite Layers’ menu. We will add a ‘Gradient Ramp’ map inside it and will change its ‘Map Channel’ value to 2 in order to link this map with the ‘UVW Map’ modifier settings. Right click on the ‘Gradient Ramp’ map inside the Slate Material Editor and choose ‘Show Shaded Material in Viewport’. Currently the Gradient Ramp map is getting displayed horizontally but in order to make it spread in vertical axis we will change the ‘W’ angle to ‘-90’ degrees. This helped us to achieve the effect of brighter areas on the top of the sandy surface while darker regions at the bottom.

13          Inside the Gradient Ramp Parameters replace the white color on the ramp with a brighter shade of yellow (200, 175 and 90). The grey areas on the ramp can get replaced with a darker tone of yellow (190, 140 and 50) while creating another copy of black flag in order to increase the black region on the ramp. Change the Interpolation settings to ‘Ease In Out’ in order to get a soft transition between black and darker shade of yellow on the ramp.

14          Jump back to the ‘Composite’ map settings and change the blending mode of Layer 2 to ‘Screen’ with only ‘40 %’ ‘Opacity’ value. We will now add in some more colour variations in the sand material by adding in another layer in our composite as the mid layer. We will use a ‘Noise’ map for this layer in order to add in some darker areas and some brighter areas based on the position of the noise. Increase the noise ‘Size’ value to ‘80’ as we will use a really big size for this map in order to replicate the realistic looking dark shades on the slopes and brighter shades on the mounts.

15          We will use this ‘Noise’ map to multiply the effect of darker and brighter areas on the maps by using the ‘Multiply’ blending mode inside the ‘Composite’ map settings. Decrease the ‘Multiply’ intensity value to ‘65’ and hit render to see the effect of this ‘Noise’ map. We will now try to add some thinner dots in our present result in order to simulate the sand presence and to enhance the look as right now we just have a general colour of the sand.

16          Add in a ‘Speckle’ map as the second layer in the ‘Composite’ map list with the ‘Size’ value of speckles as ‘1’. Change its ‘Blending Mode’ to multiply with the intensity value of ‘75’ in order to multiply the grainy effect on the current colour of the sand layer. In order to add some details in the current grainy look we will add in another layer of speckle map with almost the same settings but with a bigger speckle ‘size’ value of ‘2.5’.

17          Now we will add in some Specular over our material by increasing its ‘Specular Level’ value and ‘Glossiness’ value to ‘60’ and ‘25’ respectively. Also change the ‘Specular’ colour to a bright shade of brown while adding in a ‘Speckle’ map as the ‘Specular Level’ map. Increase the speckle ‘Size’ value to ‘1.0’ while also swapping the black and white colours of the Speckle in order to get the white grains in the specular gloss of the material.

18          With the current settings we might start getting a bit stronger ‘Specular’ on the surface of the material. Therefore in order to reduce it we will decrease the ‘Specular Level’ value and ‘Specular Level Map’ value to ‘20’ and ‘60’ respectively while increasing the ‘Glossiness’ value to ‘35’. This will help us in getting a hold of specular grains of the material.

19          Create another ‘Composite’ map for the ‘Bump’ input of the material and add in a ‘Noise’ map as its first layer which will help us in creating the unevenness over the sand surface. Increase the Noise ‘Size’ value and Noise ‘Level’ value to ‘200’ and ‘4’ respectively while selecting ‘Fractal’ as the ‘Noise Type’ in order to increase the level of details of the bump over the surface. Also decrease the ‘Bump’ map value to ‘10’ in order to reduce the bump level over the surface of the material.

20          Further to improvise the 'Bump' map detailing we will add in a 'Speckle' map inside the 'Composite' as the second layer with the Speckle 'Size' value '0.5'. Now to make the 'Bump' amount a bit controllable we will add in an 'Output' map to the 'Speckle' map while increasing the 'Bump Amount' in the 'Output' parameters to '2.0'. Also turn on the 'Invert' parametr in order to invert the RGB color values of 'Speckle' map for a finer looking grain. The last step might lead to a higher value of grain on the material so in order to noramlize the result change the 'Blending Mode' to 'Average' with the 'Opacity' value to '75'.

21          We will now try to replicate the effect of scattering of sunlight inside the reflections of the material. So for that we can pipe in a 'Fall-off' map inside the 'Reflection' input of the material while changing the 'white' color of the falloff to a brighter shade of yellow with 'Fresnel' as the 'Falloff Type'. Decrease the 'Index of Refrction' value to '1.2' in order to make the 'Reflectivity' more over the crest of the sandy terrain while less over the surface. Jump back to 'Sand' material settings and decrease the 'Reflection' map value to '35' in order to make this reflection effect less prominent and real.

Share this:



Post a Comment