25 void addPoint(
const Vector3f& pt,
float weight ) {
addPoint( Vector3d( pt ), weight ); }
29 Plane3f getBestPlanef()
const {
return Plane3f( getBestPlane() ); }
32 Line3f getBestLinef()
const {
return Line3f( getBestLine() ); }
35 MRMESH_API bool getCenteredCovarianceEigen( Vector3d & centroid, Matrix3d & eigenvectors, Vector3d & eigenvalues )
const;
36 MRMESH_API bool getCenteredCovarianceEigen( Vector3f& centroid, Matrix3f& eigenvectors, Vector3f& eigenvalues )
const;
41 AffineXf3f getBasicXf3f()
const {
return AffineXf3f( getBasicXf() ); }
45 MRMESH_API std::array<AffineXf3d, 4> get4BasicXfs()
const;
46 MRMESH_API std::array<AffineXf3f, 4> get4BasicXfs3f()
const;
48 bool valid()
const {
return sumWeight_ > 0; };
51 double sumWeight_ = 0;
53 SymMatrix3d momentum2_;
85 MRMESH_API Vector3d findBestCrossPoint(
const Vector3d & p0,
double tol,
int * rank =
nullptr, Vector3d * space =
nullptr )
const;
86 MRMESH_API Vector3f findBestCrossPoint(
const Vector3f & p0,
float tol,
int * rank =
nullptr, Vector3f * space =
nullptr )
const;
#define MRMESH_API
Definition MRMeshFwd.h:80
Definition MRBestFit.h:75
unsafe void addPlane(MR.Const_Plane3d pl)
Definition MRBestFit.h:20
unsafe void addPoint(in MR.Vector3d pt)
Definition MRPointCloudPart.h:10
MRMESH_API void accumulateWeighedPoints(PointAccumulator &accum, const std::vector< Vector3f > &points, const std::vector< float > &weights, const AffineXf3f *xf=nullptr)
Adds in existing PointAccumulator all given weighed points.
MRMESH_API void accumulateLineCenters(PointAccumulator &accum, const Polyline3 &pl, const AffineXf3f *xf=nullptr)
Adds in existing PointAccumulator all line centers with the weight equal to the length line.
MRMESH_API void accumulateFaceCenters(PointAccumulator &accum, const MeshPart &mp, const AffineXf3f *xf=nullptr)
Adds in existing PointAccumulator all mesh face centers with the weight equal to face area.
MRMESH_API void accumulatePoints(PointAccumulator &accum, const std::vector< Vector3f > &points, const AffineXf3f *xf=nullptr)
Adds in existing PointAccumulator all given points.
Definition MRCameraOrientationPlugin.h:8