MeshLib C++ Docs
Loading...
Searching...
No Matches
MRPointCloudTriangulation.h
Go to the documentation of this file.
1#pragma once
2
3#include "MRConstants.h"
4#include "MRMesh.h"
6#include <optional>
7
8namespace MR
9{
21struct TriangulationParameters
22{
36 int numNeighbours = 16;
37
43 float radius = 0;
44
56 float critAngle = PI2_F;
57
59 float boundaryAngle = 0.9f * PI_F;
60
65 float critHoleLength = -FLT_MAX;
66
68 bool automaticRadiusIncrease = true;
69
71 const PointCloud * searchNeighbors = nullptr;
72};
73
86[[nodiscard]] MRMESH_API std::optional<Mesh> triangulatePointCloud( const PointCloud& pointCloud,
87 const TriangulationParameters& params = {}, const ProgressCallback& progressCb = {} );
88
89struct FillHolesWithExtraPointsParams
90{
91 TriangulationParameters triangulation;
92
95 const VertBitSet* modifyBdVertices = nullptr;
96};
97
101[[nodiscard]] MRMESH_API bool fillHolesWithExtraPoints( Mesh & mesh, PointCloud& extraPoints,
102 const FillHolesWithExtraPointsParams& params = {}, const ProgressCallback& progressCb = {} );
103
104} //namespace MR
#define MRMESH_API
Definition MRMeshFwd.h:80
Definition MRPointCloudTriangulation.h:90
new unsafe MR.? Const_VertBitSet modifyBdVertices
Definition MRMesh/MRMesh.h:23
Definition MRMesh/MRPointCloud.h:17
Definition MRPointCloudTriangulation.h:22
new unsafe ref bool automaticRadiusIncrease
new unsafe ref int numNeighbours
new unsafe MR.? Const_PointCloud searchNeighbors
new unsafe ref float radius
new unsafe ref float critHoleLength
new unsafe ref float boundaryAngle
new unsafe ref float critAngle
MRMESH_API std::optional< Mesh > triangulatePointCloud(const PointCloud &pointCloud, const TriangulationParameters &params={}, const ProgressCallback &progressCb={})
Creates mesh from given point cloud according params Returns empty optional if was interrupted by pro...
Definition MRCameraOrientationPlugin.h:8
MRMESH_API bool fillHolesWithExtraPoints(Mesh &mesh, PointCloud &extraPoints, const FillHolesWithExtraPointsParams &params={}, const ProgressCallback &progressCb={})