SMOOTHMESH Smooth mesh by replacing each vertex by the average of its neighbors. V2 = smoothMesh(V, F) [V2, F2] = smoothMesh(V, F) Performs smoothing of the values given in V, by using adjacency information given in F. V is a numeric array representing either vertex coordinate, or value field associated to each vertex. F is an array of faces, given either as a NF-by-3 or NF-by-4 numeric array, or as a cell array. Artifact adjacencies are added if faces have more than 4 vertices. ... = smoothMesh(V, F, NITER) Repeat the smoothing procedure NITER times. This is equivalent to calling the smoothMesh function NITER times. Example [v f] = torusMesh([50 50 50 30 10 30 45]); v = v + randn(size(v)); [v2 f] = smoothMesh(v, f, 3); figure; drawMesh(v2, f); l = light; lighting gouraud See also meshes3d, meshAdjacencyMatrix, triangulateFaces, drawMesh
Package: matgeom