#include <MRNormalsToPoints.h>
Classes | |
class | ISolver |
Public Member Functions | |
MRMESH_API void | prepare (const MeshTopology &topology, float guideWeight=1) |
MRMESH_API void | run (const VertCoords &guide, const FaceNormals &normals, VertCoords &points) |
MRMESH_API void | run (const VertCoords &guide, const FaceNormals &normals, VertCoords &points, float maxInitialDistSq) |
The purpose of this class is to update vertex positions given target triangle normals; see the article "Static/Dynamic Filtering for Mesh Geometry"
MRMESH_API void MR::NormalsToPoints::prepare | ( | const MeshTopology & | topology, |
float | guideWeight = 1 ) |
builds linear system and prepares a solver for it; please call it only once for mesh, and then run as many times as you like
guideWeight | how much resulting points must be attracted to initial points, must be > 0 |
MRMESH_API void MR::NormalsToPoints::run | ( | const VertCoords & | guide, |
const FaceNormals & | normals, | ||
VertCoords & | points ) |
performs one iteration consisting of projection of all triangles on planes with given normals and finding best points from them
guide | target vertex positions to avoid under-determined system |
normals | target face normals |
points | initial approximation on input, updated approximation on output |
maxInitialDistSq | the maximum squared distance between a point and its position in (guide) |
MRMESH_API void MR::NormalsToPoints::run | ( | const VertCoords & | guide, |
const FaceNormals & | normals, | ||
VertCoords & | points, | ||
float | maxInitialDistSq ) |