Hugin trunk 0.1
Loading...
Searching...
No Matches
GaborFilter.h
Go to the documentation of this file.
1/* Import from Gabor API
2
3Copyright (c) 2002-3 Adriaan Tijsseling
4
5
6 All Rights Reserved
7
8 This program is free software; you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation; either version 2 of the License, or
11 (at your option) any later version.
12
13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details.
17
18 You should have received a copy of the GNU General Public License
19 along with this program. If not, see <http://www.gnu.org/licenses/>.
20*/
21
22/*
23 Description: Class definition for a single Gabor Filter
24 Author: Adriaan Tijsseling (AGT)
25 Copyright: (c) Copyright 2002-3 Adriaan Tijsseling. All rights reserved.
26*/
27
28
29#ifndef __GABORFILTER__
30#define __GABORFILTER__
31
32#include "GaborGlobal.h"
33#include "PGMImage.h"
34
35namespace celeste
36{
38{
39public:
40
43
44 void Initialize( int radius, float a, float f, float s, float p = 0 );
45 void Save( char* file, int angle, int freq );
46
47 inline float GetReal( int x, int y ) { return mReal[x][y]; }
48 inline float GetImaginary( int x, int y ) { return mImaginary[x][y]; }
49
50protected:
51
52 int mXYO; // origin
53 int mRadius; // radius of filter
54 float mSigma; // curve of gaussian (sually set to PI)
55 float mAngle; // orientation of filter (theta)
56 float mPhase; // phase of filter (rho)
57 float mFrequency; // wavelengths of filter (omega)
58 float** mReal; // real part of filter
59 float** mImaginary; // imaginary part of filter
60};
61} //namespace
62#endif
void Initialize(int radius, float a, float f, float s, float p=0)
float GetImaginary(int x, int y)
Definition GaborFilter.h:48
void Save(char *file, int angle, int freq)
float GetReal(int x, int y)
Definition GaborFilter.h:47