A workflow to transfer Scan data to a clean and functional geometry.
by Armando Sepulveda
Modern 3D scanning technology is widely used in CG production as a first step in the creation of 3D models. Despite the current advances in existing tools, it is still a non trivial process.
One obstacle is that some models can not be scanned in a single pass due to its complex form, in such cases it is required to break apart the model and then scan each part separately. The modeler artist is then responsible for rebuilding the original 3D model from the scanned parts.
However a for more difficult issue one must deal with is the clean up of the scanned 3D data. We need to adjust the resolution of the model to the production needs of the project and more importantly — specially in CG animation — the whole topology of the mesh data must be revised to allow proper deformations. By topology we refer to the flow of polygonal lines, vertex count of its intersection and the overall layout of these features on the 3D model
The objective of this article is to present a production tested workflow for the conversion of scan data into a valid 3D geometric and topological structure for CG animation. We will also cover the specific problem of dealing with multipart scans.
Our workflow is based on well known commercial packages: Maya, Nex, Mudbox and Photoshop.
Thanks to Mudbox or ZBrush we will be able to translate our scan data into a hierarchical subdivision surface, where it is far easier to model low resolution detail working on a low count polygonal mesh and at the same time we can still add highly precise detail in the higher res version of the same sub surface. All this switch back and forth from low to high resolution in a seamless manner.
We nevertheless can benefit from using extra software like Topogun. However let us leave for the moment the details of how to use these plugins for a future article.
#step 1. Importing the data
We are going to assume that the 3D scanning department is going to provide us with several resolution scans of the parts in the model. This is by far the most common work routine. In the example bellow, for example, we are going to have a low and hires versions of the left arm, right arm, torso, etc.
We need to bring all this data into our maya environment, scale it, oriented properly and setting all the parts in place.
Since working with potentially millions of polygons for the main body, scaling, rotating etc is very cumbersome and potentially slow process we are going to use a simple trick in maya to do the job once in the low res and apply it on the highres for free.
So here are the first steps:
- Open Maya and import the low res version of the scan
- Use Ctrl:g to assign the geometry to a new group
- Now select the newly created group and transform its scale, orientation and position until the model is place in the desire target location and scale.
- Lock the group to prevent modifying its transform by accident
#step 2. Transforming the data
Next we are going to reuse the group we just created to apply the same rotation, scaling and translation operations to other parts
- Import the next part of the model into maya
- Parent it under the previous group node
- Reset the transform of the new part so that it gets move to its proper location
In the next figure we added an skeleton to the maya scene in order to verify that arms, joints and proportions are all correct.
#Step 3. Organizing the data
The parts of the model we are importing can be organized in very complex hierarchical structures in order to have the flexibility of changing the pose, for example rotating an arm. One can then create a number of groups under the first root group for this purpose. Always keep an important detail in mind: set the pivots of the new groups in the appropriate locations.
In the case shown in the next figure, we rotated the RightArm group after resetting it to the proper location attached to the torso. Now when one imports the hires version of the same arm, and parents it/reset it under this transform it should go to the same exact location and orientation.
-We can create specific layers for each LOD and parts into the scan data for a better control.
#Step 4. Modeling the geometry
Next we are going to use a maya plugin called Nex to create a cleaner version of the same model. This plugin allows us to re-sample the scanned data and generate geometry with the desired resolution and topology.
Before proceeding there is an intermediate step one has to take care first. Since we rotated the location of the arms, the joint shoulder scanned data doesn’t match exactly anymore. Using Mudbox this is easily fixable.
Just creating a low res version of the model with a correct topology is enough. It’s not necessary to match every detail on the scan data right now. Later on, Mudbox will take care of that baking the high res data into the low.
Nex is a plugin for Maya very handy for modeling over live surfaces. Take a look at this link and its videos, mainly the Quad Draw Tool.
I’ll be using the Quad Draw tool. So first thing is setting the mesh as Live Reference.
After setting the scan as the reference, every vertex, edge or polygion we create or move will be snapped to the surface. The Quad Draw tool allows you to create vertex freely on the surface and then create the polygons with them.
It’s very easy to combine the maya tools with Nex, so just extruding an edge and then Shrink it to the Live Mesh.
Most of main modeling tools are already included into Nex. So even when we add loops they will be snapped automaticly to the surface.
And finally after creating and editing, and always keeping the volume, I have a final (almost) low res mesh with a proper Topology. For a better explanation about topologies go to this post where I give some orientation or ideas.
Using a right topology and flow will make things easier for the time we create the uvs.
Our final Uvs
#Step 6. Baking the Scan Data
Now we will transfer the volume info from the scan to our clean Mesh getting a Displacement Map to work with. Our goal is to mirror this map and apply it back again to the mesh obtaining a final HighRes mesh with subdivision history into Mudbox.
It’s also the time to use the high res scandata exported from Maya, following the intial steps to get its proper transforms. This scan data is closer to 1M polys
Due to the rotation in the arms it will need some modeling work in Mudbox, as well as some cleaning on the surface before baking it.
Once ready the Highres Scan we import our low res geo with the right topology and uvs. We named everything properly into Mudbox and we baked it.
Utilities/Texture Baking/New Operation and these are the settings
We can use the Image Browser to check our final Displament Map. After that we will mirror it and get a new complete and symmetrical map.
We bake back this mirrored map into the Low res Geo to get our Subdivided mesh.
Utilities/Mesh Displacement/New Operation and these are the settings
#step 7. Final Touch
Of course once the Disp Map is mirrored and baked back to our geo we will get some artifacts, so we will have to do some cleaning.
And here is the final result with the different levels of detail.
After that, our final model can be baked back again into our Low Res Geo and get a final clean Displacement Map ready for render, and of course another new Low res Geo matching the volume of the Scan.
Here is a Maya snapshot with the final Low res Geo and a clean topology ready to be rigged and animated.