#include <sdet_nonmax_suppression.h>
Public Member Functions | |
sdet_nonmax_suppression (sdet_nonmax_suppression_params &nsp, vbl_array_2d< double > &grad_x, vbl_array_2d< double > &grad_y) | |
Constructor from a parameter block, and gradients along x and y directions given as arrays. | |
sdet_nonmax_suppression (sdet_nonmax_suppression_params &nsp, vbl_array_2d< double > &dir_x, vbl_array_2d< double > &dir_y, vbl_array_2d< double > &grad_mag) | |
Constructor from a parameter block, gradient magnitudes given as an array and directions given as component arrays. | |
sdet_nonmax_suppression (sdet_nonmax_suppression_params &nsp, vbl_array_2d< double > &grad_mag, vbl_array_2d< vgl_vector_2d< double > > &directions) | |
Constructor from a parameter block, gradient magnitudes given as an array and the search directions. | |
sdet_nonmax_suppression (sdet_nonmax_suppression_params &nsp, vil_image_view< double > &grad_x, vil_image_view< double > &grad_y) | |
Constructor from a parameter block, and gradients along x and y directions given as images. | |
sdet_nonmax_suppression (sdet_nonmax_suppression_params &nsp, vil_image_view< double > &dir_x, vil_image_view< double > &dir_y, vil_image_view< double > &grad_mag) | |
Constructor from a parameter block, gradient magnitudes given as an image and directions given as component image. | |
sdet_nonmax_suppression (sdet_nonmax_suppression_params &nsp, vil_image_view< double > &grad_mag, vbl_array_2d< vgl_vector_2d< double > > &directions) | |
Constructor from a parameter block, gradient magnitudes given as an image and the search directions. | |
~sdet_nonmax_suppression () | |
Destructor. | |
vcl_vector< vsol_point_2d_sptr > & | get_points () |
vcl_vector< vsol_line_2d_sptr > & | get_lines () |
vcl_vector< vgl_vector_2d < double > > & | get_directions () |
void | apply () |
Apply the algorithm. | |
void | clear () |
Clear internal storage. | |
bool | SanityCheck () |
Checks that parameters are within acceptable bounds. | |
Public Attributes | |
double | thresh_ |
points with gradient magnitude below thresh_*maximum_gradient_magnitude/100 will not be processed. | |
int | pfit_type_ |
Protected Member Functions | |
int | intersected_face_number (double gx, double gy) |
double | intersection_parameter (double gx, double gy, int face_num) |
void | f_values (int x, int y, double gx, double gy, double s, int face_num, double *f) |
void | get_relative_corner_coordinates (int face_num, int *corners) |
double | subpixel_s (double *s, double *f) |
double | subpixel_s (int x, int y, vgl_vector_2d< double > direction) |
void | find_distance_s_and_f_for_point (int x, int y, vgl_homg_line_2d< double > line, double &d, double &s, vgl_vector_2d< double > direction) |
void | InitParams (double thresh, int pfit_type) |
Protected Attributes | |
bool | points_valid_ |
vcl_vector< vsol_point_2d_sptr > | points_ |
vcl_vector< vsol_line_2d_sptr > | lines_ |
vcl_vector< vgl_vector_2d < double > > | directions_ |
vbl_array_2d< double > | grad_x_ |
vbl_array_2d< double > | grad_y_ |
vbl_array_2d< double > | grad_mag_ |
int | width_ |
int | height_ |
double | max_grad_mag_ |
int | parabola_fit_type_ |
Friends | |
vcl_ostream & | operator<< (vcl_ostream &, const sdet_nonmax_suppression_params &dp) |
Definition at line 51 of file sdet_nonmax_suppression.h.
sdet_nonmax_suppression::sdet_nonmax_suppression | ( | sdet_nonmax_suppression_params & | nsp, |
vbl_array_2d< double > & | grad_x, | ||
vbl_array_2d< double > & | grad_y | ||
) |
Constructor from a parameter block, and gradients along x and y directions given as arrays.
Definition at line 22 of file sdet_nonmax_suppression.cxx.
sdet_nonmax_suppression::sdet_nonmax_suppression | ( | sdet_nonmax_suppression_params & | nsp, |
vbl_array_2d< double > & | dir_x, | ||
vbl_array_2d< double > & | dir_y, | ||
vbl_array_2d< double > & | grad_mag | ||
) |
Constructor from a parameter block, gradient magnitudes given as an array and directions given as component arrays.
Definition at line 51 of file sdet_nonmax_suppression.cxx.
sdet_nonmax_suppression::sdet_nonmax_suppression | ( | sdet_nonmax_suppression_params & | nsp, |
vbl_array_2d< double > & | grad_mag, | ||
vbl_array_2d< vgl_vector_2d< double > > & | directions | ||
) |
Constructor from a parameter block, gradient magnitudes given as an array and the search directions.
Definition at line 81 of file sdet_nonmax_suppression.cxx.
sdet_nonmax_suppression::sdet_nonmax_suppression | ( | sdet_nonmax_suppression_params & | nsp, |
vil_image_view< double > & | grad_x, | ||
vil_image_view< double > & | grad_y | ||
) |
Constructor from a parameter block, and gradients along x and y directions given as images.
Definition at line 111 of file sdet_nonmax_suppression.cxx.
sdet_nonmax_suppression::sdet_nonmax_suppression | ( | sdet_nonmax_suppression_params & | nsp, |
vil_image_view< double > & | dir_x, | ||
vil_image_view< double > & | dir_y, | ||
vil_image_view< double > & | grad_mag | ||
) |
Constructor from a parameter block, gradient magnitudes given as an image and directions given as component image.
Definition at line 142 of file sdet_nonmax_suppression.cxx.
sdet_nonmax_suppression::sdet_nonmax_suppression | ( | sdet_nonmax_suppression_params & | nsp, |
vil_image_view< double > & | grad_mag, | ||
vbl_array_2d< vgl_vector_2d< double > > & | directions | ||
) |
Constructor from a parameter block, gradient magnitudes given as an image and the search directions.
Definition at line 172 of file sdet_nonmax_suppression.cxx.
sdet_nonmax_suppression::~sdet_nonmax_suppression | ( | ) |
void sdet_nonmax_suppression::apply | ( | ) |
Apply the algorithm.
Definition at line 208 of file sdet_nonmax_suppression.cxx.
void sdet_nonmax_suppression::clear | ( | ) |
Clear internal storage.
Definition at line 463 of file sdet_nonmax_suppression.cxx.
void sdet_nonmax_suppression::f_values | ( | int | x, |
int | y, | ||
double | gx, | ||
double | gy, | ||
double | s, | ||
int | face_num, | ||
double * | f | ||
) | [protected] |
Definition at line 311 of file sdet_nonmax_suppression.cxx.
void sdet_nonmax_suppression::find_distance_s_and_f_for_point | ( | int | x, |
int | y, | ||
vgl_homg_line_2d< double > | line, | ||
double & | d, | ||
double & | s, | ||
vgl_vector_2d< double > | direction | ||
) | [protected] |
Definition at line 448 of file sdet_nonmax_suppression.cxx.
vcl_vector<vgl_vector_2d<double> >& sdet_nonmax_suppression::get_directions | ( | ) | [inline] |
Definition at line 85 of file sdet_nonmax_suppression.h.
vcl_vector<vsol_line_2d_sptr>& sdet_nonmax_suppression::get_lines | ( | ) | [inline] |
Definition at line 84 of file sdet_nonmax_suppression.h.
vcl_vector<vsol_point_2d_sptr>& sdet_nonmax_suppression::get_points | ( | ) | [inline] |
Definition at line 83 of file sdet_nonmax_suppression.h.
void sdet_nonmax_suppression::get_relative_corner_coordinates | ( | int | face_num, |
int * | corners | ||
) | [protected] |
Definition at line 342 of file sdet_nonmax_suppression.cxx.
void sdet_nonmax_suppression_params::InitParams | ( | double | thresh, |
int | pfit_type | ||
) | [protected, inherited] |
Definition at line 27 of file sdet_nonmax_suppression_params.cxx.
int sdet_nonmax_suppression::intersected_face_number | ( | double | gx, |
double | gy | ||
) | [protected] |
Definition at line 263 of file sdet_nonmax_suppression.cxx.
double sdet_nonmax_suppression::intersection_parameter | ( | double | gx, |
double | gy, | ||
int | face_num | ||
) | [protected] |
Definition at line 296 of file sdet_nonmax_suppression.cxx.
bool sdet_nonmax_suppression_params::SanityCheck | ( | ) | [inherited] |
Checks that parameters are within acceptable bounds.
Note that msg << ends seems to restart the string and erase the previous string. We should only use it as the last call, use vcl_endl otherwise.
Definition at line 39 of file sdet_nonmax_suppression_params.cxx.
double sdet_nonmax_suppression::subpixel_s | ( | double * | s, |
double * | f | ||
) | [protected] |
Definition at line 402 of file sdet_nonmax_suppression.cxx.
double sdet_nonmax_suppression::subpixel_s | ( | int | x, |
int | y, | ||
vgl_vector_2d< double > | direction | ||
) | [protected] |
Definition at line 411 of file sdet_nonmax_suppression.cxx.
vcl_ostream& operator<< | ( | vcl_ostream & | os, |
const sdet_nonmax_suppression_params & | dp | ||
) | [friend, inherited] |
Definition at line 55 of file sdet_nonmax_suppression_params.cxx.
vcl_vector<vgl_vector_2d<double> > sdet_nonmax_suppression::directions_ [protected] |
Definition at line 95 of file sdet_nonmax_suppression.h.
vbl_array_2d<double> sdet_nonmax_suppression::grad_mag_ [protected] |
Definition at line 98 of file sdet_nonmax_suppression.h.
vbl_array_2d<double> sdet_nonmax_suppression::grad_x_ [protected] |
Definition at line 96 of file sdet_nonmax_suppression.h.
vbl_array_2d<double> sdet_nonmax_suppression::grad_y_ [protected] |
Definition at line 97 of file sdet_nonmax_suppression.h.
int sdet_nonmax_suppression::height_ [protected] |
Definition at line 99 of file sdet_nonmax_suppression.h.
vcl_vector<vsol_line_2d_sptr> sdet_nonmax_suppression::lines_ [protected] |
Definition at line 94 of file sdet_nonmax_suppression.h.
double sdet_nonmax_suppression::max_grad_mag_ [protected] |
Definition at line 100 of file sdet_nonmax_suppression.h.
int sdet_nonmax_suppression::parabola_fit_type_ [protected] |
Definition at line 101 of file sdet_nonmax_suppression.h.
int sdet_nonmax_suppression_params::pfit_type_ [inherited] |
Definition at line 34 of file sdet_nonmax_suppression_params.h.
vcl_vector<vsol_point_2d_sptr> sdet_nonmax_suppression::points_ [protected] |
Definition at line 93 of file sdet_nonmax_suppression.h.
bool sdet_nonmax_suppression::points_valid_ [protected] |
Definition at line 92 of file sdet_nonmax_suppression.h.
double sdet_nonmax_suppression_params::thresh_ [inherited] |
points with gradient magnitude below thresh_*maximum_gradient_magnitude/100 will not be processed.
Definition at line 33 of file sdet_nonmax_suppression_params.h.
int sdet_nonmax_suppression::width_ [protected] |
Definition at line 99 of file sdet_nonmax_suppression.h.