00001 #ifndef FACE_CONTOUR_DETECTOR_FILTERS_EDGECONNECTORGRAPHBASED_H_ 00002 #define FACE_CONTOUR_DETECTOR_FILTERS_EDGECONNECTORGRAPHBASED_H_ 00003 00004 #include <face_contour_detector/filters/Filter.h> 00005 #include <face_contour_detector/filters/Parameter.h> 00006 #include <vector> 00007 #include <string> 00008 #include <opencv/cv.h> 00009 #include <cmath> 00010 #include <math.h> 00011 00012 namespace face_contour_detector { 00013 namespace filters { 00015 class EdgeConnectorGraphBased : public Filter { 00016 public: 00017 EdgeConnectorGraphBased(); 00018 00019 virtual std::vector<filters::Parameter> GetParameters(); 00023 virtual void Apply(const cv::Mat& input, cv::Mat& result); 00024 virtual void ResetParameters(); 00025 virtual const std::string& GetFilterName(); 00026 protected: 00027 int m_searchRadius; 00028 unsigned char m_connectValue; 00029 void M_Connect(cv::Mat& image, int x1, int y1, int x2, int y2); 00030 //static 00031 static std::string m_filterName; 00032 }; 00033 00034 //implementation 00035 00036 } 00037 } 00038 00039 #endif /* FILTER_EDGECONNECTORGRAPHBASED_H_ */