zbrush zmapper 2005 nov 30

Upload: kadriank

Post on 03-Apr-2018

241 views

Category:

Documents


0 download

TRANSCRIPT

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    1/100

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    2/100

    2

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    3/100

    1

    Document Orientation

    We wanted to give a reference not just on ZMapper, but on normal map concepts, so this is alarge document. But, you dont need to read all or even most of it to begin using ZMapper. Hereare some directions for starting with minimal reading:

    If normal mapping is a new concept to you, you may first want to read section 7,which talks about the concepts behind normal, bump, and displacement maps; but if

    youre comfortable with normal map concepts, you can ignore that section.

    For those familiar with ZBrush and with normal maps, section 2 gives a high-leveldescription of the normal map generation process. This may be all you need.

    To learn ZMapper by going through a detailed example, look at section 5.5.

    Section 3 deals with the special case in which youve had to re-create your modelwith a new topology, after having already detailed and normal-mapped the original

    model in ZBrush. If you do not need to change topology in this way, you do not need

    to read this section, nor will the example in section 5.6 be of interest.

    Section 6 gives a description of normal mapping tools that existed in ZBrush prior toZMapper; these tools may still be useful in many circumstances, and this chapter is

    included for convenience.

    For most purposes, most of the controls described in section 4 may be ignored. Infact, it is possible youll only ever use the controls described in sections 4.4.1, 4.4.3,and 4.4.4.

    More generally, reading chapter 1 will give you a one-page overview of what ZMapper can do

    and its workflow. Section 2 give a more detailed description of normal map creation (withoutexamples), and section 3 is the same thing for the specialized topic of projecting normal maps

    onto new topology. Section 4 is the detailed reference section. Section 5 gives detailed examples

    that illustrate the use of ZMapper, and the next sections cover normal map topics not related

    specifically to ZMapper. The final section is a simple ZMapper cheat sheet.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    4/100

    2

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    5/100

    1

    Table of Contents

    1. INTRODUCTION...................................................................................................... 11.1. Prcis of Normal Map Workflow.......................................................................................................................... 11.2. Projected Normal Maps ......................................................................................................................................... 22. NORMAL MAP GENERATION QUICK START....................................................... 32.1. Normal Maps from Subdivision Models.............................................................................................................. 32.2. Normal Maps from Bump Maps ........................................................................................................................... 3

    2.2.1. Creating Bump Maps In ZBrush ...................................................................................................................... 42.3. Normal Maps from Both Bump Maps and Subdivision Models...................................................................... 42.4.

    Cavity Shading ......................................................................................................................................................... 4

    2.5. Caveats and Tips ..................................................................................................................................................... 53. PROJECTING NORMAL MAPS ONTO NEW TOPOLOGY..................................... 73.1. Aligning the Initial and New Base Meshes .......................................................................................................... 7

    3.1.1. ZBrush Settings to Check ................................................................................................................................. 83.1.2. Workflow Issues ................................................................................................................................................ 8

    3.1.2.1. Workflow; Original and New Model from External Program ............................................................... 93.1.2.2. Workflow; Original Model in ZBrush, New Model Externally ............................................................. 93.1.2.3. Workflow; Original Single Model, New Model Broken into Pieces ..................................................... 9

    3.1.3. Aligning Rotations ............................................................................................................................................ 93.1.4. Aligning Scaling .............................................................................................................................................. 10

    3.2. Settings .................................................................................................................................................................... 114. ZMAPPER DETAILS.............................................................................................. 134.1. Installing or Starting ZMapper .......................................................................................................................... 13

    4.1.1. Installing ZMapper as a Plugin ...................................................................................................................... 134.1.2. Loading ZMapper Manually........................................................................................................................... 13

    4.2. The ZMapper ProcessWorkflow Reference ................................................................................................. 144.3. Map and Model Resolutions ................................................................................................................................154.4. ZMapper Interface Description and Reference................................................................................................ 16

    4.4.1. Navigating Around the Model........................................................................................................................ 164.4.2. ZMapper Control Panel and Control Types .................................................................................................. 164.4.3. Upper Controls ................................................................................................................................................ 17

    4.4.3.1. ZMapper Column ....................................................................................................................................174.4.3.2. Transform Column ..................................................................................................................................194.4.3.3. Mesh Column .......................................................................................................................................... 19

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    6/100

    2

    4.4.3.4. Morph Modes Column............................................................................................................................ 204.4.3.5. Wires Column..........................................................................................................................................224.4.3.6. Screen Column ........................................................................................................................................ 244.4.3.7. Display Column....................................................................................................................................... 254.4.3.8. Configuration and Preview Controls ..................................................................................................... 294.4.3.9. Subpanel Tabs (see bottom left of Figure 4) .........................................................................................30

    4.4.4. Normal & Cavity Map Tabbed Panel ............................................................................................................304.4.5. Projection Tabbed Panel .................................................................................................................................374.4.6. Expert 1 Pass and Expert 2 Pass Tabbed Panels ...........................................................................................38

    4.4.6.1. Expert Option Passes ..............................................................................................................................384.4.6.2. Surface Normal Interpolation .................................................................................................................384.4.6.3. Map Distortion Issues ............................................................................................................................. 394.4.6.4. Expert Options Summary ....................................................................................................................... 39

    4.4.7. Misc Tabbed Panel .......................................................................................................................................... 395. ZMAPPER EXAMPLES ......................................................................................... 415.1. Viewing a Finished Model ....................................................................................................................................415.2. Constructing a Normal Map from a Finished Model; Elephant ................................................................... 425.3. Constructing a Normal Map from a Finished Model; Troll ..........................................................................455.4. Creating Bump Maps for ZMapper ................................................................................................................... 46

    5.4.1. Viewing the Bump Map as you Create .......................................................................................................... 475.4.2. Tips and Tricks for Creating Bump Maps ..................................................................................................... 48

    5.5. An Example from Incept ion to Completion ...................................................................................................... 485.5.1. Creating the Geometry ....................................................................................................................................495.5.2. (Continued) Create a Bump Map ................................................................................................................... 505.5.3. (Continued) Create a Normal Map.................................................................................................................52

    5.6. Projecting a Normal Map Onto Different Topology ....................................................................................... 535.6.1. Projection Example ......................................................................................................................................... 535.6.2. Projection Troubleshooting ............................................................................................................................ 57

    5.6.2.1. Scaling Problems..................................................................................................................................... 575.6.2.2. Rotational Mismatches ........................................................................................................................... 585.6.2.3. Texture Map Problems............................................................................................................................ 595.6.2.4. Projection ExampleFixing Projection Problems ............................................................................... 59

    6. NON-ZMAPPER ZBRUSH NORMAL MAPPING TOOLS...................................... 646.1. Create Enhanced Detailing with ZBrush 2D, 2.5D and 3D Tools ................................................................. 646.2. Creating Seamless Alphas and Painting Bump Maps ..................................................................................... 656.3. Detailed Tutorial: Using Zbrushs Canvas to Create Normal and Bump Maps ........................................ 687. CONCEPTS BEHIND BUMP, DISPLACEMENT, AND NORMAL MAPS.............. 757.1. Bump Maps ............................................................................................................................................................ 757.2. Displacement Maps ............................................................................................................................................... 75

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    7/100

    3

    7.3. Surface Normals and Lighting ............................................................................................................................ 787.3.1. Surface Normals with Specular and Reflective Lighting ............................................................................. 79

    7.4. Surface Normal Perturbation..............................................................................................................................797.5. Bump Maps and Surface Normals...................................................................................................................... 807.6. Normal Maps.......................................................................................................................................................... 81

    7.6.1. Representing Normal Maps as Textures ........................................................................................................ 827.6.2. Normal Map Generation .................................................................................................................................83

    7.6.2.1. Converting From a Bump Map ..............................................................................................................837.6.2.2. Raytracing/Raycasting ............................................................................................................................ 84

    7.6.3. Normal Maps in Tangent and Object Space.................................................................................................. 857.6.3.1. Object Space Map Uses .......................................................................................................................... 867.6.3.2. Tangent Space Map Uses ....................................................................................................................... 877.6.3.3. How Does Your Application Distinguish Between Tangent and Object Space Normal Maps? ....... 877.6.3.4. Summary of Object Space and Tangent Space Normal Maps ............................................................. 87

    7.6.4. Cavity Shading ................................................................................................................................................ 888. ZMAPPER CHEAT SHEET.................................................................................... 898.1. Control Panels........................................................................................................................................................ 898.2. Model Navigation with the Mouse ...................................................................................................................... 898.3. Keyboard Shortcuts .............................................................................................................................................. 90

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    8/100

    4

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    9/100

    1

    1.Introduction1.1. Prcis of Normal Map WorkflowZMapper uses some of the unique features of ZBrush, such as multi-resolution subdivisionsurfaces, to make the creation of normal maps a quick and easy process. Section 4.2 gives a more

    detailed conceptual overview of the process, and the examples in section 5 give step-by-step

    instructions for generating normal maps, in order to illustrate the full range of possibilities. But

    heres a quick preview of a typical use of ZMapper, so you can have an idea of how it fits in withZBrush.

    1. Create a low-resolution model to your liking and (in ZBrush, using the multiplesubdivision levels feature) a high-resolution model that is a subdivision of the low-resolution model.

    2. Choose a texture size for the normal map.3. Add a bump map if desired, for high-frequency detail.4. Start the ZMapper plugin and use it to create a normal map for the low-resolution model.

    The map will incorporate both the differentials in geometry between the low- and high-

    resolution models, and the details of the bump map.

    The world below shows how well an extremely high-resolution model can be mapped to a very

    low-resolution model, given the appropriate geometry.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    10/100

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    11/100

    3

    2.Normal Map Generation Quick StartThis section is for readers who already possess a reasonable familiarity with ZBrush and the

    concepts of normal maps. It gives you the bare details you need to get going, without going into

    material youre likely already familiar with. If you do want to look at certain aspects in more

    details weve provided all of the appropriate cross-references.

    A good first step would be to follow the instructions for viewing the examples in sections 5.1 and

    5.2. This will take just a few minutes, and will expose you to all of the basic ZMapper features.

    Not included in this section is the process of projecting a previously generated normal map onto

    a new model with a different topology.

    2.1. Normal Maps from Subdivision ModelsZBrush exploits its powerful multi-resolution subdivision modeling feature to allow easy

    creation of normal maps from a single model sculpted at both low and high resolutions. The

    process is simple:

    1. Install or load ZMapper. (See section 4.1.)2. Create the low-resolution Polymesh3D model you want to start with, and make sure it

    conforms as closely as possible in shape to the high-resolution mesh that will be

    expressing all of the details.

    3. Using the ZBrush tools you are already familiar with, iteratively subdivide the model andsculpt finer and finer detail, until you have the desired final result.

    4. Create and select a texture that will hold the normal map. It must be square, and its sidedimensions must be powers of two. (256, 512, 1024, and so on.) To capture all of the

    detail, the normal map area used (i.e. that portion not left blank by the UV mapping)should have about as many pixels as the high-resolution model has polygons. ZMapper

    will use whatever UV mapping you choose for the model.

    5. Set the model to its lowest subdivision setting. The selected level is the model level forwhich the normal map will be generated.

    6. Start ZMapper. Select Tangent Space N.Map or Object Space N.Map to choose betweengenerating a tangent or object space normal map. Open the Normal & Cavity Map tab, and

    press Create Normal Map.

    7. Once the normal map is complete, exit ZMapper. The finished texture map will be in thetexture palette.

    2.2. Normal Maps from Bump MapsAnother way to produce a normal map is to start with a bump map, and convert it to a normalmap. This has the advantage that the resulting normal map no longer has the intensity

    adjustment problems that can be encountered with bump maps, when transferring them between

    different programs. Even better, bump maps can be used along with the techniques described in

    section 2.1. The process is straightforward.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    12/100

    4

    1. Choose a polymesh 3D model for which you wish to generate a normal map.2. The bump map will be a grayscale texture map that has a UV mapping to the model. Get

    it into the Alpha palette and select it as the current alpha map. The bump map dimensions

    should be between one to two times the dimensions of the final normal map. (So if your

    normal map is 1024x1024, choose a bump map from 1024x1024 to 2048x2048.) Less

    than this, and theres not a lot of point in using a bump map. More than this, and you riskputting a lot of work into the details of the bump map that will then be filtered out

    because the normal map resolution is not high enough to support them. If you have

    enough memory, we recommend using a larger bump map than the normal map, and just

    keep in mind when editing that very fine details in the bump map will not come through.The higher resolution will still probably improve quality on the larger details.

    3. Create a texture that will hold the generated normal map. The restrictions outlined in theprevious section as regards to normal map dimensions apply. (Square, power of two.)

    4. Set Tool:Displacement:Displacement Intensity to about 0.05. After a highly rigorousevaluation, this figure was chosen because it seems to work pretty well most of the time.

    Feel free to experiment. This is the setting that tells ZMapper the chosen alpha map is tobe considered a bump map, and with what intensity to apply it.

    5. Go into ZMapper and, as in the previous section, choose the type of normal map togenerate and then create it. When it has been created, exit ZMapper and your normal map

    will be in the texture palette and ready for use.

    2.2.1.Creating Bump Maps In ZBrushYouve no doubt thought, Aha, I can use ZBrush to create great bump maps as well, to use in

    the above process. Youre right, of course. There is a plethora of ways to generate the requisite

    grayscale bump map from within ZBrush. You can paint directly to the 2.5D canvas and then

    grab an alpha off of there. Using Projection Master with the BumpViewerMaterial, you can painta grayscale texture onto your model, and then create an alpha from that. Some of these

    techniques are discussed in section 6. The experienced ZBrush user will no doubt come up with

    many more.

    There are some points here you should be aware of, pertaining to the relative resolutions of the

    various map that come into play. See section 4.3 for details.

    2.3. Normal Maps from Both Bump Maps and Subdivision ModelsIts easy enough to combine the above two ways of generating normal maps. Just make sureyouve followed the steps in section 2.2 so that you have an appropriate bump map alpha

    selected, and that youve followed the steps in section 2.1 so that you have a subdivision modelset to its lowest level. Then go and create the map as usual. Both the geometry and the bumpmap will be incorporated.

    2.4. Cavity ShadingStrictly speaking, cavity shading (a form of simulating ambient occlusion) has nothing to do inconcept with normal mapping, but it turns out to be easy to incorporate a cavity shading effect

    into the normal map process, at no further end-use cost. ZMapper has the ability to produce and

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    13/100

    5

    integrate cavity shading. The process is not difficult, but there are a number of settings that affect

    the final result, so rather than go into it here, Ill refer you to section. 4.4.4.

    2.5. Caveats and Tips ZMapper will do its best, but no normal map generator can compensate for models

    whose large-scale structure varies significantly between the high-resolution and low-resolution models. In other words, dont turn a hillock in your low-resolution model

    into a tree in your high-resolution model, and expect to come up with anything

    intelligible.

    Another no-no is producing elements in the high-resolution model that fold over,where they did not do that in the low-resolution geometry. This produces a situation

    where one point in the normal map must represent two different normal directions

    (depending on viewing angle, no less!), and that simply isnt possible. Youllprobably end up with a normal map, but not one youd want to use.

    Creating normal maps between a very low-resolution model and a very high-resolution model can be problematic. For example, if your starting geometry is a

    single quad, and you then take that up to a million quads for the high-resolution

    model, ZMapper may have difficulties. The solution is to start with a higher-res low-

    resolution model (say 100 or 10,000 quads), and produce a normal map for it. Then,you can remap that normal map to a single quad to get the effect you want.

    If at any point you need more detail in the steps outlined above, look at section 5.5. Itattempts to give a very simple but thorough example touching on almost every aspectof normal map generation discussed here.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    14/100

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    15/100

    7

    3.Projecting Normal Maps Onto New TopologyOnce youve created a normal map for an object, you may find you need to change the base

    topology of your original low-resolution mesh, in order to allow better deformation duringanimation, or for some similar reason. However, the new base mesh will of course not have any

    of the sculpted detail applied to the original mesh with ZBrush, so a normal map cannot begenerated for it in the same way. In order to allow reuse of the original sculpted model, ZMapper

    provides the Projection tab.

    Figure 2. The Projection Tab

    Simply put, these controls allow you to make use of the detail from the original mesh by fitting it

    over the new mesh, and projecting that detail onto the new mesh as the normal map is beingbuilt.

    Conceptually, the process is fairly simple. It consists of the following steps.

    1. Build and sculpt the initial modelcall it modelA.2. Build and import the new base meshcall it modelB.3. Ensure the two meshes are properly aligned and scaled within ZBrushs coordinate space.4. Choose the original mesh (A), go into ZMapper, and click Capture Current Mesh in the

    panel above. This will remember modelA as the mesh from which detail is being

    projected. Then leave ZMapper.

    5. Choose modelB, ensure UV coordinates have been assigned to it (if not assigned beforeimportation into ZBrush), enter ZMapper, and click Create Projected NormalMap. This

    creates a new normal map forB by raycasting the details ofA onto it.

    There are various settings you can use to affect the quality of the final result, but the mostimportant thing is just to make sure that the original low-resolution mesh and the new low-

    resolution mesh fit together as closely as possible; youre not going to be able to transfer the

    detail from a ducks head into a normal map for a robin. If your new mesh ends up being

    differently shaped in some places than the previous mesh, you can try resculpting the original inZBrush to better fit the new; this should keep most of the high-resolution details.

    The remainder of this chapter discusses some of the concepts and details youll need to

    understand to make working with raycasting easy. A full example is presented in section 5.6, and

    the controls are detailed in the section 4.4.

    3.1. Aligning the Initial and New Base MeshesAside from being as identical in shape as possible, the base meshes also need to be identically

    aligned with respect to global location, scaling, and rotation, to obtain the ideal result. If they are

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    16/100

    8

    not aligned, the mismatches will show up when you go into ZMapper, and you can correct them

    using the techniques described below. Examples of this are given in section 5.6.

    There are a couple of things that can affect whether or not you need to deal with alignment

    problems. Controls described below can have an effect; more importantly, certain workflows can

    require dealing with scale issues. These are also discussed below. The simple case, where thesettings below are left at their default values and the models being worked with are single-piecemodels built in an external program, should not cause any alignment mismatches.

    3.1.1.ZBrush Settings to CheckYou should be aware of two controls in ZBrush that might affect scaling, and one set that canaffect rotation. These are the Preferences:Importexport:Unify Scale setting, the Tool:Export:Scale

    setting, and various of the flip settings in Preferences:Importexport . If you encounter

    unexpected alignment problems, check these controls to ensure they are set at reasonable values.

    The default values are reasonable for almost all cases.

    Tool:Export:Scale does what you might think from the name; it scales the mesh up or down onexport. For example, if you import a 1x1x1 cube, set Tool:Export:Scale to 2, and then export the

    cube, youll get a 2x2x2 cube. The default for this setting is 1, and you should normally leave it

    at that.

    The other scaling setting, Unify Scale, affects the scale factor that is used to change from external

    coordinates to ZBrush internal coordinates when a model is imported or exported, and the

    simplest thing to do with it is just not change it. Regardless of what this control is set at (the

    default is 4), if you import an object, sculpt it, and then export it without changing Unify Scaleand with ToolExport:Scale = 1, the exported object will have the same size as the imported

    object, and you wont encounter scaling issues.

    The flip settings in Preferences:Importexport are all off by default, and should normally left thatway when using ZMapper. If you do find a model is flipped when it is imported, you can activatethe appropriate ones of these switches and import the model again, but its probably faster to use

    the technique described in section 3.1.3.

    3.1.2.Workflow IssuesThere are all sorts of different workflows that might be employed when building an original

    mesh and then a similar mesh with a new topology. For example, you might sculpt the original

    mesh from a ZBrush primitive, export the base level, use an external program to produce a new

    topology, and then import that new topology. Or you might produce both the original topologyand the new topology in a single program, and import both into ZMapper. Or, conceivably, one

    artist might produce the original mesh in one program, sculpt it in ZBrush, and then somehow

    transfer the original base mesh to another artist who uses another program to produce anothermesh with a different topology but the same shape. Regardless of workflow, the end goal is to

    project normal maps in ZMapper, and to do that the models need to be as closely aligned in

    ZMapper as possible.

    Lets discuss a few common workflows, and some of the things you might need to think aboutwith each of them.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    17/100

    9

    3.1.2.1. Workflow; Original and New Model from External ProgramIn this instance, you build the initial head in your favorite modeling package, import into

    ZBrush, and sculpt. Then, it turns out that the original head topology isnt satisfactory, so you goback to the modeling package, and build the new topology exactly over the old topology; eyes

    are in the same place, nostrils in the same place, etc. Most particularly, the width, height, depth,

    and origin of the models are the same. When thats done, you import the new topology intoZBrush.

    In this case, you shouldnt encounter any problems whatsoever. Since the dimensions and origins

    of each model are the same, theyll undergo identical scaling in ZBrush, and should line up just

    as well in ZBrush as they do in the external modeler.

    3.1.2.2. Workflow; Original Model in ZBrush, New Model ExternallyThis is the case where youre a sculptor who just loves ZBrush, and would never want to start a

    model any other way. So you begin with a ZBrush sphere, convert it to a polymesh, do all of

    your sculpting in ZBrush, and export one level (probably the base level) of the polymesh. Then

    you or someone else builds the desired topology around that exported mesh using a program ofchoice, and finally the new mesh is imported back into ZBrush for projection of the normal map

    onto it.

    In this case, you may find in ZMapper that the imported model is scaled differently than the

    original model. (This occurs because by default, ZBrush rescales imported models to fit in anoptimal working area of the ZBrush coordinate system.) The fix for this is found in section

    3.1.4.

    3.1.2.3. Workflow; Original Single Model, New Model Broken into PiecesHere, an initial model is made, imported into ZBrush, and sculpted. A new model is then made,

    broken into pieces, and the pieces are imported separately into ZBrush for normal mapprojection.

    A naive import of the pieces will result in them having scales different from the sculpted model.

    The fix here is the same as the fix for the previous workflow case, and is described in section3.1.4.

    3.1.3.Aligning RotationsThe fastest tool for aligning mismatched rotations is the Tool:Preview subpalette. When opened,it displays the current tool in its current global orientation, with thez-axis going straight into the

    screen. By dragging anywhere on the image except the small red cross, you can rotate the

    preview (the dark plane is thexy plane); and by holding down the Shift key as you rotate, youcan force the object to rotate in 90 degree increments. Finally, clicking the Store button will resetthe rotation of thex,y, andz planes so that the objects new global orientation is visually the

    same as the last position youd moved it to. The figure below makes this clearer.

    Figure 3. Changing Global Rotations With the Preview PanelThe three images below show (a) the preview of the Polymesh3D star tool, the currently chosen

    tool; (b) a rotation of the preview image, with the dark xy plane indicating that the rotation of the

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    18/100

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    19/100

    11

    4. With Cstill selected, use Tool:Import to importB. A new tool will be created fromB,replacing Cand with the same scaling as C. Since Chas the same scaling asA, the newtool will also have the same scaling asA.

    In a slightly different scenario, we create the new meshB, and split it into piecesB1,B2,B3, etc.

    In this case, we simply create multiple clones C1, C2, and C3 ofA, and using the process above,

    replace C1 withB1, C2 withB2, and C3 withB3.

    3.2. SettingsThere are a number of settings that affect projected normal maps. They are described in the

    reference section. However, you shouldnt normally need to use them, since ZMapper ships witha large number of predefined configuration files, one of which is likely to be correct for your

    needs. As of this writing, the files shown below are part of the distribution.

    When setting values for projections, note that you cannot incorporate bump maps or cavityshading when creating normal maps via projection. Bump maps can be used when generating the

    initial normal map, and their effect will then appear in the projection.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    20/100

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    21/100

    13

    4.ZMapper DetailsThis section is the main reference for using ZMapper. It describes the methods that can be used

    when generating normal maps with ZMapper; ZMapper installation; the standard steps and basicknowledge of controls needed to produce normal maps; and provides a reference to the ZMapper

    controls.

    It does not go deeply into specialized details, since many of those details are applicable only in

    special cases and will not be of interest to those first learning ZMapper or looking for a referenceto basic ZMapper workflow. Section 5 gives examples showing advanced ZMapper techniques.

    4.1. Installing or Starting ZMapperIn order to use the plugin, youll have to make sure it is loaded. There are two ways of doingthis. ZMapper can either be installed as a plugin, meaning it will automatically load whenever

    ZBrush is started, or it can be loaded manually whenever you wish to use it. Both methods are

    described below. In general, installing ZMapper as a plugin is probably the way to go; ZMapper

    adds just one button to the user interface, and requires no significant resources when not beingused.

    4.1.1.Installing ZMapper as a PluginFirst, locate the home ZBrush folder, the one containing the ZBrush application. This can bealmost anywhere on your system, depending on how ZBrush was installed, but good places to

    look first are /Applications/ZBrush2 (on a Macintosh), or C:\Program

    Files\Pixologic\ZBrush2 (on a PC). If you cannot find it easily, use your computers find

    file function to search for ZBrush.

    Within the ZBrush home folder should be a folder called ZStartup. Inside that folder, create a

    folder called ZPlugs, if it does not already exist.

    Finally, copy or move the ZMapper files (ZMapperData and ZMapper.zsc) into the ZPlugs

    directory.

    The next time ZBrush is started, it should automatically load ZMapper. If you then open the

    Zplugin palette, youll see a button called ZMapper. Pressing this button will start ZMapper.

    4.1.2.Loading ZMapper ManuallyTo load ZMapper manually into ZBrush, make sure you know the location of the folder

    containing the ZMapper plugin and its associated files. From within ZBrush, open the Zscript

    palette and press Load. Using the file open dialog that comes up, locate and load the fileZMapper.zsc, that will start it just as if it had loaded as a plugin

    Once this is done, pressing ZMapper in the Zplugin palette will start the ZMapper plugin.

    If you use this method, youll need to load ZMapper each time you start ZBrush.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    22/100

    14

    4.2. The ZMapper ProcessWorkflow ReferenceThe steps below specify how the ZMapper plugin is used from ZBrush, without going intoZMapper details. See section 4.4, more detailed examples and explanations of the options

    available in the ZMapper plugin.

    1. To begin, create or obtain a low-resolution mesh in ZBrush. There are two ways of doingthis. First, you can create a Polymesh3D tool in ZBrush and use that. Or, you can import alow-resolution mesh from another application..

    2. Once the initial mesh is in ZBrush, edit it as you normally would. This typically consists ofsubdividing the mesh and then adding detail at higher and higher levels of resolution untilyou are satisfied with the final detail.

    3. In the Texture palette, create a new custom texture or select an existing custom texture intowhich the normal map will be written. If no texture has been created for the model, a new

    texture with a default size will be created.

    4. If you wish to incorporate a bump map in the generated normal map, select it as the Alphapalette map and set Tool:Displacement:Intensity appropriately. (See examples for further

    details.)

    5. Set the subdivision of your model to show the low-resolution model for which you arecreating a normal map.

    6. Activate the ZMapper plugin by pressing the ZMapper button. Unless the UI configurationhas been customized, this button can be found in the Zplugin palette. The display will show a

    preview screen containing your model, and a control panel for setting options and generatingnormal maps.

    7. Select either tangent coordinates or object coordinates, then create the map. There are anumber of other options that may also be set before map creation, to affect various aspects of

    the final appearance.

    8. Exit ZMapper. The created normal map will appear in the ZBrush Texture palette, and maybe exported like any other texture.

    Of course, the above is just a recipe that doesnt really indicate all of the possibilities. Here aresome of the many ways you can alter this recipe.

    Create a model in ZBrush, then subdivide and sculpt it to a certain level. Create avery high-resolution texture map and paint it with displacement information using

    Projection Master. In ZMapper, generate a normal map that incorporates both thehigh-level sculpted details and the painted displacement information.

    Import an externally generated model and a bump map for it. Use ZBrush to sculptfurther details into the model, then apply both that information and the previouslyexisting bump map to generate a comprehensive normal map.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    23/100

    15

    Import an externally generated model and a displacement map for it. Subdivide themodel in ZBrush to show an extremely high level of detail, and use the displacementmap to produce a subdivided model whose geometry actually reflects the geometry

    implied by the displacement map. Refine the model and then use ZMapper to create a

    normal map without further need for reference to the original displacement map.

    The details of all of these techniques are described throughout section 4, and examples of themmay be seen in section 5.

    4.3. Map and Model ResolutionsIn spite of the nondescript title, the information in this section is quite important to achieving the

    best normal map possible. When working with ZMapper, there are up to four different

    resolutions you must consider:

    The resolution of the 3D object being mapped, in terms of number of polygons anduniformity of distribution.

    The resolution of the final normal map. If creating a bump map in ZBrush, the resolution of the bump map. If using Projection Master as part of the process, the resolution of the canvas.

    For optimal results, you need to make sure that all of these resolutions are set to be compatible

    with one another. Heres how to do it.

    Assuming the polygons on your high-resolution model are distributed fairly equallyover the UV unwrapping of the model, the number of pixels in the normal map (i.e.,

    map pixel height times map pixel width) should be about equal to the number of

    polygons in the high-resolution model. If you have many more pixels than polygons,many pixels will end up mapping to the same polygons, which means your map will

    be carrying redundant information. Conversely, if you have many fewer pixels thanpolygons, some of your polygons will not be reflected in the normal map, and detail

    will be lost. Note that whenever you increase the size of a normal map, the number ofpixels in it goes up by a factor of four, which might make it hard to get a good match

    for the number of model polygons. If your end use application can handle it, too

    many pixels will give better results than too few in this case.

    If you will be incorporating a bump map, the bump map dimensions (width andheight) should generally be between one and two times the width and height

    dimensions of the normal map. Bump maps smaller than this will not be taking fulladvantage of the detail they can contribute to the normal map, and bump maps larger

    than this may lose fine detail when rolled into the normal map. Note that bump map

    dimensions are not constrained to have the same width and height, or to be powers of

    two.

    If using Projection Master to create a bump (or similar) map, we need to consider theresolution of the ZBrush canvas. The rule is that there should be an approximate one-

    to-one correspondence between pixels on the canvas and mapped pixels on theviewed portion of the model after it has been dropped, assuming it is sized so as to fill

    most of the canvas. This ensures that any change to a pixel on the canvas will result in

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    24/100

    16

    a more-or-less equivalent change to a pixel (or a couple of pixels) in the bump map.

    When working with a flat one-sided model such as a plane representing a wall, thismeans that the resolution (and for that matter, the pixel dimensions) of the canvas

    should be about the same as the model. If the model is two sided, then on average

    only one-half of its mapped pixels will be exposed at any time, so the number of

    pixels on the canvas should be about half of the number of pixels in the bump map.

    4.4. ZMapper Interface Description and ReferenceOnce in ZMapper, youll be presented with your model and the ZMapper control panel. Basic

    navigation around the model can be done using the mouse. Everything else is done with thecontrol panel.

    4.4.1.Navigating Around the ModelAs in ZBrush proper, ZMapper provides quick ways of viewing your model from differentangles, zooming in and out, and so forth. These are described below. In addition, some of the

    control panel options affect model navigation, as discussed in section 4.4.3.2.

    NOTE: These techniques apply only if the Rotate transform mode is selected. See the

    description of the Transform controls in section 4.4.3.2 for full details.

    Rotate Model: Click and drag on the model or the display background. If the Spin switch in the

    control panel is on, the model will continue to rotate after the mouse button is released, in the

    direction of the drag. The speed of the rotation corresponds to the speed of the mouse at the end

    of the drag.

    Pan Model: Hold down the space bar while you click and drag the mouse on the model or

    background.

    Zoom Model: Right-click and drag on the model or background.

    4.4.2.ZMapper Control Panel and Control TypesThe ZMapper control panel appears along the bottom of the ZMapper screen. It contains an

    upper portion and several other sections that may be accessed via tabbed pages. See Figure 4.

    ZMapper uses the standard control types in its interface; buttons, tabs, etc. These are describedbelow.

    Buttons such as Exit are shown as a lighter gray outlined area, containing the button text.

    Pressing on a button causes an action.

    Switches such as Spin are shown as text drawn on a darker gray background if deselected; and astext on a yellow background if selected. Switches may either be toggles (clicking turns them on

    or off), or part of a group (clicking one activates it, and turns any other switch in its group off).

    Intensity controls such as Morph Speed are shown with a gradated bar underneath. Clicking on

    the control sets the degree of intensity. If only the white square at the left of the bar ishighlighted, the intensity is set to 0.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    25/100

    17

    Tabs, such as Normal & Cavity Map, allow access to further controls in ZMapper. Clicking on a

    tab shows the controls associated with that tab, hiding any other tabs controls. Shift-clicking ona tab will show that tabs panel, without hiding other panels.

    The most common controls in the UI can be accessed with the hotkeys. These keys are

    indicated by a yellow letter or number in the control panel.

    At any point in time, clicking on the UI title barthe one at the top of the control panelwillhide or unhide the rest of the panel, to allow enlarging the area of the screen available for

    viewing the model.

    4.4.3.Upper ControlsThe upper ZMapper controls are those shown below; they are the most basic controls in the

    interface, and are not part of a tabbed page. The controls in the tabs will be discussed in later

    sections.

    Figure 4. ZMapper Upper Controls

    Well go through the upper controls on a column by column basis, then talk about the tabs and

    open/save configuration controls at the end of this section.

    4.4.3.1. ZMapper Column

    TheZMapper column contains general controls not related to the categories defined by the other

    columns. These are:

    Exit: Quit ZMapper. After exiting, any normal map you created will be available in theTexture palette of the main ZBrush application. ZMapper may also be exited using

    the Escape key.

    Hide: Toggles visibility of the ZMapper UI.

    Local Light: The ZMapper preview normally shows the model lit with a fixed,

    predefined lighting source. When LocalLight is activated, a light will be createdwhich rotates with the model. This light source, if visible on the display, will appear

    as a yellow cube, as shown in Figure 5. To move the light relative to the model,

    click and drag it (if it is visible on the screen) or click and drag anywhere on the

    screen while holding down the shift key.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    26/100

    18

    You cannot use the shift-drag method to move the light entirely around the model.

    Instead, rotate the model so the light remains visible, and then move the light,incrementally.

    When using the local light, the Diffuse Intensity slider affects the intensity of the local

    light.

    Figure 5. Local Light Illumination.The yellow light will always illuminate the model from the same relative angle, regardless of how

    the model is rotated (i.e. the light rotates with the model). If this view of the model were flipped

    vertically, you!d see the backside is completely unlit by the local light.

    Opaque: By default the UI panel is semi-transparent to enable viewing any part of the

    model that might be behind it. This toggles it to be opaque.

    Background: Controls the grayscale intensity of the background.

    RenderRgn: When active, this switch causes a render box to appear on the screen. Thebox may be resized by dragging on any of the four corners, and moved by dragging

    anywhere else in the border. In addition, dragging within the box will draw a regionthat further refines the render area. Once a region is created, creating a normal map

    will create it only in and around that region. This can be extremely important whenworking on specific areas, since you can evaluate changes on those areas without

    re-rendering the entire normal mappotentially a time consuming process. Below

    you can see a selected, rendered region.

    Figure 6. Rendering a Specific Region of the Normal Map

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    27/100

    19

    4.4.3.2. Transform Column

    The Transform column controls are related to navigating around the model.

    Rotate, Scale, Move: Rotate is the default option, and if chosen, all of the various

    methods for viewing the object described in section 4.4.1,Navigating Around the

    Model, apply. If either of the other two options is selected then any of the actionsdescribed in that section cause the model to be scaled or moved, as appropriate to

    the selected setting. How you use these settings will depend on how often you use

    ZMapper, and your preference for remembering shortcuts vs. explicitly selecting

    actions with the UI. If you prefer the speed of the shortcuts described in section4.4.1, always leave Rotate selected. If instead you prefer the simplicity of using just

    one type of action for all transforms, simply select the appropriate transform and

    then click and drag to perform it.

    4.4.3.3. Mesh ColumnTheMesh column contains various options having to do with viewing the mesh:

    Faceted or Smooth: Models are normally displayed using standard polygon smoothing,

    but choosing Faceted disables polygon smoothing in some (not all) render modes.

    This allows you to see the exact relationship of an underlying area (such as a UVtexture group) to the polygons it covers. Figure 7 gives an example.

    Figure 7. Mesh Faceted Display.

    Spin: When on, the model will rotate continuously in the preview window. You can

    control the direction and speed of the rotation by dragging the mouse on the model

    or background. (The Transform mode must be Rotate for this to apply; see 0 above.)The speed and direction of the spin will be set by the mouse motion at the time you

    release the mouse button.

    Recenter: Causes the model to be reset to its initial position on the screen. Repeatedlyclicking this button will cycle between viewing angles.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    28/100

    20

    Diffuse Intensity: Slider allowing selection of the intensity of the diffuse (ambient)

    light source. When Local Light is on, controls the brightness of the local light.

    4.4.3.4. Morph Modes Column

    TheMorph Modes column allows the model to dynamically morph between different

    representations.

    Morph 3D: Causes the model to cyclically morph between its initial geometry and a

    predefined morph target, if such a morph target exists. (Morph targets can bedefined while modeling in ZBrush.) If no morph target exists, nothing will happen.

    This can be useful for seeing the interaction between an animation (as simulated by

    the morph cycle) and the normal map. This may reveal artifacts without the

    necessity of transferring all of the data over to the next 3D application in yourworkflow.

    Morph UV: The screenshots below try to give some idea of the effect of this veryinteresting tool. Basically, this morph dynamically unwraps the 3D model surface

    onto a 2D texture plane so that you can easily see how various parts of the model

    correspond to the UV mapping. Not only does show where texture seams are, but it

    can help you to more easily spot ways in which the UV mapping might beresponsible for artifacts in the normal map.

    Figure 8. Series of images from Morph UV setting.The unwrapping of the troll below shows how various areas of the normal map correspond to areas

    on the model itself.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    29/100

    21

    The normal map for the head below was set up using adaptive UV tiling ("AUV! tiling) in ZBrush,

    which UV maps small sections of the model to appropriately sized rectangles in the normal map,

    ensuring minimal distortion. Compared to more standard mappings such as for the troll above, this

    makes more efficient use of the texture map, but gives little control over the positions of seams.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    30/100

    22

    Freeze At Target: When one of the two morph modes is on and this switch is activated,

    the morph cycle is suspended and only the other endpoint of the morph is displayed.For example, ifMorph UV were on, the normal map unwrapped onto the texture

    plane would be shown.

    Morph Speed: Controls the speed of the morph cycle.

    If one of the two morphs modes is active and you want to turn off all morphing, simply

    click on the active morph switch.

    4.4.3.5. Wires ColumnThe Wires column controls various display properties of the model by imposing lines (wires) on

    the rest of the model. All of these options can be toggled independently.

    PolyFrame: Shows the borders of polygons. If groups are defined, border colors reflect

    this.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    31/100

    23

    Figure 9. PolyFrame Model View.

    TanFrame: Shows the polygon tangent and bi-tangent1 vectors used in generating the

    normal map as red and green lines.

    Figure 10.TanFrame Model View.

    NormFrame: Shows blue lines giving polygon normal directions.

    1 The bi-tangent is also called the bi-normal vector. It is (subject to adjustment during map generation) thevector orthogonal to both the normal and tangent vector at that point.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    32/100

    24

    Figure 11.NormFrame Model View.

    4.4.3.6. Screen Column

    The controls in the Screen column allow the creation and saving of screenshots showing multiple

    views of the same model in different poses, or with different rendering options. To obtain suchsnapshots:

    1. Render and place the model on the screen as desired. Activate Snapshot. This will place acopy of the model on the screen background; when the model is next moved, the copywill remain.

    2. Repeat step 1 as desired, to build up a screen with multiple snapshots.3. Activate Save to prompt for a file save dialog, or Dispose to clear the screen background.Snapshots require additional video card resources, and may result in slower performance

    on some hardware.

    Below is a screenshot of two views of the troll model, one showing the normal texture and the

    other showing normal shading, composed into the same screen using the snapshot functionality.

    You can see how this would be useful for constructing thumbnail arrays for comparing poses,texturing, and so on.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    33/100

    25

    Figure 12.Multiple views caught with Snapshot.

    4.4.3.7. Display Column

    TheDisplay column, on the top right side of the control panel, allows viewing the model invarious ways and also controls whether a normal map will be generated in object or tangent

    space

    Display slider: Changes the perspective of the model. Low intensities present the

    model as if it being viewed from afar with a high-powered zoom lens. High settingsmake it appear as if it were viewed from nearby with a wide-angle lens.

    Figure 13.Effects of Display slider.Increasing values change the shot from a distant zoom shot to a close-up wide-angle shot.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    34/100

    26

    Object space N.Map: Causes the model to displayed using the associated texture (if

    any) as an object-space normal map. As well, any normal map created while thisoption is on will be an object-space normal map.

    Tangent space N.Map: Causes the model to displayed using the associated texture (if

    any) as a tangent-space normal map. In addition, pressing Create NormalMap(Found in the first tabbed page of the interface) while this is on will cause the

    generated normal map to be a tangent-space normal map.

    Figure 14.Model as it would appear with a tangent-normal map viewed using thetangent space option, or with an object-normal map viewed with the objectspace option set.

    It is possible to view a tangent-space map using the object space option, or an object-space map with the tangent space option, but theres no point in doing so, except perhapsfor curiosity.

    Normals: Shows as colors the object-space normals of the low-resolution surface as

    applied to the low-resolution surface. In the figure below, the upper side is green,

    yellow, and orange, while you can see the traces of blues and purples that are thepredominant colors on the lower side. This full spectrum range is characteristic of

    the RGB representation of normals over the surface of an object when the normals

    are calculated in object space.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    35/100

    27

    Figure 15.Model with Normals render option on.

    Tangents: Same as Normals, except that the vectors calculated and displayed are the

    tangent vectors used in calculating the normal map.

    Tangentsdoes notdisplay the colors of the normal vectors of a tangent space normalmap. It displays the color representation of the tangent vectors themselves, where the

    tangents vectors are lines tangent to the surface, on which calculation of the normals

    depends.

    Figure 16.Model with Tangents render option on.

    UV Seams: Uses colors to show how different areas of the model map to differentareas of the normal map texture. The borders between areas of different colors

    correspond to seams in the normal map texture. The colors are arbitrary and do not

    represent vectors of any sort.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    36/100

    28

    Figure 17.Model with UV Seams render option on.

    Groups: Displays the model with its different groups shown in different colors. Groupsmay have been generated in ZBrush, or may have been defined in a model imported

    from another application.

    Figure 18.Model with Groups render option on.

    Texture: Shows the model with the normal map (whether tangent or global space)

    applied as a colored texture. This is the best way of seeing how colors in a normal

    map relate to the appearance of bumps on the surface.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    37/100

    29

    Figure 19.Model with Texture render option on.This displays the color of the generated normal map. The bluish color of the map below indicates it

    was built in tangent space. An object-normal map would display a full spectrum of colors.

    4.4.3.8. Configuration and Preview ControlsOpen Configuration: Allows loading a predefined configuration file that will set

    options appropriate for an external program you use in conjunction with ZBrushnormal maps. Configuration files can be saved for later reuse (see below), or one of

    many predefined files included with ZMapper can be used. When you first choose

    Open Configuration, youll be presented with a file selection dialog showing the

    contents of ZMappers standard configuration files directory. Configuration files

    shipping with ZMapper indicate their uses by file name.Different 3D applications can interpret details of a normal map in different ways. In other

    words, while the concept of a normal map is the same across applications, there is no

    industry standard defining how the value of a pixel in a normal map precisely affects afinal rendered image. ZMappers predefined configuration files can ease the task of

    finding appropriate settings for use with your own applications, and no doubt further

    configuration files will become available as users develop them.

    The list of configuration files shipping with ZMapper as of this writing can be seenbelow.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    38/100

    30

    Figure 20. Predefined Configuration Files in ZMapper

    Save Configuration: Use this button to save ZMapper configurations youve found

    particularly suited to your needs or favorite applications, and then reload them at a

    later date with Open Configuration.

    If youve found a configuration that you think might be useful to other ZBrush users,

    please post it on the ZBrushCentral forum!

    Preview High Resolution Level: Superimposes a rendering of the ZBrush models high-

    level mesh over top of the model in the ZMapper screen. The ZBrush model will be

    displayed with whatever texture is assigned to it, which will be the normal map ifone has been generated. This allows easy comparison of the appearance of the

    sculpted mesh with the effect of the normal map on the base mesh.

    4.4.3.9. Subpanel Tabs (see bottom left of Figure 4)These control access to subpanels of the ZMapper interface. Those subpanels are described later.

    The subpanels themselves are accessed simply by clicking on the appropriate tab. In addition,

    Shift-clicking on a tab will open that subpanel without closing any currently open subpanels; this

    makes it possible to have the entire ZMapper control panel visible at one time.

    4.4.4.Normal & Cavity Map Tabbed PanelThis section describes the normal map creation options found under the Normal & Cavity Map tab.These are the settings youll most commonly use to affect a generated normal map. (The Save

    Configuration and Open Configuration buttons were discussed previously).

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    39/100

    31

    Flip Image Vertically: The generated normal map texture will be flipped top to bottom.Some external programs or renderers will need to use vertically flipped normalmaps.

    Flip Red Channel: Vertically flips just the red channel of the normal map.

    Flip Green Channel: Vertically flips just the green channel of the normal map.

    Switch Red and Green Channels: Switches the red and green channels of the normalmap. This is used with programs or renderers that switch thex-y coordinate space

    mapping of the color channels opposite to the usual way of doing things.

    RGB Blur: If you find artifacts when rendering using a ZMapper normal map,increasing the Blur value may eliminate these artifacts. Try this particularly if you

    find black speckles in the model when displayed using the created normal map.

    (This has to do with limitations inherent in the process of mapping 3D geometry to

    a normal map representation, and will be encountered in some form in all normalmap creation programs that employ the high-resolution/low-resolution subdivision

    correspondence used by ZBrush.)

    RGB Sharp: Inverse of RGB Blur. This is another control that may allow you to changethe final map to be of higher quality.

    Seam Overpaint: When renderers are processing normal map information (or almost

    any other type of map information, for that matter), they need to handle UV seamissues. These issues arise because adjacent polygons in the model may be mapped

    to areas of the normal map that are notadjacent. A renderer that in some sense

    averages nearby map pixels in its calculations may need to go outside the actualgroup/polygon area of the map in these cases. As a result, some maps (including

    normal maps) may need to have valid map information outside of and around the

    borders of the map areas actually corresponding to points on the model. This optioncontrols how many pixels outside of a map area such information may be written.

    You can try increasing it to handle artifacts that appear at UV seams.

    While overpainting seams, ZBrush will not overpaint a map area used by another group.

    As a result, group areas close together on the map may not have their borders overpaintedto the degree indicated by this setting. This applies particularly when using ZBrushs

    AUV tiles mapping, which maps into closely spaced rectangles. For optimal flexibility

    with seam overpainting, use it with a UV mapping that leaves larger amounts of space

    between group edges.

    Samples, Subdivide: These affect the quality of the final map. Higher values are likely

    to produce higher quality, at the expense of increased map generation time.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    40/100

    32

    Inflat Hires Mesh Details and Inflat Bumpmap Details: Both of these exaggerate the

    bumps or wrinkles in the mesh by inflating them, depending on the intensity of thesettings. The first control causes inflation before any bumps have been processed

    into the models geometry, and so causes inflation of only geometric details; the

    second causes inflation after bumps have been processed into the models

    geometry, and so inflates both geometric and bump details. Both may be used at thesame time, but doing so will often lead to artifacts. Using these settings is definitely

    a matter of artistic judgment. Some screenshots are shown in Figure 21 to try to

    give an idea of what the settings do.

    If there is no bump map, then the Inflat Bumpmap Details setting will not be used.

    Figure 21.Close-ups of effects of Inflat Hires Mesh Details and Inflat BumpmapDetails controls.

    Frame 1: Inflat Hires Mesh Details = 0, Inflat Bumpmap Details = 0. This is the basemodel.

    Frame 2: Inflat Hires Mesh Details = max, Inflat Bumpmap Details = 0. Notice that theheadband and some folds around the eye are more prominent, but that the headband dots (whichare bump map details) are unchanged from frame 1.

    Frame 3: Inflat Hires Mesh Details = 0, Inflat Bumpmap Details = max. Now not only thegeometric details, but also the bump map details, have been inflated.

    Frame 4: Inflat Hires Mesh Details = max, Inflat Bumpmap Details = max. Artifacts areclearly visible.

    Sharpen Bumpmap Details: Allows elements of the bump map to be presented moreclearly, but possibly with a more pixilated effect. This is shown below.

    Figure 22.Elephant ear rendered at low and high values of Sharpen Bumpmap.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    41/100

    33

    Sharpen Hires Mesh Details: Similar to the previous setting, but applies to mesh rather

    than bumpmap details.

    Cavity Intensity: One commonly used technique to achieve realistic or dramatic renders

    is the idea of ambient occlusion, where recessed areas of a surface become darker,

    even if a model is lit only with diffuse light. Cavity shading is a way of simulatingthis effect, and of incorporating it into the generated normal map. Cavity Intensity

    controls the degree of this effect; higher settings will result in darker cavities. If this

    setting is 0, no cavity shading will be done.

    Figure 23.Section of troll used to illustrate cavity mapping.The portion of the troll model shown below will be used to illustrate how the different cavity settings

    affect the final cavity map. This area was chosen because it has both wrinkled areas, flat areas,

    and blends between the two.

    When viewing a normal-mapped model with standard shading, its difficult to separate the effectof cavity shading from the effect of standard shading. Accordingly, in the examples below we

    have presented the cavity effects with cavity mapped models, rather than with normal-mapped

    models. Cavity maps may be created with the Create CavityMap button, described later.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    42/100

    34

    Figure 24.Effects of Cavity Intensity setting.The three images below show the effects of rendering a cavity map with the cavity intensity set to

    #, $, and % of its maximum value, respectively. Other cavity-related settings held constant. Higher

    settings will result in darker cavities in final rendered images.

    Cavity Coverage: Affects what is considered a cavity. In practical terms, you can think

    of the cavity ratio of a recessed area as the ratio of the depth of the recess to itswidth. The higher this ratio, the more of a cavity a recess is. As cavity coverage is

    increased, more recesses that are shallow in relation to their width will beconsidered and shaded as cavities. In particular, note the effect of this setting on the

    wrinkles in the relatively smooth area under the trolls collarbone.

    Figure 25.Effects of Cavity Coverage setting.Cavity maps rendered with cavity coverage set to approximately $, %, and maximum of full

    intensity, respectively. Other cavity-related settings were held constant. Higher settings will result in

    more geometry being affected by cavity darkening in final rendered images.

    Cavity Blur: Use this to compensate for artifacts that might appear when using cavity

    shading, or to cause an effect that does not follow the contours of the model asclosely as it otherwise would.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    43/100

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    44/100

    36

    Figure 27.Normal map generated with interpolated mode.Details around the eyes are not quite as desired.

    Figure 28.Normal map generated with raytraced mode.Note how the eyes are slightly rounder, compared with the previous picture.

    Create NormalMap: Create a normal map using the specified settings, and write it to the

    texture chosen when ZMapper was started. (If no texture was chosen, or one of the

    built-in textures was chosen, a new texture will be created with a default size.) Themodel will be displayed in ZMapper using the generated map, once the map is

    complete.

    Create CavityMap: Like CreateNormalMap, except that a grayscale map showing thecalculated cavity intensities is produced (and will be available as a texture after

    quitting ZMapper). This can be useful in a number of ways. Looking at the cavity

    map in ZMapper makes clear what effect the cavity settings have on where shading

    takes place, which is not obvious from inspecting a normal mapped surface. A

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    45/100

    37

    cavity map can also be produced separately from a normal map, and modified by

    hand to produce other effects, before being included in the rendering pipeline.

    4.4.5. Projection Tabbed PanelThe Projection panel controls projection of a normal map from one mesh to another of the same

    shape but with different topology. This process is discussed in section 3.

    We wont describe all of the controls in detailmany of them will normally be set in the

    predefined configuration files that ship with ZMapper. The most important ones are:

    Capture Current Mesh: This is normally the first button activated when projecting a

    normal map. It sets the currently selected ZBrush subdivision model as the source

    mesh from which a normal map will be calculated and projected. Once the sourcemesh has been captured, you should exit ZMapper, choose the target mesh in

    ZBrush, and come back into ZMapper to project the mesh.

    Create Projected Normal Map: This is used after the source mesh has been captured anda target mesh has then been selected. It calculates the normal map for the source

    mesh, and then projects it onto the target mesh.

    Release Captured Mesh: Once youve created your projected normal map, use this toset the captured mesh to none. This will restore the ZMapper display area and let

    you view the finished model.

    Raycasting Max Scan Distance: Sets the maximum distance ZMapper will cast rays

    from the source mesh as it tries to find a matching point on the target mesh. You

    may need to increase this if some parts of your models are not closely fitted.

    ShowMesh, ShowCap: At least one of these must be set. They control visibility of the

    target and source (captured) mesh, respectively.

    Allow Out, Allow In: If one if these is turned off, then ZMapper will not raycast out/in

    as it tries to match points on the source and target mesh. This may be useful if some

    points on the source surface can map to points on the target by both casting in andout. However, chances are that if that happens, your mesh has become folded in a

    way you didnt intend.

    Favor Out, Favor In: At most one of these may be set. If raycasting in both directions isallowed, then setting one of these tells ZMapper that the favored direction should be

    used if two target points are found, regardless of distances.

    The other controls set how rays are projected. There should be little need to use these, but youcan experiment if the default Normal setting does not provide satisfactory results.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    46/100

    38

    4.4.6.Expert 1 Pass and Expert 2 Pass Tabbed PanelsIf youre looking at these controls, youre getting deeply into normal maps. Differentapplications can use normal maps in subtly different ways, and the expert options allow fine-

    tuning of normal maps to achieve exactly the desired result. Its more likely that these options

    will be set via configuration files than by hand.

    Figure 29.Normal mapping expert panels.

    The expert options will not be described in detail in this document, but the next few paragraphs

    give an idea of some of the issues involved.

    4.4.6.1. Expert Option PassesFirst, notice that many of the controls in the first panel also appear in the second, and vice versa.

    The expert options are actually applied in two passes. The Expert 1 Pass panel defines optionsapplied in the first pass, and Expert 2 Pass defines options applied in the second pass. The

    duplication of some of the controls allows certain effects to be applied before or after other

    effects, as a matter of choice.

    4.4.6.2. Surface Normal InterpolationIf you look at Figure 84 that illustrates the raycasting process, youll notice that the rays

    projected out from the low-resolution surface are not projected perpendicularly to each polygon

    in the low-resolution surface. Instead, the ray directions are typically interpolated in some

    manner, using either surface normals or vertex normals in the low-resolution surface, in order toaccount for the fact that the polygons are normally intended as an approximation of a smooth

    surface2. Casting rays straight out from each low-resolution polygon would not take into account

    this implied smoothness.

    At the same time, not all polygons or polygon boundaries should be smoothed. Some of them

    really do represent flat faces or sharp edges. Standard mesh file formats do not have an agreed-upon method for indicating where smoothing should and should not occur, so normal map

    generation programs often provide options to allow heuristics during the map generation process.For example, you might wish to indicate that polygonal borders sharper than a given angle

    2 Similar interpolations are also done for basic lighting of untextured polygonal models, and have been

    around in the graphics field for a very long time. Reading up on basic lighting models such as Phong orBlinn will lead you into methods of interpolating surface normals.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    47/100

    39

    should be considered as sharp edges, while less sharp borders should be considered as smooth

    edges.

    In addition, polygon groups often indicate sections of a model that have sharper boundaries with

    respect to adjacent groups, making it desirable to allow different heuristics at group borders than

    at polygon borders. This may also be true at UV seam borders.

    A number of the expert options, such as the various PreSmooth... and PostSmooth... optionsrelate to these issues.

    4.4.6.3. Map Distortion IssuesGiven the amount of translation that is being done from one space (such as the xy coordinates of

    a normal map texture) to another (such as the tangent space coordinates on the surface of a

    polygon), it would be surprising if angles in one space always translated into equivalent angles inanother space. However, the definition in tangent space of the tangent, normal, and binormal

    vectors is such that they are supposed to be perpendicular to one another. In order to account for

    these stretching and distortion affects, adjustments to calculated vectors may be necessary duringthe normal map generation process. Expert options in ZMapper relating to this include the

    Orthogonalize... and Derive... options. If you play with these options, youll often find that

    changing one changes another, because there are interactions between them.

    4.4.6.4. Expert Options SummaryThe expert options panel in ZMapper exists to compensate for the fact that other 3D applicationswill interpret the subtleties of normal maps in different ways. This is likely to be a general cross-

    application difficulty, until standards for normal maps have been agreed on and published.

    This whole section on expert options was intended to help satisfy the curiosity of those who may

    be wondering about all of these additional controls, and to give some indication to those whomay need to use expert options as to what the options relate to.

    Few people should need to actually get this far into normal mapping details, however. ZMapper

    comes with a large number of configuration files (see section 4.4.3.8) that will appropriately setall options for use with many other 3D programs. More configuration files will become available

    on the Pixologic website and in the ZBrushCentral forums in the future.

    4.4.7.Misc Tabbed PanelThis final panel contains a few simple options that arent commonly used, or that dont fit in with

    the other subpanels.

    Wireframe: Normal vector length and Wireframe: Tangent vectors length: Controls thelength of vector lines drawn when the corresponding view in the Wires column of

    the upper part of the control panel is active.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    48/100

    40

    Activate MipMap Preview: When active, ZMapper will calculate and use mipmaps

    while displaying the model. This allows you to rotate and scale the model to see ifany artifacts are generated by the interplay of the mipmaps.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    49/100

    41

    5.ZMapper ExamplesThis section is an introduction to ZMapper by example. It doesnt cover all of the features ofZMapper (see the reference sections for that), but it does provide detailed walkthroughs so that

    you can quickly and easily understand and use ZMapper on your own projects.

    5.1. Viewing a Finished ModelZMapper is distributed with a detailed elephant model that well use to show off many of the

    ZMapper features. This section covers loading a finished version of the elephant, and examining

    it in ZBrush and ZMapper. As well as showing how much detail can be achieved, this will serve

    as a good introduction to the ZMapper interface. Later sections will talk about how to constructmodels like this.

    Use these instructions to view the elephant model:

    1. Start up ZBrush and make sure the ZMapper plugin is loaded, using one of the twomethods detailed in section 4.1.

    2. Using the Tool:Load button (i.e. the Load button located in the Tool palette), loadZMapper_Elephant_Posed.ZTL.

    3. Enter ZMapper by pressing the ZMapper button. (By default it appears in the Zpluginpalette.)

    4. If your elephant is showing different shades of color, it means ZMapper is showing it in adisplay mode that does not use the normal map for shading. Press Tangent Space N.Map

    in the ZMapper interface. (This displays the model assuming the pre-existing normal mapis in tangent space coordinates, which it should be.) At this point you should be viewing

    the image shown in Figure 30.

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    50/100

    42

    Figure 30.Normal Mapped ElephantThis is the normal-mapped, low-resolution elephant model displayed in ZMapper. The model

    consists of approximately 11,000 polygons.

    5. Use the other features of ZMapper (rotating, spinning, etc.) to show the full detail of theelephant. (See section 4.4.1 for details on how to navigate around the model in ZMapper.)

    6. Exit ZMapper and, if youd like, draw an instance of the elephant on the screen to viewits geometry. As you can see, it is a relatively light model (for something of its

    complexity), with only about 11,000 polygons. The rest of the complexity seen inZMapper came entirely from the normal map.

    You cannot generate normal maps from this model. It is intended purely for display

    purposes.

    5.2. Constructing a Normal Map from a Finished Model; ElephantIn this section, well cover how to actually generate a normal map from a finished model. Theinstructions below come in two sets. The first set describes how to load a multiple-resolution

    model and create a normal map from it. The second set continues from where the first left off,and shows how to incorporate a high-resolution bump map into normal map creation.

    To create a normal map from a high-resolution/low-resolution model:

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    51/100

    43

    1. Restart ZBrush (to make sure nothing else that might have been done in it will affect thedemonstration), and load ZMapper.

    2. Load the tool ZMapper_Elephant.ZTL. Unlike the model used in the previous section,this model has multiple levels of subdivision.

    3.

    InTool:Geometry

    , make sure the subdivision level (SDiv

    ) is set to 1. As was discussed insection 4.2, ZMapper creates a normal map for the models geometry at this subdivisionlevel. Setting SDiv to 1 ensures that the normal map will be created for the lowest-

    resolution version of the model, by comparing it to the highest-resolution version.

    4. Using the Texture palette, create a new blank texture with width and height both set to2048, and make sure the new texture is selected as the current texture. This will becomethe normal map3.

    5. Start ZMapper. You will see a low-resolution elephant, probably with what appears to bea plain gray surface.

    6. Use the ZMapper Open Configuration control to open the configuration fileZMapper_Elephant.zmp. (This gives a good set of values for creating the elephantnormal map. You might want to later experiment with the various values to see the

    effects.)

    7. Press Create NormalMap. Normal map calculations will be displayed graphically as theyoccur. Click OK on the report dialog that comes up after the calculations are done, and

    you'll see the normal mapped elephant displayed.

    8. Exit ZMapper. The generated normal map is selected in the Texture palette, ready forexport. This normal map was created simply by comparing the high-resolution and low-resolution versions of the elephant model.

    This concludes the first part of the normal map generation instructions, which illustrate

    how to generate a normal map by comparing differing subdivision levels of a model. Thiselephant isn't as detailed as the one shown in Figure 30, because the details from thebump map haven't yet been incorporated. Use of a bump map is shown in the remaining

    steps.

    To incorporate a bump map into the normal map:

    9. Empty the generated normal map texture using Texture:Clear. This isnt strictlynecessary, but is a good reminder that the normal map created in the previous steps isnt

    actually required when incorporating a bump map. Generation of a normal map using

    both high-resolution/low-resolution comparison and a bump map is done at the same

    time, and weve split the instructions into two parts simply to present the high-resolution/low-resolution comparison generation method (above) independently of the

    use of bump maps (below).

    3 The elephant is a very detailed model intended for viewing at high resolutionsin my case, full screen

    on a 1600x1200 display. A model taking up a smaller area of the screen will require a smaller normal

    map. For example, a model intended to occupy only about a sixteenth of the screen area might require anormal map of 512x512 pixels or 256x256 pixels (depending on desired detail).

  • 7/28/2019 ZBrush ZMapper 2005 Nov 30

    52/100

    44

    10.From the Alpha palette, import the file ZMapper_Elephant_Bump.PSD. This is a bumpmap that applies to the elephant model. Well talk about how to generate such a bumpmap using ZBrush a bit later.

    If you want to examine the bump map more closely, you can bring it in as a texture (don't

    do this while following these instructions) and fill the canvas with it, or simply view it

    using Photoshop.

    11.In Tool:Displacement, set Intensity to 0.05. (In general, you will likely keep this slider tosmall values, say below 0.1. This is highly dependent on the program producing the

    bump map.) This controls how strongly the height and depth of the bump will be

    displayed on the model, based on the intensity levels in the alpha. The appropriate valuedepends on both the bump map imported in the step above, and how strongly you wish

    the bump effect to be displayed. Some experimentation may be required in your own

    work4.

    12.Enter ZMapper, select Tangent Space N.Map, and create a normal map. This time all ofthe details will be present.

    13.Exit ZMapper. The finished normal map is the currently selected textur