Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   Related Pages  

FGradientNormOp.hpp

00001 #ifndef __FGradientNormOp__
00002 #define __FGradientNormOp__
00003 
00004 
00005 
00026 #include <stdio.h>
00027 
00028 #include "AbsFImageFilter.hpp"
00029 
00030 
00031 
00032 class FGradientNormOp : public  AbsFImageFilter
00033 {
00034 protected:
00035 
00036 int                     w1,h1;
00037 FImage*         reference;
00038 
00039 public:
00040         
00041 FGradientNormOp(){reference=0; w1=h1=0;}
00042 virtual ~FGradientNormOp(){reference=0;}
00043 
00044 // point based computations
00045 // ------------------------
00046 virtual void setReference(FImage* im)
00047         { reference= im; w1=reference->getWidth()-1; h1= reference->getHeight()-1;}
00048 
00049 virtual float get(int x, int y);                        // if no side effects
00050 // borders
00051 virtual float getN(int x);
00052 virtual float getE(int y);
00053 virtual float getS(int x);
00054 virtual float getW(int y);
00055 // corners
00056 virtual float getNW();
00057 virtual float getNE();
00058 virtual float getSE();
00059 virtual float getSW();
00060 
00061 // single shot filtering
00062 virtual FImage* filter(FImage* src, FImage* dest=0);
00063 virtual FImage* selectedFilter(AnImage* mask, FImage* src, FImage* dest=0)
00064                 { return filter(src, dest); }
00065 
00066 virtual void report(FILE* file){ fprintf(file,"Central Gradient Norm\n"); }
00067 };
00068 
00069 
00070 #endif
SourceForge.net Logo
Restoreinpaint sourceforge project `C++/Java Image Processing, Restoration, Inpainting Project'.

Bernard De Cuyper: Open Project Leader: Concept, design and development.
Bernard De Cuyper & Eddy Fraiha 2002, 2003. Bernard De Cuyper 2004. Open and free, for friendly usage only.
Modifications on Belgium ground of this piece of artistic work, by governement institutions or companies, must be notified to Bernard De Cuyper.
bern_bdc@hotmail.com