source: trunk/saliency_detection/include/saliency_detection/cvgabor.h @ 10

Last change on this file since 10 was 10, checked in by wcaarls, 12 years ago

Imported saliency_detection at revision 1000

File size: 2.7 KB
Line 
1/***************************************************************************
2 *   Copyright (C) 2006 by Mian Zhou   *
3 *   M.Zhou@reading.ac.uk   *
4 *                                                                         *
5 *   This program is free software; you can redistribute it and/or modify  *
6 *   it under the terms of the GNU General Public License as published by  *
7 *   the Free Software Foundation; either version 2 of the License, or     *
8 *   (at your option) any later version.                                   *
9 *                                                                         *
10 *   This program is distributed in the hope that it will be useful,       *
11 *   but WITHOUT ANY WARRANTY; without even the implied warranty of        *
12 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         *
13 *   GNU General Public License for more details.                          *
14 *                                                                         *
15 *   You should have received a copy of the GNU General Public License     *
16 *   along with this program; if not, write to the                         *
17 *   Free Software Foundation, Inc.,                                       *
18 *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.             *
19 ***************************************************************************/
20#ifndef CVGABOR_H
21#define CVGABOR_H
22
23#include <iostream>
24
25
26#include <cv.h>
27#include <highgui.h>
28using namespace std;
29
30#define PI 3.14159265
31#define FALSE 0
32#define TRUE 1
33#define CV_GABOR_REAL 1
34#define CV_GABOR_IMAG 2
35#define CV_GABOR_MAG  3
36#define CV_GABOR_PHASE 4
37
38/**
39@author Mian Zhou
40*/
41class CvGabor{
42public:
43    CvGabor();
44
45    ~CvGabor();
46
47     CvGabor(int iMu, int iNu);
48     CvGabor(int iMu, int iNu, float dSigma);
49     CvGabor(int iMu, int iNu, float dSigma, float dF);
50     CvGabor(float dPhi, int iNu);
51     CvGabor(float dPhi, int iNu, float dSigma);
52     CvGabor(float dPhi, int iNu, float dSigma, float dF);
53    bool IsInit();
54    long mask_width();
55    IplImage* get_image(int Type);
56    bool IsKernelCreate();
57    long get_mask_width();
58    void Init(int iMu, int iNu, double dSigma, double dF);
59    void Init(double dPhi, int iNu, double dSigma, double dF);
60    void output_file(const char *filename, int Type);
61    CvMat* get_matrix(int Type);
62    void show(int Type);
63    void conv_img(IplImage *src, IplImage *dst, int Type);
64
65protected:
66    float Sigma;
67    float F;
68    float Kmax;
69    float K;
70    float Phi;
71    bool bInitialised;
72    bool bKernel;
73    long Width;
74    CvMat *Imag;
75    CvMat *Real;
76private:
77    void creat_kernel();
78
79};
80
81#endif
Note: See TracBrowser for help on using the repository browser.