Module: Remesh Surface ()

Description:

This module implements the surface remeshing approach described in M. Zilske, H. Lamecker, and S. Zachow, Adaptive Remeshing of Non-Manifold Surfaces, Eurographics 2008 Annex to the Conf. Proc., 2008, pp. 207-211. The module implements two approaches for surface remeshing. The first approach uses explicit regularization of the triangles around a vertex and, therefore, generates triangular surfaces with high regularity. A highly regular mesh is a mesh for which most of its vertices have 6 neighbors.
The second approach is based on Lloyd relaxation and does not explicitly regularize the vertex connectivity. This approach attempts an isotropic vertex placement in order to achieve a high triangle quality.

The more general approach is that of an isotropic vertex placement, which is why it is set as the default. However, for smooth surfaces the high regularity objective might also produce very good results. At the end of this module's documentation you see the remeshing results for both objectives compared to the original surface.

Note that the algorithm is both time and memory consuming. For example, when remeshing a surface with 1,300,000 triangles, about 2GB of memory will be consumed. The time varies according to the size it will be remeshed to. For example, when remeshing the surface to 50 percent of its original size, it will take about 15 minutes.

There is no guarantee that the result of the Remeshing module is free of intersections, so to prevent intersection near contours you can:

  1. Select "fix contours" of "Remesh options (1)"
  2. Start remeshing

    Result: No intersections, but the contours have shorter edge lengths than the rest of the mesh. This might be undesired. To adjust the edge length of the contours:

  3. Attach a new Remesh Surface module to the result of the first remeshing step.
  4. Set the desired size to 100
  5. Select "Advanced options".
  6. Select "only arround contours" in "Remesh options (2):".
  7. Press the "Apply" button.

Connections:

Data [required]
Input surface to be remeshed.

DensityField [optional]
Surface scalar field used for locally modulating vertex density. If no field is connected the curvature is used for weighting the density. See also port Density contrast.

SurfacePathSet1 [optional]
A Surface Path Set that can be considered while remeshing to preserve certain features. Please also see the Surface path options port. Note that more than one surface path set can be connected to the module. If the first surface path set is connected, a new connection will be created.

Ports:

Objective

This port determines the objective of the remeshing:
High regularity: the remesher tries to generate a mesh such that for most of the vertices the number of neighboring vertices is 6.
Best isotropic vertex placement: the remesher attempts to generate a mesh with vertices placed isotropically across the surface. Since vertex placement is modulated by either the curvature or a density field, isotropy of vertex placement will only hold with respect to the modulated vertex distribution.

Vertex valence opt.

This parameter allows specifying the number of passes used for improving the vertex valence, i.e. the regularity. This option is only visible if the objective is high regularity. A mesh is considered regular if the number of neighbors of each vertex in the mesh is 6. So, the higher the nPasses value, the more the remesher will try to generate a regular mesh.

Triangle quality opt.

This parameter specifies the number of passes used for triangle quality optimization. Here the objective is to obtain triangles that are as equilateral as possible, i.e. all triangle angles should be similar. This option is only visible if the objective is high regularity.

Desired size

The values of this port determine the number of vertices and triangles in the final surface. Note that the actual number of vertices and triangles might be slightly different from this number. The three values in this port influence each other. Setting one of the values will result in a modification of the other values. In regular surfaces, the number of triangles is twice as large as the number of vertices. Hence, setting the number of triangles will result in half the number of vertices. However, it is inherent to the algorithm to consider the number of vertices and not the number of triangles. Hence, the resulting mesh will be closer to the specification of the number of vertices than to that of the number of triangles. The last value is provided for convenience only. It allows setting the percentage of the original mesh size.

Error thresholds

Two error thresholds can be set. Both thresholds are angle thresholds and have a range between -1 and 1. If the error threshold is 1, no changes are allowed, because each remeshing will violate this threshold. If the value is -1, no error will be taken into account. Since the thresholds are given as the cosines of angle thresholds, their range is -1 to 1.
The smoothness error measures the difference between the vertex normals of neighboring vertices. Hence, a vertex can only be moved if the smoothness criterion is preserved. As a result, regions of the original surface that are not smooth will usually stay as they are.
The distance error measures the distance between the original and the modified surface in terms of normal distance. Hence, a remeshing step can only get accepted, if the distance between the normals of the original and the remeshed surface is smaller than the given threshold.

Interpolate orig. surface

When the first option, smoothly, is selected, the original surface will be smoothed internally, and this smoothed surface will be used to move the vertices. If the second option is chosen, no interpolation is done and the vertices of the remeshed surface will be exactly on the original piecewise linear surface.

Contour Options

Contours can either be given by surface paths or implicitly at non-manifold edges. With the first option, these contours can be fixed, which means that no changes are allowed for contours. With the second option, one enables contraction of edges on the contours. Note that this option will only be considered if the first option is not set.

Surface path options

The remeshing algorithm can be used in conjunction with surface paths, i.e. the user can specify surface paths which will be considered separately. If the second option is selected, control points, i.e. distinguished vertices on the surface path, will not be moved.

Modify result

This toggle allows modifying the result. If one has already remeshed the surface but would like to improve the result, checking this box allows modifying the surface starting with the previously computed result. This functionality might save a lot of time if only minor changes are desired.

Zone

Zone Options

This option lets the user decide whether the whole surface should be remeshed or whether the remeshing should be restricted to the area around contours, where contours are the borders of patches.

Contour layers

If the surface should only get remeshed around contours, this parameter enables the user to determine how large the area in number of triangles should be.

Advanced Options

Triangle area opt.

This port lets the user decide how much effort is put into the optimization of the triangle area. The desired triangle area in a certain surface region is a function of the given density. If no density field is given, the curvature field will be used instead, which is computed internally. The goal is to optimize the correct triangle area distribution. If no weighting is used, the areas of all triangles should be similar. The first parameter specifies the number of passes used for optimizing the triangle area. The nAreaSteps parameter specifies the number of steps per pass that are used for optimizing the triangle area by moving the vertices. The last parameter nEdgeFlips specifies the number of edge flips performed per pass for optimization. The default parameters should be suitable for most applications.

Lloyd relaxation

This parameter becomes visible if the objective is best isotropic vertex placement. It determines the number of passes used for relaxing the points. The default should be suitable in most cases.

Density contrast

The density contrast determines the influence of the density field or the surface curvature on the triangle area in certain regions of the surface. It is used as an exponent of the values of the density field, so be careful when choosing a value. A value between 0 and 2 might be appropriate.

Density range

This is the density range to be taken into account. Values below and above will be clipped.

Examples:

Figure 1: Surface before remeshing.
Figure 2: Surface remeshing with high regularity.
Figure 3: Surface remeshing with best isotropic vertex placement.