00001
00015 #ifndef MDS_TRIVERTEXDETECTOR_H
00016 #define MDS_TRIVERTEXDETECTOR_H
00017
00018 #include "mdsTriBase.h"
00019
00020
00021 #include <MDSTk/Base/mdsAssert.h>
00022 #include <MDSTk/Base/mdsIdentifier.h>
00023 #include <MDSTk/Image/mdsImageFunctions.h>
00024 #include <MDSTk/Math/mdsBase.h>
00025
00026
00027 #include <VectorEntity/mcvertices.h>
00028
00029
00030 #include <sstream>
00031
00032
00033 namespace mds
00034 {
00035 namespace seg
00036 {
00037
00038
00039
00040
00041
00042
00044 MDS_DECLARE_ID(CELL_MAX);
00045
00046
00047
00052 template <typename Id>
00053 class CTriVertexDetector
00054 {
00055 public:
00058 bool operator()(const mds::img::CDImage *pImage, vctl::MCVerticeS *pVertices);
00059 };
00060
00061
00062
00068 template <>
00069 class CTriVertexDetector<CELL_MAX>
00070 {
00071 public:
00078 CTriVertexDetector(double dThreshold,
00079 mds::tSize CellSize,
00080 mds::tSize CellMargin
00081 )
00082 : m_dThreshold(dThreshold)
00083 , m_CellSize(CellSize)
00084 , m_CellMargin(CellMargin)
00085 {}
00086
00089 bool operator()(const mds::img::CDImage *pImage, vctl::MCVerticeS *pVertices);
00090
00091 protected:
00093 double m_dThreshold;
00094
00096 mds::tSize m_CellSize, m_CellMargin;
00097 };
00098
00099
00100
00101
00102
00103
00104
00105
00106 #include "mdsTriVertexDetector.hxx"
00107
00108
00109 }
00110 }
00111
00112 #endif // MDS_TRIVERTEXDETECTOR_H
00113