Skip to content
On this page

Remeshing

Overview

The RemeshingProcessor takes an input scene and replaces it with a lightweight proxy geometry that resembles the original, but does not share vertex data or parts of the original mesh data. The remeshed object is created and optimized for a certain on-screen pixel size - which means that holes and parts that are close to each other will have their gaps filled if the distance is below a pixel. It is also possible to set the detail level with a max deviation, which is internally converted to a corresponding on-screen size.

At default settings, the proxy mesh is assumed to be viewed from the outside. Any interior mesh that cannot be seen is removed. The result is a very light-weight mesh that is highly optimized for real-time viewing, or to speed up off-line rendering of small objects. Simplygon is capable of remeshing arbitrary geometry, including non-manifold surfaces.

Remeshing
Remeshing

Targets

You can control the output quality level and triangle count using one of two available remeshing targets; OnScreenSize or MaxDeviation.

By default, the remeshing quality level and output triangle count is controlled by setting a desired OnScreenSize. The LOD quality and triangle count is relative to this metric and will generate more triangles at larger values and fewer at lower, while keeping the geometrical error under one pixel for the given screen size. If set high enough, and the input does not have a lot of triangles, it is possible that the output will have more triangles than the input since the geometry is rebuilt from scratch. Larger values also take significantly longer time to process, as this corresponds to significantly higher geometry generation resolutions.

Alternatively, it is also possible to define the output quality using the MaxDeviation remeshing target. This allows the error tolerance to be set in absolute scene units, making it possible to remesh assets with different sizes to consistent detail levels. When using this metric, the MaxDeviation is implicitly converted to an internal OnScreenSize using the simple conversion OnScreenSize = Scene Diameter / MaxDeviation. which will control the resolution of the geometry generation in the same way as it does when using the explicit OnScreenSize target. This means that for MaxDeviation targets near zero, the implicit OnScreenSize approaches infinity, so when using this target always make sure that the MaxDeviation is set to a reasonable value in the context of the input geometry scale, and that the MaxDerivedOnScreenSize is set to the maximum tolerable implicit OnScreenSize.

Merging cavities and gaps

The RemeshingSettings contain a setting called HoleFilling, which is used to enable, disable, and control the aggressiveness of intelligent cavity removal algorithms. Since the remesher always generates two-manifold outputs, this is useful for removing insides from inputs that were not initially watertight, and would otherwise have been remeshed to two-sided output.

What this does is to measure the volume and hole opening sizes of concavities in the input geometry and fill them in in the remeshing if the concavity is large enough with a small enough opening. This removes a lot of unnecessary geometry and is recommended to be kept at it's Low default rather than turning it off, it will in the vast majority of cases have a positive effect on the result.

Remeshing modes

The remesher can be told to remesh in different ways using the RemeshingMode setting. In addition to the default Outside mode which remeshes the scene so it will look good from the outside, there is also a Inside and a Manual mode. Inside remeshes the largest interior volume with no connection to the outside found in the scene, which can be used for things like caves or house interiors, while Manual lets the user specify a point in space that will be treated as outside and remeshed from the perspective of.

Clipping planes

The remesher always creates two-manifolds, which means that even one sided input geometries will become two-sided once remeshed. So, sometimes the proxy models will have generated geometry on a side that is not intended to be viewed.

For example: if a one-sided plane is being remeshed, the generated two-manifold proxy will get a back side as well. All the geometry on the bottom side in this case is excessive. A clipping plane can be used to remove all parts of the mesh that is behind the cutting plane. By placing the cutting plane on the ground of scene, the model will no longer be a closed two-manifold because the bottom is removed and only the intended top geometry will be kept.

The clipping planes are added to the input Scene structure, and enabled using GeometryCullingSettings.

Single clipping plane

FigureDescription
Cutting planeHere the input mesh is one-sided and open
Cutting planeWith no ClippingPlane or HoleFill, the remeshing output becomes double-sided, wasting texture space and triangles.
Cutting planeAdding a ClippingPlane will make the input watertight and hence make the output single-sided again.

Multiple clipping planes

Multiple clipping planes can also be used to cut out tiles of the geometry.

Cutting planes
Cutting planes

Clipping geometry

Like clipping planes, only defined using a set of geometries instead. The clipping geometries need to be watertight within the bounds of the process geometry to work properly.

Like planes, the clipping geometries are added to the input Scene structure, and enabled using GeometryCullingSettings. The ProcessSelectionSet on the RemeshingSettings also needs to be set since the scene contains geometry you don't want remeshed.

Clipping geometry
Clipping geometry
Clipping geometry
Clipping geometry

Hole filling

These meshes are created with the different HoleFilling-modes available in the remesher: Disabled, Low, Medium and High, in order from top to bottom.

The first proxy has HoleFilling disabled, so apart from culling away triangles that are completely sealed away, all surfaces still remain. The second proxy has filled in the spout of the teapot, and also the tube all the way from the right-side opening to the section inside the tube on the left side where the teapot handle intersects the tube. On the 3rd proxy, the tube has been sealed up all the way out to the opening of the tube, and on the fourth proxy even the large opening on the top of the teapot has been sealed. As can be seen this is a very aggressive setting that probably shouldn’t be used apart from very specific cases.

New remesher
New remesher

Supported components

The RemeshingProcessor works with: