IPSDK  4_1_0_2
IPSDK : Image Processing Software Development Kit
Convolution2dImgLvl3.h
1 // Convolution2dImgLvl3.h:
3 // --------------------
4 //
14 
15 #ifndef __IPSDKIPLFILTERING_CONVOLUTION2DIMGLVL3_H__
16 #define __IPSDKIPLFILTERING_CONVOLUTION2DIMGLVL3_H__
17 
20 #include <IPSDKBaseData/Pattern/OffsetXY.h>
21 #include <vector>
22 #include <boost/scoped_array.hpp>
23 
24 // Attributes headers
25 #include <IPSDKIPL/IPSDKIPLAttributes/Attribute/Strip/YStrip2dWithKernel/InKnlYStrip2d.h>
26 #include <IPSDKIPL/IPSDKIPLAttributes/Attribute/Kernel/InKnlXY.h>
27 #include <IPSDKIPL/IPSDKIPLAttributes/Attribute/Value/InNormalize.h>
28 #include <IPSDKIPL/IPSDKIPLAttributes/Attribute/BorderPolicy/InConvolBorder2d.h>
29 #include <IPSDKIPL/IPSDKIPLAttributes/Attribute/Strip/YStrip2d/OutYStrip2d.h>
30 
31 namespace ipsdk {
32 namespace imaproc {
33 namespace filter {
34 
37 
38 // declare processing algorithm
39 IPSDK_DECLARE_PROCESSING_ALGORITHM(IPSDKIPLFiltering, Convolution2dImg,
40  ipsdk::imaproc::matchSize(_pInKnlYStrip2d, _pOutYStrip2d),
41  (((ipsdk)(imaproc)(attr))(InKnlYStrip2d))
42  (((ipsdk)(imaproc)(attr))(InKnlXY))
43  (((ipsdk)(imaproc)(attr))(InNormalize))
44  (((ipsdk)(imaproc)(attr))(InConvolBorder2d))
45  (((ipsdk)(imaproc)(attr))(OutYStrip2d)))
46 
47  // implementation of image processing data identifier retrieval method
48  // for function selector usage
49  IPSDK_DECLARE_ALGORITHM_FUNCTION_SELECTOR(((STRIP)(InKnlYStrip2d))
50  ((STRIP)(OutYStrip2d)));
51 
52  // declaration of parsed data during processing
53  IPSDK_DECLARE_ALGORITHM_PARSED_DATA(((LINESTRIP)(InKnlYStrip2d))
54  ((LINESTRIP)(OutYStrip2d)));
55 
56 // methods
57 public:
58 
59 protected:
63 
65  template <typename BufInType, typename BufOutType,
66  ipsdk::eInstructionSet::domain ISFma, ipsdk::eInstructionSet::domain IS>
67  ipsdk::BoolResult genericProcessFunction(const ipsdk::processor::ProcessingInfo& info);
68 
70  void clearIntermediateData();
71 
72 // attributes
73 protected:
75  typedef std::vector<OffsetXY> OffsetColl;
76 
78  OffsetColl _offsetColl;
79 
81  typedef std::vector<ipReal32> CoefColl;
82 
84  CoefColl _coefColl;
85 
87  typedef boost::scoped_array<const void*> BufColl;
88 
90  BufColl _pBufColl;
91 };
92 
95 
96 } // end of namespace filter
97 } // end of namespace imaproc
98 } // end of namespace ipsdk
99 
100 #endif // __IPSDKIPLFILTERING_CONVOLUTION2DIMGLVL3_H__
ipsdk::core::ExecResult preProcess()
method called before processing
#define IPSDK_DECLARE_PROCESSING_ALGORITHM(libraryName, algoName, RuleString, attributeSeq)
#define IPSDK_DECLARE_ALGORITHM_PARSED_DATA(dataSeq)
#define IPSDK_DECLARE_ALGORITHM_FUNCTION_SELECTOR(dataTypeSeq)
IPSDK_DECLARE_GPU_PROCESSING_ALGORITHM(IPSDKIPLFiltering, Convolution2dImg, ipsdk::imaproc::matchSize(_pInSubGpuImg, _pOutImg),(((ipsdk)(imaproc)(attr))(InSubGpuImg))(((ipsdk)(imaproc)(attr))(InKnlXY))(((ipsdk)(imaproc)(attr))(InNormalize))(((ipsdk)(imaproc)(attr))(InConvolBorder2d))(((ipsdk)(imaproc)(attr))(OutImg))) IPSDKCUDA_DECLARE_ALGORITHM_FUNCTION_SELECTOR((InSubGpuImg)(OutImg)) public void clearIntermediateData()
method called before processing
Definition of import/export macro for library.