MeshLib
 
Loading...
Searching...
No Matches
MRBestFitQuadric.h
Go to the documentation of this file.
1#pragma once
2#include "MRMeshEigen.h"
3#include "MRAffineXf3.h"
4
5namespace MR
6{
7
12{
13public:
15
17 MRMESH_API void addPoint( const Vector3d& point, double weight = 1.0 );
18
21 MRMESH_API Eigen::Matrix<double, 6, 1> calcBestCoefficients() const;
22
25 MRMESH_API static Vector3d findZeroProjection( const Eigen::Matrix<double, 6, 1>& coefs );
26private:
27 Eigen::Matrix<double, 6, 6> accumA_;
28 Eigen::Matrix<double, 6, 1> accumB_;
29};
30
31}
#define MRMESH_API
Definition MRMesh/MRMeshFwd.h:46
Definition MRBestFitQuadric.h:12
MRMESH_API Eigen::Matrix< double, 6, 1 > calcBestCoefficients() const
MRMESH_API void addPoint(const Vector3d &point, double weight=1.0)
Adds point to accumulation with weight.
static MRMESH_API Vector3d findZeroProjection(const Eigen::Matrix< double, 6, 1 > &coefs)
MRMESH_API QuadricApprox()
Definition MRCameraOrientationPlugin.h:7