Point Cloud Library (PCL)
1.9.1
|
45 #include <pcl/sample_consensus/ransac.h>
46 #include <pcl/sample_consensus/sac_model_registration.h>
47 #include <pcl/registration/registration.h>
48 #include <pcl/registration/transformation_estimation_svd.h>
49 #include <pcl/registration/transformation_estimation_point_to_plane_lls.h>
50 #include <pcl/registration/correspondence_estimation.h>
51 #include <pcl/registration/default_convergence_criteria.h>
93 template <
typename Po
intSource,
typename Po
intTarget,
typename Scalar =
float>
108 typedef boost::shared_ptr<IterativeClosestPoint<PointSource, PointTarget, Scalar> >
Ptr;
109 typedef boost::shared_ptr<const IterativeClosestPoint<PointSource, PointTarget, Scalar> >
ConstPtr;
181 std::vector<pcl::PCLPointField> fields;
184 for (
size_t i = 0; i < fields.size (); ++i)
187 else if (fields[i].name ==
"y")
y_idx_offset_ = fields[i].offset;
188 else if (fields[i].name ==
"z")
z_idx_offset_ = fields[i].offset;
189 else if (fields[i].name ==
"normal_x")
194 else if (fields[i].name ==
"normal_y")
199 else if (fields[i].name ==
"normal_z")
216 std::vector<pcl::PCLPointField> fields;
219 for (
size_t i = 0; i < fields.size (); ++i)
221 if (fields[i].name ==
"normal_x" || fields[i].name ==
"normal_y" || fields[i].name ==
"normal_z")
296 template <
typename Po
intSource,
typename Po
intTarget,
typename Scalar =
float>
308 typedef boost::shared_ptr<IterativeClosestPoint<PointSource, PointTarget, Scalar> >
Ptr;
309 typedef boost::shared_ptr<const IterativeClosestPoint<PointSource, PointTarget, Scalar> >
ConstPtr;
314 reg_name_ =
"IterativeClosestPointWithNormals";
337 #include <pcl/registration/impl/icp.hpp>
339 #endif //#ifndef PCL_ICP_H_
pcl::registration::DefaultConvergenceCriteria< Scalar >::Ptr getConvergeCriteria()
Returns a pointer to the DefaultConvergenceCriteria used by the IterativeClosestPoint class.
CorrespondencesPtr correspondences_
The set of correspondences determined at this ICP step.
This file defines compatibility wrappers for low level I/O functions.
virtual void setInputSource(const PointCloudSourceConstPtr &cloud)
Provide a pointer to the input source (e.g., the point cloud that we want to align to the target)
void setUseReciprocalCorrespondences(bool use_reciprocal_correspondence)
Set whether to use reciprocal correspondence or not.
boost::shared_ptr< IterativeClosestPoint< PointSource, PointTarget, Scalar > > Ptr
boost::shared_ptr< PointCloud< PointSource > > Ptr
virtual void setInputTarget(const PointCloudTargetConstPtr &cloud)
Provide a pointer to the input target (e.g., the point cloud that we want to align the input source t...
Registration represents the base registration class for general purpose, ICP-like methods.
void getFields(const pcl::PointCloud< PointT > &cloud, std::vector< pcl::PCLPointField > &fields)
Get the list of available fields (i.e., dimension/channel)
DefaultConvergenceCriteria represents an instantiation of ConvergenceCriteria, and implements the fol...
PointCloudSource::ConstPtr PointCloudSourceConstPtr
Eigen::Matrix< Scalar, 4, 4 > Matrix4
virtual void setInputSource(const PointCloudSourceConstPtr &cloud)
Provide a pointer to the input source (e.g., the point cloud that we want to align to the target)
PointCloudTarget::ConstPtr PointCloudTargetConstPtr
virtual void transformCloud(const PointCloudSource &input, PointCloudSource &output, const Matrix4 &transform)
Apply a rigid transform to a given dataset.
IterativeClosestPointWithNormals()
Empty constructor.
IterativeClosestPoint provides a base implementation of the Iterative Closest Point algorithm.
IterativeClosestPoint< PointSource, PointTarget, Scalar >::PointCloudSource PointCloudSource
Matrix4 transformation_
The transformation matrix estimated by the registration method.
bool use_reciprocal_correspondence_
The correspondence type used for correspondence estimation.
virtual void setInputTarget(const PointCloudTargetConstPtr &cloud)
Provide a pointer to the input target (e.g., the point cloud that we want to align to the target)
virtual void determineRequiredBlobData()
Looks at the Estimators and Rejectors and determines whether their blob-setter methods need to be cal...
virtual ~IterativeClosestPointWithNormals()
Empty destructor.
boost::shared_ptr< const IterativeClosestPoint< PointSource, PointTarget, Scalar > > ConstPtr
boost::shared_ptr< ::pcl::PointIndices > Ptr
boost::shared_ptr< DefaultConvergenceCriteria< Scalar > > Ptr
IterativeClosestPointWithNormals is a special case of IterativeClosestPoint, that uses a transformati...
IterativeClosestPoint< PointSource, PointTarget, Scalar >::Matrix4 Matrix4
virtual void transformCloud(const PointCloudSource &input, PointCloudSource &output, const Matrix4 &transform)
Apply a rigid transform to a given dataset.
Registration< PointSource, PointTarget, Scalar >::Matrix4 Matrix4
IterativeClosestPoint< PointSource, PointTarget, Scalar >::PointCloudTarget PointCloudTarget
pcl::registration::DefaultConvergenceCriteria< Scalar >::Ptr convergence_criteria_
virtual ~IterativeClosestPoint()
Empty destructor.
CorrespondenceEstimation represents the base class for determining correspondences between target and...
boost::shared_ptr< const IterativeClosestPoint< PointSource, PointTarget, Scalar > > ConstPtr
IterativeClosestPoint()
Empty constructor.
virtual void computeTransformation(PointCloudSource &output, const Matrix4 &guess)
Rigid transformation computation method with initial guess.
size_t nx_idx_offset_
Normal fields offset.
PointIndices::ConstPtr PointIndicesConstPtr
boost::shared_ptr< ::pcl::PointIndices const > ConstPtr
int nr_iterations_
The number of iterations the internal optimization ran for (used internally).
boost::shared_ptr< const PointCloud< PointSource > > ConstPtr
size_t x_idx_offset_
XYZ fields offset.
bool need_source_blob_
Checks for whether estimators and rejectors need various data.
boost::shared_ptr< IterativeClosestPoint< PointSource, PointTarget, Scalar > > Ptr
Registration< PointSource, PointTarget, Scalar >::PointCloudSource PointCloudSource
TransformationEstimationPtr transformation_estimation_
A TransformationEstimation object, used to calculate the 4x4 rigid transformation.
PointCloudTarget::Ptr PointCloudTargetPtr
bool source_has_normals_
Internal check whether source dataset has normals or not.
bool target_has_normals_
Internal check whether target dataset has normals or not.
PointCloudSource::Ptr PointCloudSourcePtr
bool getUseReciprocalCorrespondences() const
Obtain whether reciprocal correspondence are used or not.
std::string reg_name_
The registration method name.
Registration< PointSource, PointTarget, Scalar >::PointCloudTarget PointCloudTarget
CorrespondenceEstimationPtr correspondence_estimation_
A CorrespondenceEstimation object, used to estimate correspondences between the source and the target...
PointIndices::Ptr PointIndicesPtr