diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2014-10-12 00:29:05 +0200 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2014-10-12 00:29:05 +0200 |
commit | f50ef9ca768f676c38fb7f24c15d38e2f72126fb (patch) | |
tree | 29ac967dfeeca4bb2cb27f25303964fcb980b311 /facetracknoir/tracker.cpp | |
parent | a7fe9ca724986de10e5391512cf9064f5516f940 (diff) |
simplify, rename infix operator
Diffstat (limited to 'facetracknoir/tracker.cpp')
-rw-r--r-- | facetracknoir/tracker.cpp | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/facetracknoir/tracker.cpp b/facetracknoir/tracker.cpp index 504cd003..4a80c722 100644 --- a/facetracknoir/tracker.cpp +++ b/facetracknoir/tracker.cpp @@ -98,7 +98,7 @@ void Tracker::run() { Libraries->pTracker->GetHeadPoseData(newpose); - Pose final_raw, final_mapped; + Pose final_raw, filtered; for (int i = 0; i < 6; i++) { @@ -110,34 +110,34 @@ void Tracker::run() { final_raw(i) = newpose[k]; } - if (centerp) { - centerp = false; - pose_offset = final_raw; - } - { if (enabledp) unstopped_pose = final_raw; if (Libraries->pFilter) - Libraries->pFilter->FilterHeadPoseData(unstopped_pose, final_mapped); + Libraries->pFilter->FilterHeadPoseData(unstopped_pose, filtered); else - final_mapped = unstopped_pose; + filtered = unstopped_pose; + + if (centerp) { + centerp = false; + pose_offset = filtered; + } - final_mapped = final_mapped - pose_offset; + filtered = filtered & pose_offset; for (int i = 0; i < 6; i++) - get_curve(final_mapped(i), final_mapped(i), m(i)); + get_curve(filtered(i), filtered(i), m(i)); } if (s.tcomp_p) - t_compensate(final_mapped, final_mapped, s.tcomp_tz); + t_compensate(filtered, filtered, s.tcomp_tz); - Libraries->pProtocol->sendHeadposeToGame(final_mapped); + Libraries->pProtocol->sendHeadposeToGame(filtered); { QMutexLocker foo(&mtx); - output_pose = final_mapped; + output_pose = filtered; raw_6dof = final_raw; } |