Friday, January 23, 2015

ZBrush - Topology and ZRemesher

Whilst sculpting in ZBrush, it is likely that DynaMesh has been used to create the base form, upon which subdivisions have been created to add detail. However, as explained before, DynaMesh does not take topology into consideration when dividing the object, which can be an issue in game assets which are intended for rigging and animating.

Looks normal...

At first, this sculpt looks absolutely fine. You would probably be happy with this level of detail unless you were going into super high-level detail work, however...

Awful topology
There is no efficient topology because of the use of Dynamesh. Trying to animate or pose this sculpt will prove extremely difficult to get lifelike movement. There is also the issue that the amount of polygons is very high. In this image there is about 1.312 million active points. Putting this into a game engine (in 2015) with other assets will more than likely put a severe strain on the system.

The difference between good and bad topology
Here is a diagram detailing what good and bad topology is. Good topology follows the muscles of the face, so as to make it easier to animate fluidly. So, there are loops around the mouth and eyes to that they are easier to open and move about. Good topology should minimise the areas of 'pinching' (where more than 4 or 5 edges meet) as well as tearing whilst animating.

So, how do we fix this in ZBrush?

Thankfully, there is a tool within ZBrush which will analyse your mesh and create a more efficient topology for you. However, it is not perfect and sometimes you will have to make some adjustments yourself.

Hit the ZRemesher button. Don't forget to duplicate your SubTool first

Before beginning the re-topologising process, you should duplicate your SubTool. This will be useful later.

The tool ZRemesher can be found under the 'Geometry' menu in your toolbox. As stated before, ZRemesher will analyse the mesh, looking at possible curves as well as peaks and valleys and use those to create a more efficient topology. The target amount of polygons can be changed at 'Target Polygon Count' where the number (default 5) is multiplied by 1000. The other options do not need to be touched as of right now.

Much better topology

With ZRemesher, the topology of the model is vastly improved. However, it has lost most of its detail, going down from 1 million points to just 7 thousand. Despite this, you are able to get this detail back.

By subdividing the mesh and Projecting the Dynameshed sculpt onto your ZRemeshed sculpt, you can retrieve the detail from the Dynameshed sculpt.

Projection will allow you to take detail from your Dynamesh and put it into your ZRemeshed sculpt whilst maintaining topology
To do this, you must have your Remeshed sculpt selected, with the visibility of the Dynameshed sculpt turned on. Then, lower in the SubTool menu, there is the option to 'ProjectAll'. This will check from all points at a specific radius out on the Remeshed sculpt and, if it collides with the Dynameshed sculpt it will move the point to the position. Since our mesh is very similar we do not need to touch 'Dist', however this can be increased if some parts of the Projection are too far away. However, increasing it too much will cause some tearing.

Barely any visual difference, for under one quarter of the points!
As shown above, ZRemesher is very useful for cutting down on the active points with minimal visual difference within the model. However, it is better to use this tool when you are done with the overall shape of the model, as the topology will change depending on the shape, meaning that your ZRemeshed model is no longer as efficient and you may end up needing to Dynamesh over it.

No comments:

Post a Comment