47 #ifndef vpHomography_hh 48 #define vpHomography_hh 53 #include <visp3/core/vpCameraParameters.h> 54 #include <visp3/core/vpHomogeneousMatrix.h> 55 #include <visp3/core/vpImagePoint.h> 56 #include <visp3/core/vpMatrix.h> 57 #include <visp3/core/vpPlane.h> 58 #include <visp3/core/vpPoint.h> 177 static const double sing_threshold;
178 static const double threshold_rotation;
179 static const double threshold_displacement;
198 void insert(
const vpPlane &bP);
200 static void initRansac(
unsigned int n,
double *xb,
double *yb,
double *xa,
double *ya,
vpColVector &x);
237 void load(std::ifstream &f);
260 void resize(
const unsigned int nrows,
const unsigned int ncols,
const bool flagNullify =
true)
268 void save(std::ofstream &f)
const;
270 static void DLT(
const std::vector<double> &xb,
const std::vector<double> &yb,
const std::vector<double> &xa,
271 const std::vector<double> &ya,
vpHomography &aHb,
bool normalization =
true);
273 static void HLM(
const std::vector<double> &xb,
const std::vector<double> &yb,
const std::vector<double> &xa,
274 const std::vector<double> &ya,
bool isplanar,
vpHomography &aHb);
276 static bool ransac(
const std::vector<double> &xb,
const std::vector<double> &yb,
const std::vector<double> &xa,
277 const std::vector<double> &ya,
vpHomography &aHb, std::vector<bool> &inliers,
double &residual,
278 unsigned int nbInliersConsensus,
double threshold,
bool normalization =
true);
283 static void robust(
const std::vector<double> &xb,
const std::vector<double> &yb,
const std::vector<double> &xa,
284 const std::vector<double> &ya,
vpHomography &aHb, std::vector<bool> &inlier,
double &residual,
285 double weights_threshold = 0.4,
unsigned int niter = 4,
bool normalization =
true);
287 #ifndef DOXYGEN_SHOULD_SKIP_THIS 297 static void computeDisplacement(
const vpHomography &H,
const double x,
const double y,
298 std::list<vpRotationMatrix> &vR, std::list<vpTranslationVector> &vT,
299 std::list<vpColVector> &vN);
309 static bool degenerateConfiguration(
vpColVector &x,
unsigned int *ind);
310 static bool degenerateConfiguration(
vpColVector &x,
unsigned int *ind,
double threshold_area);
311 static bool degenerateConfiguration(
const std::vector<double> &xb,
const std::vector<double> &yb,
312 const std::vector<double> &xa,
const std::vector<double> &ya);
313 static void HartleyNormalization(
unsigned int n,
const double *x,
const double *y,
double *xn,
double *yn,
double &xg,
314 double &yg,
double &coef);
315 static void HartleyNormalization(
const std::vector<double> &x,
const std::vector<double> &y, std::vector<double> &xn,
316 std::vector<double> &yn,
double &xg,
double &yg,
double &coef);
318 double xg2,
double yg2,
double coef2);
320 #endif // DOXYGEN_SHOULD_SKIP_THIS 322 #if defined(VISP_BUILD_DEPRECATED_FUNCTIONS) Implementation of a matrix and operations on matrices.
static bool save(const std::string &filename, const vpArray2D< Type > &A, const bool binary=false, const char *header="")
vpArray2D< Type > & operator=(Type x)
Set all the elements of the array to x.
Implementation of an homogeneous matrix and operations on such kind of matrices.
error that can be emited by ViSP classes.
Implementation of a generic 2D array used as vase class of matrices and vectors.
Class that defines what is a point.
Implementation of a rotation matrix and operations on such kind of matrices.
vpColVector operator*(const double &x, const vpColVector &v)
Implementation of an homography and operations on homographies.
static bool load(const std::string &filename, vpArray2D< Type > &A, const bool binary=false, char *header=NULL)
Generic class defining intrinsic camera parameters.
Implementation of column vector and the associated operations.
Implementation of a pose vector and operations on poses.
Class that defines a 2D point in an image. This class is useful for image processing and stores only ...
void resize(const unsigned int nrows, const unsigned int ncols, const bool flagNullify=true)
This class defines the container for a plane geometrical structure.
Class that consider the case of a translation vector.
Implementation of a rotation vector as axis-angle minimal representation.