00001 #ifndef __ShockProximityFlow__ 00002 #define __ShockProximityFlow__ 00003 00025 #include <stdio.h> 00026 00027 00028 #include "RImage.hpp" 00029 00030 #include "AbsRImageFlow.hpp" 00031 00032 class ShockProximityFlow : public AbsRImageFlow 00033 { 00034 protected: 00035 00036 double limitDistance2; // balance shock / diffusion 00037 RImage* distanceMapEdges; 00038 00039 double lambda; 00040 00041 public: 00042 00043 ShockProximityFlow(RImage* distanceMap=0, double dlimit=5.0, double lambdaD=1.0) 00044 {distanceMapEdges= distanceMap; limitDistance2= dlimit*dlimit; lambda= lambdaD;} 00045 virtual ~ShockProximityFlow(){} 00046 00047 virtual double flow(RImage& image, int x, int y); 00048 virtual double flow(RImage& image0, RImage& imSmooth, int x, int y); 00049 00050 virtual void setEdgeDistance(RImage* distanceMap){ distanceMapEdges= distanceMap; } 00051 00052 virtual void report(FILE* file){} 00053 }; 00054 00055 00056 #endif