IPSDK  4_1_0_2
IPSDK : Image Processing Software Development Kit
Pruning2dImgLvl3.h
1 // Pruning2dImgLvl3.h:
3 // -------------------
4 //
14 
15 #ifndef __IPSDKIPLBASICMORPHOLOGY_PRUNING2DIMGLVL3_H__
16 #define __IPSDKIPLBASICMORPHOLOGY_PRUNING2DIMGLVL3_H__
17 
20 #include <IPSDKBaseData/Pattern/OffsetXY.h>
21 
22 // Attributes headers
23 #include <IPSDKIPL/IPSDKIPLAttributes/Attribute/DataItem/OutNbModifiedPixels.h>
24 #include <IPSDKIPL/IPSDKIPLAttributes/Attribute/Strip/YStrip2d/InOutBinYStrip2d.h>
25 #include <IPSDKIPL/IPSDKIPLAttributes/Attribute/Strip/YStrip2dWithKernel/InBinKnlYStrip2d.h>
26 #include <IPSDKIPL/IPSDKIPLAttributes/Attribute/Value/InRemoveSkeletonsWithoutHoles.h>
27 
28 namespace ipsdk {
29 namespace imaproc {
30 namespace morpho {
31 
34 
35 // declare processing algorithm
36 IPSDK_DECLARE_PROCESSING_ALGORITHM(IPSDKIPLBasicMorphology, Pruning2dImg,
37  ipsdk::imaproc::matchSizeAndType(_pInBinKnlYStrip2d, _pInOutBinYStrip2d),
38  (((ipsdk)(imaproc)(attr))(InBinKnlYStrip2d))
39  (((ipsdk)(imaproc)(attr))(InRemoveSkeletonsWithoutHoles))
40  (((ipsdk)(imaproc)(attr))(OutNbModifiedPixels))
41  (((ipsdk)(imaproc)(attr))(InOutBinYStrip2d)))
42 
43  // implementation of image processing data identifier retrieval method
44  // for function selector usage
46 
47  // declaration of parsed data during processing
48  IPSDK_DECLARE_ALGORITHM_PARSED_DATA(((LINESTRIP)(InBinKnlYStrip2d))
49  ((LINESTRIP)(InOutBinYStrip2d)));
50 
51 // methods
52 public:
53 
54 protected:
58 
61  void fillStructuringElements();
62 
64  template <ipsdk::eInstructionSet::domain IS>
65  ipsdk::BoolResult genericProcessFunction(const ipsdk::processor::ProcessingInfo& info);
66 
67 // attributes
68 protected:
70  typedef std::vector<OffsetXY> OffsetColl;
71 
73  typedef std::vector<OffsetColl> StructuringElementColl;
74 
76  StructuringElementColl _seColl_fg;
78 
81  StructuringElementColl _seExceptColl_fg;
82  StructuringElementColl _seExceptColl_bg;
83 
85  typedef boost::scoped_array<const void*> BufColl;
86 
88  BufColl _pBufColl_fg[9];
89  BufColl _pBufColl_bg[9];
90  BufColl _pBufColl_except_fg[4];
91  BufColl _pBufColl_except_bg[4];
92 
93 };
94 
97 
98 } // end of namespace morpho
99 } // end of namespace imaproc
100 } // end of namespace ipsdk
101 
102 #endif // __IPSDKIPLBASICMORPHOLOGY_PRUNING2DIMGLVL3_H__
boost::scoped_array< const void * > BufColl
collection of buffer pointers
Definition: Pruning2dImgLvl3.h:204
ipsdk::core::ExecResult preProcess()
method called before processing
Definition of import/export macro for library.
#define IPSDK_DECLARE_PROCESSING_ALGORITHM(libraryName, algoName, RuleString, attributeSeq)
#define IPSDK_DECLARE_ALGORITHM_PARSED_DATA(dataSeq)
std::vector< OffsetColl > StructuringElementColl
collection of structuring elements
Definition: Pruning2dImgLvl3.h:192
#define IPSDK_DECLARE_NOTYPE_ALGORITHM_FUNCTION_SELECTOR()