SLProject  4.2.000
A platform independent 3D computer graphics framework for desktop OS, Android, iOS and online in web browsers
FeatureExtractorFactory.h
Go to the documentation of this file.
1 #ifndef FEATURE_EXTRACTOR_FACTORY
2 #define FEATURE_EXTRACTOR_FACTORY
3 
4 #include <map>
5 #include <string>
6 #include <memory>
7 
8 #include <KPextractor.h>
9 
11 {
21 };
22 
24 {
25 public:
27  std::unique_ptr<ORB_SLAM2::KPextractor> make(ExtractorType id, const cv::Size& videoFrameSize, int nLevels);
28  std::unique_ptr<ORB_SLAM2::KPextractor> make(std::string extractorType, const cv::Size& videoFrameSize, int nLevels);
29 
30  const std::vector<std::string>& getExtractorIdToNames() const
31  {
32  return _extractorIdToNames;
33  }
34 
35 private:
36  std::unique_ptr<ORB_SLAM2::KPextractor> orbExtractor(int nf, int nLevels);
37  std::unique_ptr<ORB_SLAM2::KPextractor> briefExtractor(int nf, int nLevels);
38 #ifndef TARGET_OS_IOS
39  std::unique_ptr<ORB_SLAM2::KPextractor> glslExtractor(
40  const cv::Size& videoFrameSize,
41  int nbKeypointsBigSigma,
42  int nbKeypointsSmallSigma,
43  float highThrs,
44  float lowThrs,
45  float bigSigma,
46  float smallSigma);
47 #endif
48 
49  std::vector<std::string> _extractorIdToNames;
50 };
51 
52 #endif // FEATURE_EXTRACTOR_FACTORY
@ ExtractorType_FAST_ORBS_2000
@ ExtractorType_FAST_ORBS_3000
@ ExtractorType_FAST_BRIEF_4000
@ ExtractorType_FAST_ORBS_1000
@ ExtractorType_FAST_ORBS_4000
@ ExtractorType_FAST_BRIEF_1000
@ ExtractorType_FAST_BRIEF_2000
@ ExtractorType_FAST_BRIEF_3000
@ ExtractorType_Last
std::unique_ptr< ORB_SLAM2::KPextractor > glslExtractor(const cv::Size &videoFrameSize, int nbKeypointsBigSigma, int nbKeypointsSmallSigma, float highThrs, float lowThrs, float bigSigma, float smallSigma)
const std::vector< std::string > & getExtractorIdToNames() const
std::unique_ptr< ORB_SLAM2::KPextractor > orbExtractor(int nf, int nLevels)
std::vector< std::string > _extractorIdToNames
std::unique_ptr< ORB_SLAM2::KPextractor > briefExtractor(int nf, int nLevels)
std::unique_ptr< ORB_SLAM2::KPextractor > make(ExtractorType id, const cv::Size &videoFrameSize, int nLevels)