From 5fd06c5d0a28a861e02f000d95cf82d987465041 Mon Sep 17 00:00:00 2001 From: Patrick Ruoff Date: Sat, 12 Jan 2013 14:07:45 +0000 Subject: PointTracker: Tracker state is reported to FTNoIR, Camera pitch correction, Dynamic pose resolution made optional git-svn-id: svn+ssh://svn.code.sf.net/p/facetracknoir/code@207 19e81ba0-9b1a-49c3-bd6c-561e1906d5fb --- FTNoIR_Tracker_PT/point_tracker.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'FTNoIR_Tracker_PT/point_tracker.cpp') diff --git a/FTNoIR_Tracker_PT/point_tracker.cpp b/FTNoIR_Tracker_PT/point_tracker.cpp index 03914bb4..d617de19 100644 --- a/FTNoIR_Tracker_PT/point_tracker.cpp +++ b/FTNoIR_Tracker_PT/point_tracker.cpp @@ -87,7 +87,7 @@ void PointModel::get_d_order(const std::vector& points, int d_order[] // ---------------------------------------------------------------------------- -PointTracker::PointTracker() : init_phase(true), dt_valid(0), dt_reset(1), v_t(0,0,0), v_r(0,0,0) +PointTracker::PointTracker() : init_phase(true), dt_valid(0), dt_reset(1), v_t(0,0,0), v_r(0,0,0), dynamic_pose_resolution(true) { X_CM.t[2] = 1000; // default position: 1 m away from cam; } @@ -109,6 +109,8 @@ void PointTracker::reset_velocities() bool PointTracker::track(const vector& points, float f, float dt) { + if (!dynamic_pose_resolution) init_phase = true; + dt_valid += dt; // if there was no valid tracking result for too long, do a reset if (dt_valid > dt_reset) -- cgit v1.2.3