Creating a procedural texture map

To give the ground plane a dirt and grass look, a fractal procedural texture will be added to the ground's material color. A procedural texture means the look of the texture is driven by attributes and drawn by mathematical functions. You will also experiment with the drag and drop capabilities of the Hypershade.

1 Ground material

• In the Hypershade, clear the work area by holding down the right mouse button and selecting Graph ^ Clear Graph or press the Clear Graph button at the top of the Hypershade.

The Clear Graph button

This clears the workspace so that you can begin working on a new shading network.

  • From the Create bar section, create another Lambert material.
  • In the Attribute Editor, change the name of the Material node to groundM.

2 Fractal texture

The ground plane looks quite flat in shaded mode, and could use a grainy texture. Adding a fractal procedural texture will greatly help to enhance the look of the ground.

• In the Create bar section of the Hypershade, scroll down to the 2D Textures section. This section allows you to create new textures.

95

MMB+drag a Fractal from the Create bar anywhere into the work area.

In the work area of the Hypershade, click with your MMB on the Fractal icon and drag it onto the groundM Material node.

When you release the mouse button, a pop-up menu appears offering you a number of attributes that can be mapped by the fractal texture.

Select color from the menu to map the fractal to the Material node's color attribute.

Click on the Rearrange Graph button at the top of the Hypergraph panel.

incandescence transparency bump map displacement map Other... Shift+Diop

MMB+drag from the fractal onto the material incandescence transparency bump map displacement map Other... Shift+Diop

MMB+drag from the fractal onto the material

The Rearrange Graph button

Tip: Rearranging the work area will organize the view so connections appear from left to right. This is very useful for following the flow of connections.

Assign the material

• Select the ground, then RMB on your material groundM and select Assign Material to Selection.

Assign to selection

Tip: This method of assigning materials works better than the click+drag method when you want to assign a material to multiple objects.

4 View the texture

In order to see the texture in the viewport, you will need to enable hardware texturing.

  • Over the Perspective window, click with your MMB to make it the active window.
  • Open the hotbox and select Shading ^ Hardware Texturing.
Hardware texturing

Tip: You can also turn on hardware texturing by making the desired panel active and pressing the 6 key.

5 Edit the fractal attributes

  • In the Hypershade, click to select the Fractal node.
  • In the Attribute Editor (Ctrl+a to show it if hidden), open the Color Balance section.
  • Click on the color swatch next to the Color Gain attribute.
  • Choose any green and click the Accept button.
  • Click on the color swatch next to the Color Offset attribute.
  • Choose any brown and click the Accept button.
  • Under the Fractal Attributes section, tweak the attributes to your liking. The attributes found in this section control the way the fractal is being evaluated.
  • At the top of the Attribute Editor, select the place2dTexture tab. This tab shows different placement options for the fractal texture.
  • Change the fractal's placement attributes as shown below:

The Attribute Editor allows you to easily update the look of a procedural texture to your liking.

97

Ground texture

Note: The viewport texture shading is a representation of what your textures looks like, but it might not reflect perfectly how your scene will render.

6 Display the whole shading group

• With the groundM texture selected in the Hypershade, click on Input and Output Connections.

Input and Output Connections button

This displays some other nodes that help define this shading group.

  • Press the Alt key and click+drag with your left and middle mouse buttons to zoom out.
  • Press the a hotkey to frame everything in the view.
Complete shading network
98
0 0

Post a comment

  • Receive news updates via email from this site