// Set the given cloud as the target to which the templates will be aligned
 void
 setTargetCloud (FeatureCloud &target_cloud)
 {
     target_ = target_cloud;
     sac_ia_.setInputTarget (target_cloud.getPointCloud ());
     sac_ia_.setTargetFeatures (target_cloud.getLocalFeatures ());
 }
void TemplateAlignment::align( FeatureCloud &template_cloud, TemplateAlignment::Result &result )
{
	sac_ia_.setInputCloud( template_cloud.getPointCloud() );
	sac_ia_.setSourceFeatures( template_cloud.getLocalFeatures() );
	
	pcl::PointCloud<pcl::PointXYZ> registration_output;
	sac_ia_.align( registration_output );
	
	result.fitness_score = (float)sac_ia_.getFitnessScore( max_correspondence_distance_ );
	result.final_transformation = sac_ia_.getFinalTransformation();
}
void TemplateAlignment::setTargetCloud( FeatureCloud &target_cloud )
{
	target_ = target_cloud;
	sac_ia_.setInputTarget( target_cloud.getPointCloud() );
	sac_ia_.setTargetFeatures( target_cloud.getLocalFeatures() );
}