diff options
Diffstat (limited to 'logic/tracker.cpp')
-rw-r--r-- | logic/tracker.cpp | 21 |
1 files changed, 3 insertions, 18 deletions
diff --git a/logic/tracker.cpp b/logic/tracker.cpp index 1132affe..08d88c38 100644 --- a/logic/tracker.cpp +++ b/logic/tracker.cpp @@ -52,18 +52,6 @@ Tracker::~Tracker() wait(); } -Tracker::rmat Tracker::camera_offset(double c) -{ - const double off[] = - { - d2r * c * (double)-s.camera_yaw, - d2r * c * (double)-s.camera_pitch, - d2r * c * (double)-s.camera_roll - }; - - return euler::euler_to_rmat(off); -} - double Tracker::map(double pos, Map& axis) { bool altp = (pos < 0) && axis.opts.altp; @@ -182,9 +170,6 @@ void Tracker::logic() real_rotation.rotation = euler_to_rmat(tmp); } - scaled_rotation.camera = camera_offset(c_div); - real_rotation.camera = camera_offset(1); - nanp |= is_nan(value) || is_nan(scaled_rotation.rotation) || is_nan(real_rotation.rotation); if (!tracking_started) @@ -244,8 +229,8 @@ void Tracker::logic() break; } - euler_t rot = r2d * c_mult * rmat_to_euler(rotation); euler_t pos = euler_t(&value[TX]) - t_center; + euler_t rot = r2d * c_mult * rmat_to_euler(rotation); for (int i = 0; i < 3; i++) { @@ -258,8 +243,6 @@ void Tracker::logic() pos(i) = -pos(i); } - t_compensate(real_rotation.camera.t(), pos, pos, false, false, false); - for (int i = 0; i < 3; i++) { value(i) = pos(i); @@ -381,6 +364,8 @@ void Tracker::logic() void Tracker::run() { setPriority(QThread::HighPriority); + setPriority(QThread::HighestPriority); + setPriority(QThread::TimeCriticalPriority); { static constexpr const char* posechannels[6] = { "TX", "TY", "TZ", "Yaw", "Pitch", "Roll" }; |