MeshLib
 
Loading...
Searching...
No Matches
MRICP.h File Reference
#include "MRMeshOrPoints.h"
#include "MRMatrix3.h"
#include "MRId.h"
#include "MRConstants.h"
#include "MRAffineXf.h"
#include "MRBitSet.h"
#include <cfloat>

Go to the source code of this file.

Classes

struct  MR::PointPair
 Stores a pair of points: one samples on the source and the closest to it on the target. More...
 
struct  MR::PointPairs
 
struct  MR::NumSum
 
struct  MR::ICPProperties
 
struct  MR::MeshOrPointsXf
 an object and its transformation to global space with other objects More...
 
class  MR::ICP
 

Namespaces

namespace  MR
 

Enumerations

enum class  MR::ICPMethod { MR::Combined = 0 , MR::PointToPoint = 1 , MR::PointToPlane = 2 }
 The method how to update transformation from point pairs. More...
 
enum class  MR::ICPMode {
  MR::RigidScale , MR::AnyRigidXf , MR::OrthogonalAxis , MR::FixedAxis ,
  MR::TranslationOnly
}
 The group of transformations, each with its own degrees of freedom. More...
 
enum class  MR::ICPExitType {
  MR::NotStarted , MR::NotFoundSolution , MR::MaxIterations , MR::MaxBadIterations ,
  MR::StopMsdReached
}
 

Functions

MRMESH_API size_t MR::getNumActivePairs (const PointPairs &pairs)
 computes the number of active pairs
 
MRMESH_API NumSum MR::getSumSqDistToPoint (const PointPairs &pairs)
 computes the number of active pairs and the sum of squared distances between points
 
MRMESH_API NumSum MR::getSumSqDistToPlane (const PointPairs &pairs)
 computes the number of active pairs and the sum of squared deviation from points to target planes
 
float MR::getMeanSqDistToPoint (const PointPairs &pairs)
 computes root-mean-square deviation between points
 
float MR::getMeanSqDistToPlane (const PointPairs &pairs)
 computes root-mean-square deviation from points to target planes
 
MRMESH_API std::string MR::getICPStatusInfo (int iterations, ICPExitType exitType)
 returns status info string
 
void MR::updatePointPairs (PointPairs &pairs, const MeshOrPointsXf &src, const MeshOrPointsXf &tgt, float cosTreshold, float distThresholdSq, bool mutualClosest)
 in each pair updates the target data and performs basic filtering (activation)
 
size_t MR::deactivateFarPairs (PointPairs &pairs, float maxDistSq)
 reset active bit if pair distance is further than maxDistSq