IPSDK  4_1_0_2
IPSDK : Image Processing Software Development Kit
ThicknessSeparator.h
1 // ThicknessSeparator.h:
3 // ---------------------
4 //
14 
15 #ifndef __IPSDKBASESHAPESEGMENTATION_THICKNESSSEPARATOR_H__
16 #define __IPSDKBASESHAPESEGMENTATION_THICKNESSSEPARATOR_H__
17 
21 #include <map>
22 
23 namespace ipsdk {
24 namespace shape {
25 namespace segmentation {
26 
29 
31 {
32 public:
38 
39 // methods
40 public:
42  void separate(ipsdk::geom::Shape2d& shape,
43  const ipReal64 thicknessThreshold);
44 
45 // predefined protected types
46 protected:
48  typedef std::pair<ipsdk::geom::Shape2dPoint, ipsdk::geom::Shape2dPoint> Shape2dSegment;
49 
52  typedef std::multimap<ipReal64, Shape2dSegment> ThicknessInfoMap;
53 
54 protected:
59  BoolResult separate(const ipsdk::geom::Shape2dPolygonWithHolesPtr& pPolygonWithHoles,
60  ipsdk::geom::Shape2dPolygonWithHolesColl& polygonDecompositionColl,
61  const ipReal64 thicknessThreshold);
62 
65  void computeThicknessInfo(const ipsdk::geom::Skeleton2d& skeleton,
66  const ipReal64 thicknessThreshold,
67  ThicknessInfoMap& thicknessInfoMap);
68 
69 // attributes
70 protected:
71 
72 };
73 
76 
77 } // end of namespace segmentation
78 } // end of namespace shape
79 } // end of namespace ipsdk
80 
81 #endif // __IPSDKBASESHAPESEGMENTATION_THICKNESSSEPARATOR_H__
Main namespace for IPSDK library.
Definition: AlgorithmFunctionEfficiency.h:22
std::vector< Shape2dPolygonWithHolesPtr > Shape2dPolygonWithHolesColl
collection of polygon with holes
Definition: Shape2dTypes.h:78
double ipReal64
Base types definition.
Definition: BaseTypes.h:57
std::pair< ipsdk::geom::Shape2dPoint, ipsdk::geom::Shape2dPoint > Shape2dSegment
pair of polygon points
Definition: ThicknessSeparator.h:48
Definition of import/export macro for library.
Class allowing to represent a skeleton associated to a polygon with holes.
Definition: Skeleton2d.h:37
Class used to separate shapes.
Definition: ThicknessSeparator.h:30
Predefined types for voronoi skeleton management.
Shape 2d associated to one or more closed polygon 2d.
Definition: Shape2d.h:35
Predefined types for shape 2d management.
std::multimap< ipReal64, Shape2dSegment > ThicknessInfoMap
Definition: ThicknessSeparator.h:52
#define IPSDKBASESHAPESEGMENTATION_API
Import/Export macro for library IPSDKBaseShapeSegmentation.
Definition: IPSDKBaseShapeSegmentationExports.h:25
boost::shared_ptr< Shape2dPolygonWithHoles > Shape2dPolygonWithHolesPtr
shared pointer to polygon with holes associated to shape
Definition: Shape2dTypes.h:69