00001 #ifndef __RRecursive2dBlurOp__ 00002 #define __RRecursive2dBlurOp__ 00003 00004 00037 #include <stdio.h> 00038 00039 #include "AbsRImageFilter.hpp" 00040 00041 class RRecursive2dBlurOp : public AbsRImageFilter 00042 { 00043 protected: 00044 00045 // basic filter parameters 00046 double sigma; 00047 00048 double scale; // normalisation factor 00049 00050 double a0; 00051 double a1; 00052 double b0; 00053 double w0; 00054 00055 double c0; 00056 double c1; 00057 double b1; 00058 double w1; 00059 00060 // causal filter parameters 00061 double n0p, n1p, n2p, n3p; 00062 double d1p, d2p, d3p, d4p; 00063 00064 // non-causal filter parameters 00065 double n1m, n2m, n3m, n4m; 00066 double d1m, d2m, d3m, d4m; 00067 00068 protected: 00069 00070 virtual void computeNormalisation(); 00071 00072 virtual void computeCausalFilter(); 00073 virtual void computeNonCausalFilter(); 00074 00075 public: 00076 00077 RRecursive2dBlurOp(double asigma=1.0); 00078 virtual ~RRecursive2dBlurOp(){} 00079 00080 // single shot filtering 00081 virtual RImage* filter(RImage* src, RImage* dest=0); 00082 virtual RImage* selectedFilter(AnImage* mask, RImage* src, RImage* dest=0); 00083 00084 virtual void report(FILE* file){ fprintf(file,"Real Recursive 2d Blur Operator\n"); } 00085 }; 00086 00087 00088 #endif