IPSDK  4_1_0_2
IPSDK : Image Processing Software Development Kit
GreyReconstruction2dImgLvl3.h
1 // GreyReconstruction2dImgLvl3.h:
3 // ------------------------------
4 //
14 
15 #ifndef __IPSDKIPLADVANCEDMORPHOLOGY_GREYRECONSTRUCTION2DIMGLVL3_H__
16 #define __IPSDKIPLADVANCEDMORPHOLOGY_GREYRECONSTRUCTION2DIMGLVL3_H__
17 
20 
21 // Attributes headers
22 #include <IPSDKIPL/IPSDKIPLAttributes/Attribute/Strip/YStrip2d/InYStrip2d.h>
23 #include <IPSDKIPL/IPSDKIPLAttributes/Attribute/Strip/YStrip2d/InOptPreviousYStrip2d.h>
24 #include <IPSDKIPL/IPSDKIPLAttributes/Attribute/Enumerate/InLocalExtremumType.h>
25 #include <IPSDKIPL/IPSDKIPLAttributes/Attribute/DataItem/OutNbModifiedPixels.h>
26 #include <IPSDKIPL/IPSDKIPLAttributes/Attribute/Strip/YStrip2d/InOutYStrip2d.h>
27 
28 namespace ipsdk {
29 namespace imaproc {
30 namespace advmorpho {
31 
34 
35 // declare processing algorithm
36 IPSDK_DECLARE_PROCESSING_ALGORITHM(IPSDKIPLAdvancedMorphology, GreyReconstruction2dImg,
37  (ipsdk::imaproc::matchSizeAndType(_pInYStrip2d, _pInOutYStrip2d)),
38  (((ipsdk)(imaproc)(attr))(InYStrip2d))
39  (((ipsdk)(imaproc)(attr))(InOptPreviousYStrip2d))
40  (((ipsdk)(imaproc)(attr))(InLocalExtremumType))
41  (((ipsdk)(imaproc)(attr))(OutNbModifiedPixels))
42  (((ipsdk)(imaproc)(attr))(InOutYStrip2d)))
43 
44  // implementation of image processing data identifier retrieval method
45  // for function selector usage
46  IPSDK_DECLARE_ALGORITHM_FUNCTION_SELECTOR(((STRIP)(InYStrip2d)));
47 
48  // declaration of parsed data during processing
49  IPSDK_DECLARE_ALGORITHM_PARSED_DATA(((LINESTRIP)(InYStrip2d))
50  ((LINESTRIP)(InOutYStrip2d)));
51 
52 // methods
53 public:
54 
55 protected:
57  template <typename BufType,
58  ipsdk::eInstructionSet::domain IS>
59  ipsdk::BoolResult genericProcessFunction(const ipsdk::processor::ProcessingInfo& info);
60 
63  template <typename BufType,
64  typename Operator,
65  ipsdk::eInstructionSet::domain IS>
66  void specificProcessFunction(const ipsdk::processor::ProcessingInfo& info);
67 
69  template <typename BufType,
70  typename Operator,
71  ipsdk::eInstructionSet::domain IS>
72  void initPreviousData();
73 
75  template <typename BufType,
76  typename Operator,
77  ipsdk::eInstructionSet::domain IS>
78  void updatePreviousRowData();
79 
81  void clearIntermediateData();
82 
83 // attributes
84 protected:
86  ipUInt64 _alignedRowNbData;
87 
89  ipUInt64 _sizeX;
90 
92  boost::scoped_array<ipUInt8> _pPrevRowGreyBuf;
93 
95  boost::scoped_array<ipUInt8> _pCurRowGreyBuf;
96 
98  ipReal64 _usedBorderValue;
99 };
100 
103 
104 } // end of namespace advmorpho
105 } // end of namespace imaproc
106 } // end of namespace ipsdk
107 
108 #endif // __IPSDKIPLADVANCEDMORPHOLOGY_GREYRECONSTRUCTION2DIMGLVL3_H__
Definition of import/export macro for library.
uint64_t ipUInt64
double ipReal64
#define IPSDK_DECLARE_PROCESSING_ALGORITHM(libraryName, algoName, RuleString, attributeSeq)
#define IPSDK_DECLARE_ALGORITHM_PARSED_DATA(dataSeq)
#define IPSDK_DECLARE_ALGORITHM_FUNCTION_SELECTOR(dataTypeSeq)