Image Component Library (ICL)
|
00001 /******************************************************************** 00002 ** Image Component Library (ICL) ** 00003 ** ** 00004 ** Copyright (C) 2006-2013 CITEC, University of Bielefeld ** 00005 ** Neuroinformatics Group ** 00006 ** Website: www.iclcv.org and ** 00007 ** http://opensource.cit-ec.de/projects/icl ** 00008 ** ** 00009 ** File : ICLMarkers/src/ICLMarkers/FiducialDetectorPluginForQua ** 00010 ** ds.h ** 00011 ** Module : ICLMarkers ** 00012 ** Authors: Christof Elbrechter ** 00013 ** ** 00014 ** ** 00015 ** GNU LESSER GENERAL PUBLIC LICENSE ** 00016 ** This file may be used under the terms of the GNU Lesser General ** 00017 ** Public License version 3.0 as published by the ** 00018 ** ** 00019 ** Free Software Foundation and appearing in the file LICENSE.LGPL ** 00020 ** included in the packaging of this file. Please review the ** 00021 ** following information to ensure the license requirements will ** 00022 ** be met: http://www.gnu.org/licenses/lgpl-3.0.txt ** 00023 ** ** 00024 ** The development of this software was supported by the ** 00025 ** Excellence Cluster EXC 277 Cognitive Interaction Technology. ** 00026 ** The Excellence Cluster EXC 277 is a grant of the Deutsche ** 00027 ** Forschungsgemeinschaft (DFG) in the context of the German ** 00028 ** Excellence Initiative. ** 00029 ** ** 00030 ********************************************************************/ 00031 00032 #pragma once 00033 00034 #include <ICLUtils/CompatMacros.h> 00035 #include <ICLMarkers/FiducialDetectorPlugin.h> 00036 #include <ICLMarkers/QuadDetector.h> 00037 00038 namespace icl{ 00039 namespace markers{ 00040 00042 class FiducialDetector; 00046 00047 class ICLMarkers_API FiducialDetectorPluginForQuads : public FiducialDetectorPlugin{ 00049 struct Data; 00050 00052 Data *data; 00053 00054 protected: 00055 00057 FiducialDetectorPluginForQuads(); 00058 public: 00059 00061 friend class icl::markers::FiducialDetector; 00062 00064 ~FiducialDetectorPluginForQuads(); 00065 00066 // use the edges 00067 virtual void getKeyPoints2D(std::vector<Fiducial::KeyPoint> &dst, FiducialImpl &impl); 00068 virtual void getFeatures(Fiducial::FeatureSet &dst); 00069 virtual void detect(std::vector<FiducialImpl*> &dst, const core::Img8u &image); 00070 00072 virtual SourceImageType getPreProcessing() const { return Gray; } 00073 00075 00086 virtual void addOrRemoveMarkers(bool add, const utils::Any &which, const utils::ParamList ¶ms) = 0; 00087 00089 std::string getIntermediateImageNames() const; 00090 00092 00093 const core::ImgBase *getIntermediateImage(const std::string &name) const throw (utils::ICLException); 00094 00096 00099 virtual void prepareForPatchClassification(){} 00100 00102 virtual FiducialImpl *classifyPatch(const core::Img8u &image, int *rot, bool returnRejectedQuads, cv::ImageRegion r) = 0; 00103 00105 00106 virtual void getQuadRectificationParameters(utils::Size &markerSizeWithBorder, 00107 utils::Size &markerSizeWithoutBorder) = 0; 00108 00110 QuadDetector& getQuadDetector(); 00111 00112 }; 00113 } // namespace markers 00114 } 00115