MeshLib C++ Docs
Loading...
Searching...
No Matches
MRAlphaShape.h File Reference
#include "MRMeshFwd.h"
#include "MRPrecisePredicates3.h"
#include "MRFastInt128.h"
#include "MRVector.h"
#include "MRBitSet.h"
#include "MRPch/MRBindingMacros.h"
#include <cstddef>
#include <optional>

Go to the source code of this file.

Classes

struct  MR::AlphaShapeData
struct  MR::AlphaShapeStats
struct  MR::AlphaShapeNei
 a neighbour of the point v in the search of alpha-shape triangles around it More...
struct  MR::BallPivotCandidate
 a point touchable by a ball together with the edge (vi, vj) in the search of findBallPivotVertex More...

Namespaces

namespace  MR
 Only strictly necessary for the bindings (to make MR::MeshIntersectionResult a complete type).

Functions

AlphaShapeData MR::getAlphaShapeData (const PointCloud &cloud, float radius, bool allPoints)
void MR::findAlphaShapeNeiTriangles (const PointCloud &cloud, VertId v, const AlphaShapeData &data, Triangulation &appendTris, Vector< AlphaShapeNei > &neis, bool onlyLargerVids, AlphaShapeStats *stats=nullptr)
 optional statistics of the work done, which is increased here
VertId MR::findBallPivotVertex (const PointCloud &cloud, VertId vi, VertId vj, VertId vk, const AlphaShapeData &data, Vector< BallPivotCandidate > &cands)
 temporary storage to avoid memory allocations, it will be filled with the touchable points in unspecified order
std::optional< Triangulation > MR::findAlphaShapeAllTriangles (const PointCloud &cloud, float radius, const ProgressCallback &cb, AlphaShapeStats *stats=nullptr)
 finds all triangles of alpha-shape with negative alpha = -1/radius
Triangulation MR::findAlphaShapeAllTriangles (const PointCloud &cloud, float radius, AlphaShapeStats *stats=nullptr)
std::optional< Triangulation > MR::findAlphaShapeAllTriangles (const PointCloud &cloud, const AlphaShapeData &data, const ProgressCallback &cb, AlphaShapeStats *stats=nullptr)
Triangulation MR::findAlphaShapeAllTriangles (const PointCloud &cloud, const AlphaShapeData &data, AlphaShapeStats *stats=nullptr)
std::optional< Mesh > MR::findAlphaShape (const PointCloud &cloud, float radius, const ProgressCallback &cb, std::vector< MeshBuilder::VertDuplication > *dups=nullptr, AlphaShapeStats *stats=nullptr)
Mesh MR::findAlphaShape (const PointCloud &cloud, float radius, std::vector< MeshBuilder::VertDuplication > *dups=nullptr, AlphaShapeStats *stats=nullptr)
std::optional< ThreeVertIds > MR::findBallPivotingSeed (const PointCloud &cloud, VertId v, const Vector3f &dir, const AlphaShapeData &data, Triangulation &tris, Vector< AlphaShapeNei > &neis)
 temporary storage to avoid memory allocations, see findAlphaShapeNeiTriangles
std::optional< Triangulation > MR::findBallPivotingComponent (const PointCloud &cloud, const ThreeVertIds &seed, const AlphaShapeData &data, const ProgressCallback &cb={})
 reports the fraction of the cloud points in the triangles found so far, so it stays small for a small piece
std::optional< Triangulation > MR::findBallPivotingTriangles (const PointCloud &cloud, const AlphaShapeData &data, bool allComponents=false, const ProgressCallback &cb={})
std::optional< Mesh > MR::findBallPivotingMesh (const PointCloud &cloud, float radius, bool allComponents, const ProgressCallback &cb, std::vector< MeshBuilder::VertDuplication > *dups=nullptr)
Mesh MR::findBallPivotingMesh (const PointCloud &cloud, float radius, bool allComponents=false, std::vector< MeshBuilder::VertDuplication > *dups=nullptr)