In this post we present a powerful new tool available in Rhino3DMedical for meshing and creating solid objects: Shrink Wrap. We explain its meaning and show how to use it and its benefits.

The process of enveloping 3D meshes

Common in 3D polygon mesh processing, Shrink Wrap is the concept of enveloping a complex 3D mesh with a simpler object like a sphere, properly deforming and modifying it. Two parameters govern this modification: the precision, or how close the envelope will be to the original mesh, and the wrapping itself, or how likely the envelope will keep being a "simple" object (in practice, whether the enveloping sphere will stop being a sphere and break into smaller objects).

References like [1] and [2] show different ways of doing this enveloping process. In most cases it is an optimization procedure that takes the two mentioned parameters as inputs.

Process of enveloping a complex 3D model (blue) with a loose shape (green) [1].

Process of enveloping a brain model with a sphere-like object [2].

Shrink Wrap in Rhino3DMedical

Rhino3DMedical presents an implementation of Shrink Wrap as a mesh-to-mesh command. You can find it in Mesh Repair section, and run it on any mesh (not only medical).

The command will ask to select a mesh, and the command line will prompt the option to modify parameters alpha (corresponding to wrapping coefficient, or how likely the wrapping is to hide small holes), and offset (corresponding to precision, or how close the wrapping will be to the original mesh). For both parameters default values are 300, and can be selected between 1 and 5000. In most cases you won’t need to modify them, as they are optimally placed. However, if you want to increase wrapping coefficient or precision, push these values up (e.g. higher offset number for higher precision).

Original mesh in Rhino3DMedical (in orange).

In this case, we see in the following image the results of applying Shrink Wrap to the skull. Remember to access Layer tab in order to hide the visibility of the original mesh, and see the new one. You can change the color of its material, to better see the intersection with the medical image.

New Shrink Wrap mesh (in red).

Mesh comparison

If we make both meshes visible and with different material colors, we can properly compare precision with the medical image. In the following picture we observe this for the skull. We observe that original mesh (orange) has several internal artifacts and irregularities (corresponding to porosity and thinner bone), while the new Shrink Wrap mesh (red) surrounds the outer structure and is cleaner and more compact. We also observe that the precision of the new mesh is at least as the one of the original one, with differences bounded by the length of one voxel (0.3 mm in this case).

First comparison of original mesh (orange) with Shrink Wrap mesh (red).

Second comparison of original mesh (orange) with Shrink Wrap mesh (red).

If we overall compare the two meshes, we can observe that the new Shrink Wrap mesh is more solid and slightly smoother than the original one, removing artifacts and presenting a cleaner and solid structure. It is more likely to have better quality for 3D printing and processing in tools like extended reality.

Original mesh (left) and Shrink Wrap mesh (right) in Rendered mode.

On the other hand, Shrink Wrap tends to increase the density of the mesh and have a bigger number of triangles. The scale of this change can be tweaked or refined by modifying the precision (offset) option in the command.

Original mesh (left) and Shrink Wrap mesh (right) in Shaded mode.

Altogether, Shrink Wrap is a powerful tool to perform mesh processing on your meshes, simplify and make them easier to treat, while preserving their amount of detail and precision.

[1] Hurtado, J., Montenegro, A., Gattass, M. et al. Enveloping CAD models for visualization and interaction in XR applications. Engineering with Computers 38, 781–799 (2022).
[2] Kobbelt, L. , Vorsatz, J., Labsik, U., Seidel, H. A Shrink Wrapping Approach to Remeshing Polygonal Surfaces. Computer Graphics Forum, 2000.