feasibilitychecker.cpp
Go to the documentation of this file.
1 
18 #ifndef Q_MOC_RUN
19 #include <ros/ros.h>
20 #endif
21 
22 FeasibilityChecker::FeasibilityChecker(boost::shared_ptr<Calibration_Object> calibrationObject, const Eigen::Vector3d &expectedOrientationz, double maximumAngleDeviation)
23 {
24  this->calibrationObject = calibrationObject;
25  this->expectedOrientation_z = Eigen::Vector4d(expectedOrientationz[0], expectedOrientationz[1], expectedOrientationz[2], 0.0);
26  this->maximumAngleDeviation = maximumAngleDeviation;
27 }
28 
29 bool FeasibilityChecker::checkFeasibility_sideLengths(double sideA, double sideB, double sideC)
30 {
31  return (sideA <= calibrationObject->side_a && sideB <= calibrationObject->side_b && sideC <= calibrationObject->side_c);
32 }
33 
34 bool FeasibilityChecker::checkFeasibility_pose(const Eigen::Matrix4d& pose)
35 {
36  Eigen::Vector4d zAxis(0.0,0.0,1.0,0.0);
37  zAxis = pose*zAxis;
38  double angleDeviation = 1.0 - std::fabs(zAxis.dot(this->expectedOrientation_z));
39  return angleDeviation < maximumAngleDeviation;
40 }
bool checkFeasibility_sideLengths(double sideA, double sideB, double sideC)
EIGEN_MAKE_ALIGNED_OPERATOR_NEW FeasibilityChecker(boost::shared_ptr< Calibration_Object > calibrationObject, const Eigen::Vector3d &expectedOrientationz, double maximumAngleDeviation)
boost::shared_ptr< Calibration_Object > calibrationObject
bool checkFeasibility_pose(const Eigen::Matrix4d &pose)
Eigen::Vector4d expectedOrientation_z


asr_mild_calibration_tool
Author(s): Aumann Florian, Heller Florian, Meißner Pascal
autogenerated on Mon Dec 2 2019 03:11:43