Go to the documentation of this file.00001
00018 #ifndef RATING_H
00019 #define RATING_H
00020
00021 #include <geometry_msgs/Pose.h>
00022 #include <geometry_msgs/Point.h>
00023 #include <Eigen/Dense>
00024
00025 namespace fake_object_recognition {
00026
00030 class Rating {
00031
00033 double fovx_;
00034
00036 double fovy_;
00037
00039 double ncp_;
00040
00042 double fcp_;
00043
00045 const Eigen::Vector3d camera_orientation_;
00046
00053 double getDistanceRating(const geometry_msgs::Pose &object_pose);
00054
00062 double getAngleRating(const geometry_msgs::Pose &object_pose, bool direction);
00063
00070 bool getBBRating(const std::array<geometry_msgs::Point, 8> &bounding_box);
00071
00080 double getNormalRating(const geometry_msgs::Pose &object_pose, const std::vector<geometry_msgs::Point> &normals);
00081
00082 public:
00091 Rating(double fovx, double fovy, double ncp, double fcp);
00092
00102 bool ratePose(const geometry_msgs::Pose &pose, double threshold_d, double threshold_x, double threshold_y);
00103
00115 bool rateBBandNormal(const geometry_msgs::Pose &object_pose, const std::array<geometry_msgs::Point, 8> &bounding_box, const std::vector<geometry_msgs::Point> &normals, double threshold);
00116 };
00117
00118 }
00119
00120 #endif
00121