324 chapter 9 ■ Normal Maps, Displacement Maps, Maya, and Decimation Master
In this example, we created a separate map per body part to increase quality in the final
product by allowing more texture space per body part and the use of multiple high-resolution
maps. To assign the maps, we need to create a displacement shader for each map we’ll apply
to the model.
The model in this example has eight UV regions, so eight maps are generated. The
resulting 32-bit TIFF files will be ready to apply to the mesh in Maya and should render
exactly as seen in ZBrush. To make sure each map is applied to the correct region of the
creature, open the UV Texture Editor and follow these steps.
- Marquee-select one quadrant of UVs and choose
Select → Convert To Faces (or press Ctrl+F9 on
your keyboard). You can also select a few U Vs
from one shell and then choose Select → Select
Shell to enlarge the selection to the whole UV
shell. Now in the Hypershade, apply the shader
with the corresponding map to the set of faces.
You can quickly assign shaders to selected faces
by right-clicking your shader in the Hypershade
and selecting Assign To Selection. - Once the faces that correspond to the UVs
in each region have their own displacement
shader applied, you are ready to render.
Because the Alpha Gain and Alpha Offset
settings are the same for all maps, there will
be no discernable seams between your maps
(Figure 9.42). Be sure that the Alpha Gain and
Alpha Offset values are correct for each file
node on each shader.
Setting Up 16-Bit Displacement Renders in Maya
While GoZ will set up your 16-bit renders for you, I find it valuable to understand exactly
what is being done “under the hood.” in this section I will show you exactly what process
to follow to manually set up a 16-bit displacement shader. Included on the DVD is a video
demonstrating how to render 16-bit displacement maps in Maya. The process for setting up
the shader is identical to that used for 32-bit maps. The difference comes in determining the
Alpha Gain and Alpha Offset values for the displacement map file node.
Because a 16-bit map does not have real-world scale baked in, you must adjust the
Alpha Gain and Alpha Offset values until the render appears correct. By using an expression
for Alpha Offset, you can just adjust the Gain value and Offset will update. Set Alpha Offset
to = - filenodename.alphaGain /2;. In this expression, replace filenodename with the name
of the current file node. You can find this at the top of the Attribute Editor window when you
select the file node (Figure 9.43). If the file node is called file2, use the expression = - file2
.alphaGain /2.
Test-render your displacement. If your Approximation settings are correct, you will
just need to raise the Alpha Gain value until the height of the displacement looks correct.
Figure 9.44 shows the Pixologic displacement test head. This figure illustrates a ZBrush render
of the test head on the left and a Maya render of the same head on the right. By adjusting Alpha
Figure 9.42 The final render with multiple
displacement maps