Main Page | Modules | Namespace List | Class Hierarchy | Class List | File List | Namespace Members | Class Members | File Members | Related Pages
matchpoint/Descriptor.h
Go to the documentation of this file.00001 /*************************************************************************** 00002 * Copyright (C) 2007 by Zoran Mesec * 00003 * zoran.mesec@gmail.com * 00004 * * 00005 * This program is free software; you can redistribute it and/or modify * 00006 * it under the terms of the GNU General Public License as published by * 00007 * the Free Software Foundation; either version 2 of the License, or * 00008 * (at your option) any later version. * 00009 * * 00010 * This program is distributed in the hope that it will be useful, * 00011 * but WITHOUT ANY WARRANTY; without even the implied warranty of * 00012 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * 00013 * GNU General Public License for more details. * 00014 * * 00015 * You should have received a copy of the GNU General Public License * 00016 * along with this program; if not, write to the * 00017 * Free Software Foundation, Inc., * 00018 * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * 00019 ***************************************************************************/ 00020 00021 #ifndef DESCRIPTOR_H_INCLUDED 00022 #define DESCRIPTOR_H_INCLUDED 00023 #include <string> 00024 #include "APImage.h" 00025 #include "HessianDetector.h" 00026 00027 #define NR_ANGLE_BINS 8 00028 #define DESCRIPTOR_SIZE 36 00029 00030 class Descriptor 00031 { 00032 public: 00033 Descriptor(APImage* i, HessianDetector* hd); 00034 double _gaussWeighting(int x, int y, double stdev); 00035 00036 00037 00038 void setPoints(vector<vector<int> >* pts); 00039 //void orientate(); 00040 void createDescriptors(); 00041 vector<vector<double> >* getDescriptors(); 00042 bool printDescriptors(string name); 00043 bool generateAutopanoXML(string name); 00044 vector<vector<int> >* interestPoints; 00045 00046 00047 private: 00048 APImage* image; 00049 HessianDetector* hd; 00050 00051 double _getMaxima(int x,int y); 00052 double _euclidianDistance(int x1, int y1, int x2, int y2); 00053 //double _initDescriptor(double* desciptor); 00054 void _GaborResponse(int x,int y,double maxima,double* descriptor); 00055 void _RegionResponse(int x,int y,double maxima,double* descriptor); 00056 void _ShapeContext(int x,int y,double maxima,double* descriptor); 00057 00058 vector<vector<int> >* maximas; 00059 vector<vector<double> > descriptors; 00060 //int orientations[]; 00061 }; 00062 00063 00064 00065 #endif // DESCRIPTOR_H_INCLUDED
1.3.9.1