public class MeshUtilities
extends java.lang.Object
Constructor and Description |
---|
MeshUtilities() |
Modifier and Type | Method and Description |
---|---|
static void |
closeHoles(PolygonalMesh mesh,
int size)
Attempts to close holes smaller or equal to the given size
|
static void |
laplacianSmooth(PolygonalMesh mesh,
double lambda,
int iters)
Applies the Laplacian smoothing operating to the mesh, with cotangent weights
|
static void |
quadricEdgeCollapse(PolygonalMesh mesh,
int n)
Quadric edge-collapse decimation, removing vertices through edge-collapse based on
least quadric plane error
|
static void |
sqrt3Subdivide(PolygonalMesh mesh,
boolean even,
int niters)
Sqrt-3 subdivision
|
static void |
sqrt3Subdivide(PolygonalMesh mesh,
int niters)
Sqrt-3 subdivision
|
static void |
taubinSmooth(PolygonalMesh mesh,
double lambda,
double mu,
int iters)
Applies the Taubin smoothing operating to the mesh, with cotangent
weights, suggested factors 0
< lambda < -mu <= 1. |
public static void laplacianSmooth(PolygonalMesh mesh, double lambda, int iters)
mesh
- polygonal mesh to smoothlambda
- scale factor for gradient additioniters
- number of iterationspublic static void taubinSmooth(PolygonalMesh mesh, double lambda, double mu, int iters)
<
lambda <
-mu <=
1.
Meshlab uses lambda=0.5, mu=-0.53 by default.mesh
- polygonal mesh to smoothlambda
- scale factor for gradient addition (smoothing)mu
- scale factor for gradient additioniters
- number of iterationspublic static void quadricEdgeCollapse(PolygonalMesh mesh, int n)
mesh
- mesh to updaten
- number of edges to collapsepublic static void sqrt3Subdivide(PolygonalMesh mesh, int niters)
mesh
- mesh to subdivideniters
- number of iterationspublic static void sqrt3Subdivide(PolygonalMesh mesh, boolean even, int niters)
mesh
- mesh to subdivideeven
- set first iteration to an "even" split, where borders are not dividedniters
- number of iterationspublic static void closeHoles(PolygonalMesh mesh, int size)
mesh
- mesh to closesize
- max number of edges in hole (if <=
0, closes holes of
any size)