IPSDK  4_1_0_2
IPSDK : Image Processing Software Development Kit
HistogramMsr3dLvl2.h
1 // HistogramMsr3dLvl2.h:
3 // ---------------------
4 //
14 
15 #ifndef __IPSDKIPLGLOBALMEASURE_HISTOGRAMMSR3DLVL2_H__
16 #define __IPSDKIPLGLOBALMEASURE_HISTOGRAMMSR3DLVL2_H__
17 
20 
21 // Attributes headers
22 #include <IPSDKIPL/IPSDKIPLAttributes/Attribute/DataItem/InOptHistoMsrParams.h>
23 #include <IPSDKIPL/IPSDKIPLAttributes/Attribute/DataItem/OutHistogram.h>
24 #include <IPSDKIPL/IPSDKIPLAttributes/Attribute/SubImage/Input/3d/InSubImg3d.h>
25 
26 namespace ipsdk {
27 namespace imaproc {
28 namespace glbmsr {
29 
30 class StatsMsr3dLvl2;
31 
34 
35 // declare processor class
36 IPSDK_DECLARE_LVL2_PROCESSOR(ASYNC2, IPSDKIPLGlobalMeasure, HistogramMsr3d,
37  (ipsdk::processor::ifIsSet(_pInOptHistoMsrParams,
38  ipsdk::imaproc::matchImageRange<ipsdk::imaproc::attr::HistoMsrParams::Min>(_pInSubImg3d, _pInOptHistoMsrParams) &&
39  ipsdk::imaproc::matchImageRange<ipsdk::imaproc::attr::HistoMsrParams::Max>(_pInSubImg3d, _pInOptHistoMsrParams) &&
40  ipsdk::processor::isGreater<ipsdk::imaproc::attr::HistoMsrParams::BinWidth>(_pInOptHistoMsrParams, 0))),
41  (((ipsdk)(imaproc)(attr))(InSubImg3d))
42  (((ipsdk)(imaproc)(attr))(InOptHistoMsrParams))
43  (((ipsdk)(imaproc)(attr))(OutHistogram)))
44 
45 // methods
46 public:
47 
48 protected:
50  processor::RetrievalResult retrieveLastProvider(const core::BasePriority& priority,
51  core::ActionProviderPtr& pProvider);
52 
55  core::ExecResult postProcess();
56 
59  ipUInt32 getHistoNbClasses(ipReal64 fMin, ipReal64 fMax, ipReal64 fBinWidth) const;
60 
62  void clearIntermediateData();
63 
64 // attributes
65 protected:
66  // declaration of dispatch results collection
67  IPSDK_DECLARE_DYNAMIC_RESULT_COLL(OutHistogram, OutHistogramColl);
68 
70  boost::shared_ptr<glbmsr::StatsMsr3dLvl2> _pStatsMsr3dLvl2;
71 
72 };
73 
76 
77 } // end of namespace glbmsr
78 } // end of namespace imaproc
79 } // end of namespace ipsdk
80 
81 #endif // __IPSDKIPLGLOBALMEASURE_HISTOGRAMMSR3DLVL2_H__
ProcessingResult< eRetrievalResultType > RetrievalResult
#define IPSDK_DECLARE_LVL2_PROCESSOR(ProcType, libraryName, algoName, RuleString, attributeSeq)
double ipReal64
boost::enable_if_c< AttributeType::g_bOptional, RulePtr >::type ifIsSet(const boost::shared_ptr< AttributeType > &pAttribute, const RulePtr &pRuleTrue)
ProcessingResult< eExecutionResult > ExecResult
boost::shared_ptr< BaseActionProvider > ActionProviderPtr
Definition of import/export macro for library.
#define IPSDK_DECLARE_DYNAMIC_RESULT_COLL(AttributeType, CollType)
uint32_t ipUInt32