Fix a bug in two point ransac; Close issue #15
This commit is contained in:
parent
610728c8c4
commit
f2c3178314
@ -1109,8 +1109,9 @@ void ImageProcessor::twoPointRansac(
|
||||
0, raw_inlier_idx.size()-1)];
|
||||
int idx_diff = random_gen.uniformInteger(
|
||||
1, raw_inlier_idx.size()-1);
|
||||
int pair_idx2 = pair_idx1+idx_diff < raw_inlier_idx.size() ?
|
||||
pair_idx1+idx_diff : pair_idx1+idx_diff-raw_inlier_idx.size();
|
||||
int pair_idx2 = raw_inlier_idx[
|
||||
pair_idx1+idx_diff < raw_inlier_idx.size() ?
|
||||
pair_idx1+idx_diff : pair_idx1+idx_diff-raw_inlier_idx.size()];
|
||||
|
||||
// Construct the model;
|
||||
Vector2d coeff_tx(coeff_t(pair_idx1, 0), coeff_t(pair_idx2, 0));
|
||||
|
Loading…
Reference in New Issue
Block a user