00001 #ifndef RGBDSLAM_AORB 00002 #define RGBDSLAM_AORB 00003 /*M/////////////////////////////////////////////////////////////////////////////////////// 00004 // 00005 // IMPORTANT: READ BEFORE DOWNLOADING, COPYING, INSTALLING OR USING. 00006 // 00007 // By downloading, copying, installing or using the software you agree to this license. 00008 // If you do not agree to this license, do not download, install, 00009 // copy or use the software. 00010 // 00011 // 00012 // License Agreement 00013 // For Open Source Computer Vision Library 00014 // 00015 // Copyright (C) 2000-2008, Intel Corporation, all rights reserved. 00016 // Copyright (C) 2009-2010, Willow Garage Inc., all rights reserved. 00017 // Third party copyrights are property of their respective owners. 00018 // 00019 // Redistribution and use in source and binary forms, with or without modification, 00020 // are permitted provided that the following conditions are met: 00021 // 00022 // * Redistribution's of source code must retain the above copyright notice, 00023 // this list of conditions and the following disclaimer. 00024 // 00025 // * Redistribution's in binary form must reproduce the above copyright notice, 00026 // this list of conditions and the following disclaimer in the documentation 00027 // and/or other materials provided with the distribution. 00028 // 00029 // * The name of the copyright holders may not be used to endorse or promote products 00030 // derived from this software without specific prior written permission. 00031 // 00032 // This software is provided by the copyright holders and contributors "as is" and 00033 // any express or implied warranties, including, but not limited to, the implied 00034 // warranties of merchantability and fitness for a particular purpose are disclaimed. 00035 // In no event shall the Intel Corporation or contributors be liable for any direct, 00036 // indirect, incidental, special, exemplary, or consequential damages 00037 // (including, but not limited to, procurement of substitute goods or services; 00038 // loss of use, data, or profits; or business interruption) however caused 00039 // and on any theory of liability, whether in contract, strict liability, 00040 // or tort (including negligence or otherwise) arising in any way out of 00041 // the use of this software, even if advised of the possibility of such damage. 00042 // 00043 //M*/ 00044 00045 #include "opencv2/core/core.hpp" 00049 namespace cv { 00050 class AORB : public Feature2D 00051 { 00052 public: 00053 // the size of the signature in bytes 00054 enum { kBytes = 32, HARRIS_SCORE=0, FAST_SCORE=1 }; 00055 00056 explicit AORB(int nfeatures = 500, float scaleFactor = 1.2f, int nlevels = 8, int edgeThreshold = 31, 00057 int firstLevel = 0, int WTA_K=2, int scoreType=0, int patchSize=31, int fastThreshold = 20 ); 00058 00059 // returns the descriptor size in bytes 00060 int descriptorSize() const; 00061 // returns the descriptor type 00062 int descriptorType() const; 00063 00064 // Compute the AORB features and descriptors on an image 00065 void operator()(InputArray image, InputArray mask, vector<KeyPoint>& keypoints) const; 00066 00067 // Compute the AORB features and descriptors on an image 00068 void operator()( InputArray image, InputArray mask, vector<KeyPoint>& keypoints, 00069 OutputArray descriptors, bool useProvidedKeypoints=false ) const; 00070 00071 AlgorithmInfo* info() const; 00072 00073 protected: 00074 00075 void computeImpl( const Mat& image, vector<KeyPoint>& keypoints, Mat& descriptors ) const; 00076 void detectImpl( const Mat& image, vector<KeyPoint>& keypoints, const Mat& mask=Mat() ) const; 00077 00078 CV_PROP_RW int nfeatures; 00079 CV_PROP_RW double scaleFactor; 00080 CV_PROP_RW int nlevels; 00081 CV_PROP_RW int edgeThreshold; 00082 CV_PROP_RW int fastThreshold; 00083 CV_PROP_RW int firstLevel; 00084 CV_PROP_RW int WTA_K; 00085 CV_PROP_RW int scoreType; 00086 CV_PROP_RW int patchSize; 00087 }; 00088 00089 typedef AORB AorbFeatureDetector; 00090 typedef AORB AorbDescriptorExtractor; 00091 00092 00093 } 00094 #endif