vnl_gaussian_kernel_1d.h
Go to the documentation of this file.
1 // This is core/vnl/algo/vnl_gaussian_kernel_1d.h
2 #ifndef vnl_gaussian_kernel_1d_h_
3 #define vnl_gaussian_kernel_1d_h_
4 //:
5 // \file
6 // \brief Holds one half of a discretely sampled 1D gaussian distribution
7 // \author Andrew W. Fitzgibbon, Oxford RRG
8 // \date 07 Aug 97
9 //
10 // \verbatim
11 // Modifications
12 // 970807 AWF Initial version.
13 // dac (Manchester) 28/03/2001: tidied up documentation
14 // \endverbatim
15 
16 #include <vnl/vnl_vector.h>
17 #include <vnl/algo/vnl_algo_export.h>
18 
19 //: Holds one half of a discretely sampled 1D gaussian distribution
20 class VNL_ALGO_EXPORT vnl_gaussian_kernel_1d
21 {
22  public:
23  // Constructors/Destructors--------------------------------------------------
24  vnl_gaussian_kernel_1d(double sigma, double cutoff = 0.5/256.0);
25 
26  double G(double x) const;
27 
28  int width() const { return vec_.size(); }
29  double operator [] (int i) const { return vec_[i]; }
30 
31  protected:
32  // Data Members--------------------------------------------------------------
34  double inscale_;
35 };
36 
37 #endif // vnl_gaussian_kernel_1d_h_
Holds one half of a discretely sampled 1D gaussian distribution.
vnl_vector< double > vec_