4
* @brief Main program for detecting and computing descriptors in a nonlinear
7
* @author Pablo F. Alcantarilla
10
#ifndef __OPENCV_FEATURES_2D_KAZE_FEATURES_H__
11
#define __OPENCV_FEATURES_2D_KAZE_FEATURES_H__
13
/* ************************************************************************* */
15
#include "KAZEConfig.h"
16
#include "nldiffusion_functions.h"
18
#include "TEvolution.h"
23
/* ************************************************************************* */
24
// KAZE Class Declaration
29
/// Parameters of the Nonlinear diffusion class
30
KAZEOptions options_; ///< Configuration options for KAZE
31
std::vector<TEvolution> evolution_; ///< Vector of nonlinear diffusion evolution
33
/// Vector of keypoint vectors for finding extrema in multiple threads
34
std::vector<std::vector<cv::KeyPoint> > kpts_par_;
37
int ncycles_; ///< Number of cycles
38
bool reordering_; ///< Flag for reordering time steps
39
std::vector<std::vector<float > > tsteps_; ///< Vector of FED dynamic time steps
40
std::vector<int> nsteps_; ///< Vector of number of steps per cycle
45
KAZEFeatures(KAZEOptions& options);
47
/// Public methods for KAZE interface
48
void Allocate_Memory_Evolution(void);
49
int Create_Nonlinear_Scale_Space(const cv::Mat& img);
50
void Feature_Detection(std::vector<cv::KeyPoint>& kpts);
51
void Feature_Description(std::vector<cv::KeyPoint>& kpts, cv::Mat& desc);
52
static void Compute_Main_Orientation(cv::KeyPoint& kpt, const std::vector<TEvolution>& evolution_, const KAZEOptions& options);
54
/// Feature Detection Methods
55
void Compute_KContrast(const cv::Mat& img, const float& kper);
56
void Compute_Multiscale_Derivatives(void);
57
void Compute_Detector_Response(void);
58
void Determinant_Hessian(std::vector<cv::KeyPoint>& kpts);
59
void Do_Subpixel_Refinement(std::vector<cv::KeyPoint>& kpts);