diff options
Diffstat (limited to 'tracker-pt/point_tracker.h')
| -rw-r--r-- | tracker-pt/point_tracker.h | 10 | 
1 files changed, 3 insertions, 7 deletions
| diff --git a/tracker-pt/point_tracker.h b/tracker-pt/point_tracker.h index 8c754718..48c7617e 100644 --- a/tracker-pt/point_tracker.h +++ b/tracker-pt/point_tracker.h @@ -15,9 +15,8 @@  #include "ftnoir_tracker_pt_settings.h"  #include <QObject> +#include <QMutex> -// ---------------------------------------------------------------------------- -// Affine frame trafo  class Affine  {  public: @@ -120,12 +119,8 @@ public:      // f : (focal length)/(sensor width)      // dt : time since last call      void track(const std::vector<cv::Vec2f>& projected_points, const PointModel& model, float f, bool dynamic_pose, int init_phase_timeout); -    Affine pose() const { return X_CM; } +    Affine pose() { QMutexLocker l(&mtx); return X_CM; }      cv::Vec2f project(const cv::Vec3f& v_M, float f); -    void reset(const Affine& pose) -    { -        X_CM = pose; -    }  private:      // the points in model order      struct PointOrder @@ -146,6 +141,7 @@ private:      Timer t;      bool init_phase; +    QMutex mtx;  };  #endif //POINTTRACKER_H | 
