#include <SurfPlanarDetector.h>
Public Member Functions | |
void | detect (ObjectDetectorMethod::DetectionData &data, ObjectModel &model, re_msgs::DetectedObject &detection) |
SurfPlanarDetector () | |
virtual | ~SurfPlanarDetector () |
Protected Member Functions | |
bool | alignedPoints (const ObjectModel::Face &face, const std::vector< int > indices) const |
bool | detectWithHomography (const SurfSet &scene_surfset, ObjectModel &model, ObjectModel::Face &face, const std::vector< int > &model_indices, const std::vector< int > &scene_indices, const std::vector< float > &distances, const ObjectDetectorMethod::DetectionData &data, const double maxReprojectionError, bool doReChecking, re_msgs::DetectedObject &detection) |
Protected Attributes | |
std::string | m_debug_prefix |
times ::detect has been called | |
int | m_detect_counter |
Definition at line 48 of file SurfPlanarDetector.h.
SurfPlanarDetector::SurfPlanarDetector | ( | ) | [inline] |
Definition at line 53 of file SurfPlanarDetector.h.
virtual SurfPlanarDetector::~SurfPlanarDetector | ( | ) | [inline, virtual] |
Definition at line 58 of file SurfPlanarDetector.h.
bool SurfPlanarDetector::alignedPoints | ( | const ObjectModel::Face & | face, |
const std::vector< int > | indices | ||
) | const [protected] |
Checks if a set of points are aligned in the 3D space
face | |
indices | indices of 3D face points to check |
Definition at line 189 of file SurfPlanarDetector.cpp.
void SurfPlanarDetector::detect | ( | ObjectDetectorMethod::DetectionData & | data, |
ObjectModel & | model, | ||
re_msgs::DetectedObject & | detection | ||
) | [virtual] |
Tries to detect in the given data the given model. Results are stored in detection
data | |
model | model to search for |
detection | results |
Implements ObjectDetectorMethod.
Definition at line 76 of file SurfPlanarDetector.cpp.
bool SurfPlanarDetector::detectWithHomography | ( | const SurfSet & | scene_surfset, |
ObjectModel & | model, | ||
ObjectModel::Face & | face, | ||
const std::vector< int > & | model_indices, | ||
const std::vector< int > & | scene_indices, | ||
const std::vector< float > & | distances, | ||
const ObjectDetectorMethod::DetectionData & | data, | ||
const double | maxReprojectionError, | ||
bool | doReChecking, | ||
re_msgs::DetectedObject & | detection | ||
) | [protected] |
Given the correspondences between the scene and the model, tries to detect the object with an homography
scene_surfset | surfs from the original image |
model | model checked |
face | face of the model checked |
model_indices | indices of model keypoints matched |
scene_indices | indices of scene keypoints matched |
distances | distances between the matched keypoint descriptors |
data | common detection data |
maxReprojectionError | max reprojection error to accept a reprojected point as an inlier |
doReChecking | if true, the algorithm is run again with the inliers got in the first iteration and with a smaller maxReprojectionError |
detection | place to put the results in |
Definition at line 222 of file SurfPlanarDetector.cpp.
std::string SurfPlanarDetector::m_debug_prefix [protected] |
times ::detect has been called
Definition at line 112 of file SurfPlanarDetector.h.
int SurfPlanarDetector::m_detect_counter [protected] |
Definition at line 111 of file SurfPlanarDetector.h.