00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011 #ifndef HxNftNormCorrelation_h
00012 #define HxNftNormCorrelation_h
00013
00014 #include "HxNeighbFunctorTem.h"
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025 template <class ArgType, class ResType>
00026 class HxNftNormCorrelation : public HxNeighbFunctorTem<ArgType,ResType>
00027 {
00028 public:
00029 HxNftNormCorrelation();
00030 virtual ~HxNftNormCorrelation();
00031
00032 virtual void init();
00033 virtual void next(ArgType pixV, ArgType maskV, HxPoint p);
00034 virtual ResType result();
00035
00036 virtual int hasPhase2();
00037
00038 virtual void init2();
00039 virtual void next2(ArgType pixV, ArgType maskV, HxPoint p);
00040 virtual ResType result2();
00041
00042 private:
00043 HxScalarInt _num;
00044 ResType _fBar;
00045 ResType _wBar;
00046 ResType _sumFW;
00047 ResType _sumFSqr;
00048 ResType _sumWSqr;
00049 };
00050
00051 #ifdef INC_TEMPLATE_SRC
00052 #include "HxNftNormCorrelation.c"
00053 #endif
00054
00055 #endif