summaryrefslogtreecommitdiffhomepage
path: root/ftnoir_tracker_pt
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2015-10-25 16:18:29 +0100
committerStanislaw Halik <sthalik@misaki.pl>2015-10-25 16:18:29 +0100
commitb1f6b8d22bc2bb9129917bce9b1c0fb37a64b5bf (patch)
tree5c5316292716b6c991e35f5cca0785cf89c7f523 /ftnoir_tracker_pt
parentc8fa6d2099874e0f2c9bd72f9c6735ebf31ccbb1 (diff)
pt: drop nan check
Bug cause was different
Diffstat (limited to 'ftnoir_tracker_pt')
-rw-r--r--ftnoir_tracker_pt/ftnoir_tracker_pt.cpp30
1 files changed, 1 insertions, 29 deletions
diff --git a/ftnoir_tracker_pt/ftnoir_tracker_pt.cpp b/ftnoir_tracker_pt/ftnoir_tracker_pt.cpp
index 2db5006c..15a60962 100644
--- a/ftnoir_tracker_pt/ftnoir_tracker_pt.cpp
+++ b/ftnoir_tracker_pt/ftnoir_tracker_pt.cpp
@@ -67,11 +67,6 @@ bool Tracker_PT::get_focal_length(float& ret)
return false;
}
-static inline bool nanp(double value)
-{
- return std::isnan(value) || std::isinf(value);
-}
-
void Tracker_PT::run()
{
#ifdef PT_PERF_LOG
@@ -110,8 +105,6 @@ void Tracker_PT::run()
if (!get_focal_length(fx))
continue;
- Affine X_CM_ = pose();
-
if (success)
{
point_tracker.track(points, PointModel(s), fx, s.dynamic_pose, s.init_phase_timeout);
@@ -119,28 +112,7 @@ void Tracker_PT::run()
Affine X_CM = pose();
- {
- int j = 0;
-
- for (int i = 0; i < 3; i++)
- {
- if (nanp(X_CM.t(i)))
- goto nannan;
- for (; j < 3; j++)
- if (nanp(X_CM.R(i, j)))
- {
-nannan: success = false;
- X_CM = X_CM_;
- {
- QMutexLocker lock(&mutex);
- point_tracker.reset(X_CM_);
- }
- goto nannannan;
- }
- }
- }
-
-nannannan: ever_success |= success;
+ ever_success |= success;
{
Affine X_MH(cv::Matx33f::eye(), cv::Vec3f(s.t_MH_x, s.t_MH_y, s.t_MH_z)); // just copy pasted these lines from below