PanoDetectorDefs.h

Go to the documentation of this file.
00001 // -*- c-basic-offset: 4 ; tab-width: 4 -*-
00002 /*
00003 * Copyright (C) 2007-2008 Anael Orlinski
00004 *
00005 * This file is part of Panomatic.
00006 *
00007 * Panomatic is free software; you can redistribute it and/or modify
00008 * it under the terms of the GNU General Public License as published by
00009 * the Free Software Foundation; either version 2 of the License, or
00010 * (at your option) any later version.
00011 *
00012 * Panomatic is distributed in the hope that it will be useful,
00013 * but WITHOUT ANY WARRANTY; without even the implied warranty of
00014 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00015 * GNU General Public License for more details.
00016 *
00017 * You should have received a copy of the GNU General Public License
00018 * along with Panomatic; if not, write to the Free Software
00019 * <http://www.gnu.org/licenses/>.
00020 */
00021 
00022 #ifndef __detectpano_panodetectordefs_h
00023 #define __detectpano_panodetectordefs_h
00024 #include <vector>
00025 #include <iostream>
00026 
00027 #include <localfeatures/KeyPoint.h>
00028 #include "KDTree.h"
00029 #include "Utils.h"
00030 
00031 
00032 // define KDTree element from a KeyPointPtr
00033 // define a class to wrap an Ipoint and make it KDTree compliant.
00034 class KDElemKeyPoint : public KDTreeSpace::KDTreeElemInterface<double>
00035 {
00036 public:
00037     KDElemKeyPoint (lfeat::KeyPointPtr& iK, int iNumber) : _ivec(iK->_vec), _n(iNumber) {}
00038     inline double& getVectorElem(int iPos) const
00039     {
00040         return _ivec[iPos];   // access to the vector elements.
00041     }
00042     double* _ivec;
00043     size_t _n;
00044 };
00045 
00046 typedef std::vector<KDElemKeyPoint>     KDElemKeyPointVect_t;
00047 
00048 
00049 
00050 
00051 
00052 
00053 
00054 
00055 #endif // __detectpano_panodetectordefs_h
00056 

Generated on 30 Aug 2015 for Hugintrunk by  doxygen 1.4.7