40 #ifndef PCL_REGISTRATION_TRANSFORMATION_ESTIMATION_POINT_TO_PLANE_WEIGHTED_H_
41 #define PCL_REGISTRATION_TRANSFORMATION_ESTIMATION_POINT_TO_PLANE_WEIGHTED_H_
43 #include <pcl/registration/transformation_estimation_point_to_plane.h>
44 #include <pcl/registration/warp_point_rigid.h>
45 #include <pcl/registration/distances.h>
49 namespace registration
58 template <
typename Po
intSource,
typename Po
intTarget,
typename MatScalar =
float>
71 typedef boost::shared_ptr<TransformationEstimationPointToPlaneWeighted<PointSource, PointTarget, MatScalar> >
Ptr;
72 typedef boost::shared_ptr<const TransformationEstimationPointToPlaneWeighted<PointSource, PointTarget, MatScalar> >
ConstPtr;
74 typedef Eigen::Matrix<MatScalar, Eigen::Dynamic, 1>
VectorX;
75 typedef Eigen::Matrix<MatScalar, 4, 1>
Vector4;
122 Matrix4 &transformation_matrix)
const;
134 const std::vector<int> &indices_src,
136 Matrix4 &transformation_matrix)
const;
150 const std::vector<int> &indices_src,
152 const std::vector<int> &indices_tgt,
153 Matrix4 &transformation_matrix)
const;
167 Matrix4 &transformation_matrix)
const;
203 boost::shared_ptr<pcl::registration::WarpPointRigid<PointSource, PointTarget, MatScalar> >
warp_point_;
209 template<
typename _Scalar,
int NX=Eigen::Dynamic,
int NY=Eigen::Dynamic>
218 typedef Eigen::Matrix<_Scalar,InputsAtCompileTime,1>
InputType;
219 typedef Eigen::Matrix<_Scalar,ValuesAtCompileTime,1>
ValueType;
220 typedef Eigen::Matrix<_Scalar,ValuesAtCompileTime,InputsAtCompileTime>
JacobianType;
333 EIGEN_MAKE_ALIGNED_OPERATOR_NEW
338 #include <pcl/registration/impl/transformation_estimation_point_to_plane_weighted.hpp>
OptimizationFunctor(int m_data_points, const TransformationEstimationPointToPlaneWeighted *estimator)
Functor constructor.
TransformationEstimationPointToPlaneWeighted & operator=(const TransformationEstimationPointToPlaneWeighted &src)
Copy operator.
bool use_correspondence_weights_
int operator()(const VectorX &x, VectorX &fvec) const
Fill fvec from x.
Functor(int m_data_points)
Constructor.
int operator()(const VectorX &x, VectorX &fvec) const
Fill fvec from x.
TransformationEstimationPointToPlaneWeighted uses Levenberg Marquardt optimization to find the transf...
Functor()
Empty Construtor.
Eigen::Matrix< _Scalar, ValuesAtCompileTime, InputsAtCompileTime > JacobianType
Eigen::Matrix< _Scalar, ValuesAtCompileTime, 1 > ValueType
boost::shared_ptr< const TransformationEstimationPointToPlaneWeighted< PointSource, PointTarget, MatScalar > > ConstPtr
TransformationEstimation< PointSource, PointTarget, MatScalar >::Matrix4 Matrix4
const std::vector< int > * tmp_idx_tgt_
Temporary pointer to the target dataset indices.
boost::shared_ptr< ::pcl::PointIndices const > ConstPtr
boost::shared_ptr< ::pcl::PointIndices > Ptr
const TransformationEstimationPointToPlaneWeighted< PointSource, PointTarget, MatScalar > * estimator_
TransformationEstimationPointToPlaneWeighted(const TransformationEstimationPointToPlaneWeighted &src)
Copy constructor.
boost::shared_ptr< pcl::registration::WarpPointRigid< PointSource, PointTarget, MatScalar > > warp_point_
The parameterized function used to warp the source to the target.
OptimizationFunctorWithIndices(int m_data_points, const TransformationEstimationPointToPlaneWeighted *estimator)
Functor constructor.
OptimizationFunctorWithIndices & operator=(const OptimizationFunctorWithIndices &src)
Copy operator.
Eigen::Matrix< MatScalar, 4, 1 > Vector4
virtual ~OptimizationFunctorWithIndices()
Destructor.
boost::shared_ptr< PointCloud< PointT > > Ptr
const PointCloudTarget * tmp_tgt_
Temporary pointer to the target dataset.
OptimizationFunctorWithIndices(const OptimizationFunctorWithIndices &src)
Copy constructor.
boost::shared_ptr< const PointCloud< PointT > > ConstPtr
const std::vector< int > * tmp_idx_src_
Temporary pointer to the source dataset indices.
Base functor all the models that need non linear optimization must define their own one and implement...
OptimizationFunctor(const OptimizationFunctor &src)
Copy constructor.
virtual ~OptimizationFunctor()
Destructor.
boost::shared_ptr< TransformationEstimationPointToPlaneWeighted< PointSource, PointTarget, MatScalar > > Ptr
Eigen::Matrix< MatScalar, Eigen::Dynamic, 1 > VectorX
void setWarpFunction(const boost::shared_ptr< WarpPointRigid< PointSource, PointTarget, MatScalar > > &warp_fcn)
Set the function we use to warp points.
std::vector< pcl::Correspondence, Eigen::aligned_allocator< pcl::Correspondence > > Correspondences
virtual ~TransformationEstimationPointToPlaneWeighted()
Destructor.
const PointCloudSource * tmp_src_
Temporary pointer to the source dataset.
virtual ~Functor()
Destructor.
void setUseCorrespondenceWeights(bool use_correspondence_weights)
use the weights given in the pcl::CorrespondencesPtr for one of the estimateTransformation (...
OptimizationFunctor & operator=(const OptimizationFunctor &src)
Copy operator.
std::vector< double > correspondence_weights_
const TransformationEstimationPointToPlaneWeighted< PointSource, PointTarget, MatScalar > * estimator_
Eigen::Matrix< _Scalar, InputsAtCompileTime, 1 > InputType
void setWeights(const std::vector< double > &weights)
int values() const
Get the number of values.
Eigen::Matrix< MatScalar, Eigen::Dynamic, 1 > VectorX
TransformationEstimationPointToPlaneWeighted()
Constructor.
TransformationEstimation represents the base class for methods for transformation estimation based on...
TransformationEstimationPointToPlane uses Levenberg Marquardt optimization to find the transformation...
void estimateRigidTransformation(const pcl::PointCloud< PointSource > &cloud_src, const pcl::PointCloud< PointTarget > &cloud_tgt, Matrix4 &transformation_matrix) const
Estimate a rigid rotation transformation between a source and a target point cloud using LM...