vpgl_fm_compute_8_point.h
Go to the documentation of this file.
1 // This is core/vpgl/algo/vpgl_fm_compute_8_point.h
2 #ifndef vpgl_fm_compute_8_point_h_
3 #define vpgl_fm_compute_8_point_h_
4 //:
5 // \file
6 // \brief The 8 point algorithm for computing a fundamental matrix from point correspondences.
7 // \author Thomas Pollard
8 // \date May 10, 2005
9 //
10 // The point correspondences in relation to F are defined by
11 // $pl^t[F]pr = 0$
12 //
13 // \verbatim
14 // Modifications
15 // Sep 27, 2007 Ricardo Fabbri Imposed order of 1) rank-enforcement and 2) de-normalization.
16 // \endverbatim
17 
18 #include <vgl/vgl_homg_point_2d.h>
20 
22 {
23  public:
24  //: If precondition = true, points are conditioned prior to computation.
25  vpgl_fm_compute_8_point( bool precondition = true ) :
26  precondition_(precondition) {}
27 
28  //: Compute from two sets of corresponding points.
29  // Put the resulting matrix into fm, return true if successful.
30  // Points pr are associated with the RHS of the fundamental matrix
31  // while the points pl are associated with the LHS.
32  bool compute( const std::vector< vgl_homg_point_2d<double> >& pr,
33  const std::vector< vgl_homg_point_2d<double> >& pl,
35 
36  protected:
38 };
39 
40 #endif // vpgl_fm_compute_8_point_h_
A class for the fundamental matrix between two projective cameras.
bool compute(const std::vector< vgl_homg_point_2d< double > > &pr, const std::vector< vgl_homg_point_2d< double > > &pl, vpgl_fundamental_matrix< double > &fm)
Compute from two sets of corresponding points.
vpgl_fm_compute_8_point(bool precondition=true)
If precondition = true, points are conditioned prior to computation.